Skip to contentSkip to conversation

nft_counter: remove wrong __percpu of nft_counter_resest()'s arg

PATCH Applied Luc Van Oostenryck 2 participants 2 messages Jan 19, 2019 – Jan 28, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 nft_counter: remove wrong __percpu of nft_counter_resest()'s arg

nft_counter_rest() has its first argument declared as
struct nft_counter_percpu_priv __percpu *priv
but this structure is not percpu (it only countains a member 'counter' which is, correctly, a pointer to a percpu struct nft_counter).

So, remove the '__percpu' from the argument's declaration.

---
 net/netfilter/nft_counter.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/netfilter/nft_counter.c +1 -1
index a61d7edfc..1a6b06ce6 100644
@@ -104,7 +104,7 @@ static void nft_counter_obj_destroy(const struct nft_ctx *ctx,
 	nft_counter_do_destroy(priv);
 }
 
-static void nft_counter_reset(struct nft_counter_percpu_priv __percpu *priv,
+static void nft_counter_reset(struct nft_counter_percpu_priv *priv,
 			      struct nft_counter *total)
 {
 	struct nft_counter *this_cpu;
Signature · 1 line
2.20.0
maintainer Applied
#1 lore raw
Quoted 7 lines · Luc Van Oostenryck

nft_counter_rest() has its first argument declared as
struct nft_counter_percpu_priv __percpu *priv
but this structure is not percpu (it only countains a member 'counter' which is, correctly, a pointer to a percpu struct nft_counter).

So, remove the '__percpu' from the argument's declaration.

Applied, thanks.