bpf-headers: fix use of netlink.h header
[openwrt/staging/stintel.git] / package / kernel / bpf-headers / patches / 102-net-flow_offload-use-NL_SET_ERR_MSG-instead-of-NL_SE.patch
1 From 6e7cd9c0abffea55e39a4160949bc6fba972d161 Mon Sep 17 00:00:00 2001
2 From: Christian Marangi <ansuelsmth@gmail.com>
3 Date: Thu, 19 Jan 2023 13:37:46 +0100
4 Subject: [PATCH] net/flow_offload: use NL_SET_ERR_MSG instead of
5 NL_SET_ERR_MSG_MOD
6
7 Use NL_SET_ERR_MSG instead of NL_SET_ERR_MSG_MOD for bpf modules as
8 kernel modules are not supported.
9
10 Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
11 ---
12 include/net/flow_offload.h | 6 +++---
13 1 file changed, 3 insertions(+), 3 deletions(-)
14
15 diff --git a/include/net/flow_offload.h b/include/net/flow_offload.h
16 index 7a2b022..f17c485 100644
17 --- a/include/net/flow_offload.h
18 +++ b/include/net/flow_offload.h
19 @@ -321,7 +321,7 @@ flow_action_mixed_hw_stats_check(const struct flow_action *action,
20
21 flow_action_for_each(i, action_entry, action) {
22 if (i && action_entry->hw_stats != last_hw_stats) {
23 - NL_SET_ERR_MSG_MOD(extack, "Mixing HW stats types for actions is not supported");
24 + NL_SET_ERR_MSG(extack, "Mixing HW stats types for actions is not supported");
25 return false;
26 }
27 last_hw_stats = action_entry->hw_stats;
28 @@ -356,11 +356,11 @@ __flow_action_hw_stats_check(const struct flow_action *action,
29
30 if (!check_allow_bit &&
31 ~action_entry->hw_stats & FLOW_ACTION_HW_STATS_ANY) {
32 - NL_SET_ERR_MSG_MOD(extack, "Driver supports only default HW stats type \"any\"");
33 + NL_SET_ERR_MSG(extack, "Driver supports only default HW stats type \"any\"");
34 return false;
35 } else if (check_allow_bit &&
36 !(action_entry->hw_stats & BIT(allow_bit))) {
37 - NL_SET_ERR_MSG_MOD(extack, "Driver does not support selected HW stats type");
38 + NL_SET_ERR_MSG(extack, "Driver does not support selected HW stats type");
39 return false;
40 }
41 return true;
42 --
43 2.38.1
44