Commit 544377cd authored by Roman Mashak's avatar Roman Mashak Committed by David S. Miller

net sched actions: fix sparse warning

The variable _data in include/asm-generic/sections.h defines sections,
this causes sparse warning in pedit:

net/sched/act_pedit.c:293:35: warning: symbol '_data' shadows an earlier one
./include/asm-generic/sections.h:36:13: originally declared here

Therefore rename the variable.
Reviewed-by: default avatarSimon Horman <simon.horman@netronome.com>
Signed-off-by: default avatarRoman Mashak <mrv@mojatatu.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent d020d455
...@@ -290,7 +290,7 @@ static int tcf_pedit(struct sk_buff *skb, const struct tc_action *a, ...@@ -290,7 +290,7 @@ static int tcf_pedit(struct sk_buff *skb, const struct tc_action *a,
enum pedit_cmd cmd = TCA_PEDIT_KEY_EX_CMD_SET; enum pedit_cmd cmd = TCA_PEDIT_KEY_EX_CMD_SET;
for (i = p->tcfp_nkeys; i > 0; i--, tkey++) { for (i = p->tcfp_nkeys; i > 0; i--, tkey++) {
u32 *ptr, _data; u32 *ptr, hdata;
int offset = tkey->off; int offset = tkey->off;
int hoffset; int hoffset;
u32 val; u32 val;
...@@ -337,7 +337,7 @@ static int tcf_pedit(struct sk_buff *skb, const struct tc_action *a, ...@@ -337,7 +337,7 @@ static int tcf_pedit(struct sk_buff *skb, const struct tc_action *a,
} }
ptr = skb_header_pointer(skb, hoffset + offset, ptr = skb_header_pointer(skb, hoffset + offset,
4, &_data); 4, &hdata);
if (!ptr) if (!ptr)
goto bad; goto bad;
/* just do it, baby */ /* just do it, baby */
...@@ -355,7 +355,7 @@ static int tcf_pedit(struct sk_buff *skb, const struct tc_action *a, ...@@ -355,7 +355,7 @@ static int tcf_pedit(struct sk_buff *skb, const struct tc_action *a,
} }
*ptr = ((*ptr & tkey->mask) ^ val); *ptr = ((*ptr & tkey->mask) ^ val);
if (ptr == &_data) if (ptr == &hdata)
skb_store_bits(skb, hoffset + offset, ptr, 4); skb_store_bits(skb, hoffset + offset, ptr, 4);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment