projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5ac4b47
)
net: dsa: Implement flow_dissect callback for tag_qca
author
xiaofeis
<
[email protected]
>
Wed, 27 Mar 2019 03:59:06 +0000
(11:59 +0800)
committer
David S. Miller
<
[email protected]
>
Thu, 28 Mar 2019 23:57:19 +0000
(16:57 -0700)
Add flow_dissect for qca tagged packet to get the right hash.
Signed-off-by: Xiaofei Shen <
[email protected]
>
Reviewed-by: Andrew Lunn <
[email protected]
>
Reviewed-by: Vinod Koul <
[email protected]
>
Reviewed-by: Florian Fainelli <
[email protected]
>
Signed-off-by: David S. Miller <
[email protected]
>
net/dsa/tag_qca.c
patch
|
blob
|
history
diff --git
a/net/dsa/tag_qca.c
b/net/dsa/tag_qca.c
index ed4f6dc26365baa3e9988b2f11ac26d8ffeb55b7..85c22ada47449d580ee2a175c0729f4bad2cad61 100644
(file)
--- a/
net/dsa/tag_qca.c
+++ b/
net/dsa/tag_qca.c
@@
-98,8
+98,18
@@
static struct sk_buff *qca_tag_rcv(struct sk_buff *skb, struct net_device *dev,
return skb;
}
+static int qca_tag_flow_dissect(const struct sk_buff *skb, __be16 *proto,
+ int *offset)
+{
+ *offset = QCA_HDR_LEN;
+ *proto = ((__be16 *)skb->data)[0];
+
+ return 0;
+}
+
const struct dsa_device_ops qca_netdev_ops = {
.xmit = qca_tag_xmit,
.rcv = qca_tag_rcv,
+ .flow_dissect = qca_tag_flow_dissect,
.overhead = QCA_HDR_LEN,
};