kernel: Make the patches apply on top of 4.19
[openwrt/staging/chunkeey.git] / target / linux / generic / pending-4.19 / 671-net-provide-defines-for-_POLICY_FAILED-until-all-cod.patch
1 From: Jonas Gorski <jogo@openwrt.org>
2 Subject: net: provide defines for _POLICY_FAILED until all code is updated
3
4 Upstream introduced ICMPV6_POLICY_FAIL for code 5 of destination
5 unreachable, conflicting with our name.
6
7 Add appropriate defines to allow our code to build with the new
8 name until we have updated our local patches for older kernels
9 and userspace packages.
10
11 Signed-off-by: Jonas Gorski <jogo@openwrt.org>
12 ---
13 include/uapi/linux/fib_rules.h | 2 ++
14 include/uapi/linux/icmpv6.h | 2 ++
15 include/uapi/linux/rtnetlink.h | 2 ++
16 3 files changed, 6 insertions(+)
17
18 --- a/include/uapi/linux/fib_rules.h
19 +++ b/include/uapi/linux/fib_rules.h
20 @@ -89,6 +89,8 @@ enum {
21 __FR_ACT_MAX,
22 };
23
24 +#define FR_ACT_FAILED_POLICY FR_ACT_POLICY_FAILED
25 +
26 #define FR_ACT_MAX (__FR_ACT_MAX - 1)
27
28 #endif
29 --- a/include/uapi/linux/icmpv6.h
30 +++ b/include/uapi/linux/icmpv6.h
31 @@ -119,6 +119,8 @@ struct icmp6hdr {
32 #define ICMPV6_POLICY_FAIL 5
33 #define ICMPV6_REJECT_ROUTE 6
34
35 +#define ICMPV6_FAILED_POLICY ICMPV6_POLICY_FAIL
36 +
37 /*
38 * Codes for Time Exceeded
39 */
40 --- a/include/uapi/linux/rtnetlink.h
41 +++ b/include/uapi/linux/rtnetlink.h
42 @@ -232,6 +232,8 @@ enum {
43 __RTN_MAX
44 };
45
46 +#define RTN_FAILED_POLICY RTN_POLICY_FAILED
47 +
48 #define RTN_MAX (__RTN_MAX - 1)
49
50