]> git.baikalelectronics.ru Git - kernel.git/commit
r6040: use ETH_ZLEN instead of MISR for SKB length checking
authorFlorian Fainelli <florian@openwrt.org>
Wed, 15 Jan 2014 21:04:26 +0000 (13:04 -0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 17 Jan 2014 00:22:54 +0000 (16:22 -0800)
commiteffd28706408b387f8efd8c93a14eba11a5676d5
treec8cad9f43e4df16ff955b2d9b1da60f72965f219
parent61b1eae77eea9c52109392ed0bd346f89176ca42
r6040: use ETH_ZLEN instead of MISR for SKB length checking

Ever since this driver was merged the following code was included:

if (skb->len < MISR)
skb->len = MISR;

MISR is defined to 0x3C which is also equivalent to ETH_ZLEN, but use
ETH_ZLEN directly which is exactly what we want to be checking for.

Reported-by: Marc Volovic <marcv@ezchip.com>
Signed-off-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/rdc/r6040.c