aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/usb/asix.c
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2012-05-28 18:31:41 -0400
committerDavid S. Miller <davem@davemloft.net>2012-05-29 17:30:07 -0400
commit9dae31009b1a00d926c6fe032d5a88099620adc3 (patch)
tree97cd6bd5a843cd1ca2faee3a28ed99f09e749357 /drivers/net/usb/asix.c
parenta0c6ffbcfe600606b2d913dded4dc6b37b3bbbfd (diff)
asix: allow full size 8021Q frames to be received
asix driver drops 8021Q full size frames because it doesn't take into account VLAN header size. Tested on AX88772 adapter. Signed-off-by: Eric Dumazet <edumazet@google.com> CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org> CC: Allan Chou <allan@asix.com.tw> CC: Trond Wuellner <trond@chromium.org> CC: Grant Grundler <grundler@chromium.org> CC: Paul Stewart <pstew@chromium.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/usb/asix.c')
-rw-r--r--drivers/net/usb/asix.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/usb/asix.c b/drivers/net/usb/asix.c
index 71e2b0523bc2..3ae80eccd0ef 100644
--- a/drivers/net/usb/asix.c
+++ b/drivers/net/usb/asix.c
@@ -35,6 +35,7 @@
35#include <linux/crc32.h> 35#include <linux/crc32.h>
36#include <linux/usb/usbnet.h> 36#include <linux/usb/usbnet.h>
37#include <linux/slab.h> 37#include <linux/slab.h>
38#include <linux/if_vlan.h>
38 39
39#define DRIVER_VERSION "22-Dec-2011" 40#define DRIVER_VERSION "22-Dec-2011"
40#define DRIVER_NAME "asix" 41#define DRIVER_NAME "asix"
@@ -321,7 +322,7 @@ static int asix_rx_fixup(struct usbnet *dev, struct sk_buff *skb)
321 return 0; 322 return 0;
322 } 323 }
323 324
324 if ((size > dev->net->mtu + ETH_HLEN) || 325 if ((size > dev->net->mtu + ETH_HLEN + VLAN_HLEN) ||
325 (size + offset > skb->len)) { 326 (size + offset > skb->len)) {
326 netdev_err(dev->net, "asix_rx_fixup() Bad RX Length %d\n", 327 netdev_err(dev->net, "asix_rx_fixup() Bad RX Length %d\n",
327 size); 328 size);