* [PATCH net-next] net/sched: cls_flower: Use a proper mask value for enc key id parameter
@ 2016-09-27 8:21 Hadar Hen Zion
2016-09-27 9:30 ` Amir Vadai"
2016-09-28 7:11 ` David Miller
0 siblings, 2 replies; 3+ messages in thread
From: Hadar Hen Zion @ 2016-09-27 8:21 UTC (permalink / raw)
To: David S. Miller
Cc: netdev, Amir Vadai, Jiri Pirko, Or Gerlitz, Hadar Hen Zion
The current code use the encapsulation key id value as the mask of that
parameter which is wrong. Fix that by using a full mask.
Fixes: bc3103f1ed40 ('net/sched: cls_flower: Classify packet in ip tunnels')
Signed-off-by: Hadar Hen Zion <hadarh@mellanox.com>
---
net/sched/cls_flower.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/sched/cls_flower.c b/net/sched/cls_flower.c
index 2af09c8..f6f40fb 100644
--- a/net/sched/cls_flower.c
+++ b/net/sched/cls_flower.c
@@ -481,7 +481,7 @@ static int fl_set_key(struct net *net, struct nlattr **tb,
}
fl_set_key_val(tb, &key->enc_key_id.keyid, TCA_FLOWER_KEY_ENC_KEY_ID,
- &mask->enc_key_id.keyid, TCA_FLOWER_KEY_ENC_KEY_ID,
+ &mask->enc_key_id.keyid, TCA_FLOWER_UNSPEC,
sizeof(key->enc_key_id.keyid));
return 0;
@@ -919,7 +919,7 @@ static int fl_dump(struct net *net, struct tcf_proto *tp, unsigned long fh,
goto nla_put_failure;
if (fl_dump_key_val(skb, &key->enc_key_id, TCA_FLOWER_KEY_ENC_KEY_ID,
- &mask->enc_key_id, TCA_FLOWER_KEY_ENC_KEY_ID,
+ &mask->enc_key_id, TCA_FLOWER_UNSPEC,
sizeof(key->enc_key_id)))
goto nla_put_failure;
--
1.8.3.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH net-next] net/sched: cls_flower: Use a proper mask value for enc key id parameter
2016-09-27 8:21 [PATCH net-next] net/sched: cls_flower: Use a proper mask value for enc key id parameter Hadar Hen Zion
@ 2016-09-27 9:30 ` Amir Vadai"
2016-09-28 7:11 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: Amir Vadai" @ 2016-09-27 9:30 UTC (permalink / raw)
To: Hadar Hen Zion
Cc: David S. Miller, netdev, Amir Vadai, Jiri Pirko, Or Gerlitz
On Tue, Sep 27, 2016 at 11:21:18AM +0300, Hadar Hen Zion wrote:
> The current code use the encapsulation key id value as the mask of that
> parameter which is wrong. Fix that by using a full mask.
>
> Fixes: bc3103f1ed40 ('net/sched: cls_flower: Classify packet in ip tunnels')
> Signed-off-by: Hadar Hen Zion <hadarh@mellanox.com>
> ---
Acked-by: Amir Vadai <amir@vadai.me>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH net-next] net/sched: cls_flower: Use a proper mask value for enc key id parameter
2016-09-27 8:21 [PATCH net-next] net/sched: cls_flower: Use a proper mask value for enc key id parameter Hadar Hen Zion
2016-09-27 9:30 ` Amir Vadai"
@ 2016-09-28 7:11 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2016-09-28 7:11 UTC (permalink / raw)
To: hadarh; +Cc: netdev, amirva, jiri, ogerlitz
From: Hadar Hen Zion <hadarh@mellanox.com>
Date: Tue, 27 Sep 2016 11:21:18 +0300
> The current code use the encapsulation key id value as the mask of that
> parameter which is wrong. Fix that by using a full mask.
>
> Fixes: bc3103f1ed40 ('net/sched: cls_flower: Classify packet in ip tunnels')
> Signed-off-by: Hadar Hen Zion <hadarh@mellanox.com>
Applied, thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-09-28 7:11 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-27 8:21 [PATCH net-next] net/sched: cls_flower: Use a proper mask value for enc key id parameter Hadar Hen Zion
2016-09-27 9:30 ` Amir Vadai"
2016-09-28 7:11 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).