From: Peter Korsgaard Date: Mon, 16 Dec 2013 10:35:33 +0000 (+0100) Subject: dm9601: fix reception of full size ethernet frames on dm9620/dm9621a X-Git-Tag: v4.14-rc1~8331^2~36 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=407900cfb54bdb2cfa228010b6697305f66b2948;p=platform%2Fkernel%2Flinux-rpi.git dm9601: fix reception of full size ethernet frames on dm9620/dm9621a dm9620/dm9621a require room for 4 byte padding even in dm9601 (3 byte header) mode. Cc: Signed-off-by: Peter Korsgaard Signed-off-by: David S. Miller --- diff --git a/drivers/net/usb/dm9601.c b/drivers/net/usb/dm9601.c index 8e88572..aca0285 100644 --- a/drivers/net/usb/dm9601.c +++ b/drivers/net/usb/dm9601.c @@ -364,7 +364,12 @@ static int dm9601_bind(struct usbnet *dev, struct usb_interface *intf) dev->net->ethtool_ops = &dm9601_ethtool_ops; dev->net->hard_header_len += DM_TX_OVERHEAD; dev->hard_mtu = dev->net->mtu + dev->net->hard_header_len; - dev->rx_urb_size = dev->net->mtu + ETH_HLEN + DM_RX_OVERHEAD; + + /* dm9620/21a require room for 4 byte padding, even in dm9601 + * mode, so we need +1 to be able to receive full size + * ethernet frames. + */ + dev->rx_urb_size = dev->net->mtu + ETH_HLEN + DM_RX_OVERHEAD + 1; dev->mii.dev = dev->net; dev->mii.mdio_read = dm9601_mdio_read;