]> git.hungrycats.org Git - linux/commit
net: mscc: fix the frame extraction into the skb
authorAntoine Tenart <antoine.tenart@bootlin.com>
Thu, 20 Sep 2018 10:08:54 +0000 (12:08 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 18 Oct 2018 07:18:11 +0000 (09:18 +0200)
commit6133d8e499e6a88b9a938243e1b8a6aa1f79ec8c
tree86bcab15036e66131e95a6a2df07cba05e1fa620
parentd29a558b56ee952e452969ac7c90d0a7bf2f58bb
net: mscc: fix the frame extraction into the skb

[ Upstream commit 652ef42c134da1bbb03bd4c9b4291dfaf8d7febb ]

When extracting frames from the Ocelot switch, the frame check sequence
(FCS) is present at the end of the data extracted. The FCS was put into
the sk buffer which introduced some issues (as length related ones), as
the FCS shouldn't be part of an Rx sk buffer.

This patch fixes the Ocelot switch extraction behaviour by discarding
the FCS.

Fixes: a556c76adc05 ("net: mscc: Add initial Ocelot switch support")
Signed-off-by: Antoine Tenart <antoine.tenart@bootlin.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/ethernet/mscc/ocelot_board.c