diff options
author | 2019-03-19 13:12:18 +0000 | |
---|---|---|
committer | 2019-03-19 13:12:18 +0000 | |
commit | c9e48084c88cf901ad0d99a889f2628a5622d90b (patch) | |
tree | e95ef2305fa14e0c6e218a6aba8de8df4a0b5798 /net/dsa/tag_dsa.c | |
parent | regulator: axp20x: Use rdev_get_id at appropriate places (diff) | |
parent | Linux 5.1-rc1 (diff) | |
download | wireguard-linux-c9e48084c88cf901ad0d99a889f2628a5622d90b.tar.xz wireguard-linux-c9e48084c88cf901ad0d99a889f2628a5622d90b.zip |
Merge tag 'v5.1-rc1' into regulator-5.2
Linux 5.1-rc1
Diffstat (limited to 'net/dsa/tag_dsa.c')
-rw-r--r-- | net/dsa/tag_dsa.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/net/dsa/tag_dsa.c b/net/dsa/tag_dsa.c index 8b2f92e3f3a2..67ff3fae18d8 100644 --- a/net/dsa/tag_dsa.c +++ b/net/dsa/tag_dsa.c @@ -146,8 +146,17 @@ static struct sk_buff *dsa_rcv(struct sk_buff *skb, struct net_device *dev, return skb; } +static int dsa_tag_flow_dissect(const struct sk_buff *skb, __be16 *proto, + int *offset) +{ + *offset = 4; + *proto = ((__be16 *)skb->data)[1]; + return 0; +} + const struct dsa_device_ops dsa_netdev_ops = { .xmit = dsa_xmit, .rcv = dsa_rcv, + .flow_dissect = dsa_tag_flow_dissect, .overhead = DSA_HLEN, }; |