* [PATCH] cdc-eem: bad crc checking
@ 2009-07-16 16:08 Vincent CUISSARD
2009-07-17 1:10 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Vincent CUISSARD @ 2009-07-16 16:08 UTC (permalink / raw)
To: netdev
When the driver received an EEM packet with CRC option enabled, driver must
compute and check the CRC of the Ethernet data. Previous version computes CRC
on Ethernet data plus the original CRC value. Skbuff is correctly trimed but
the old length is used when CRC is computed.
Signed-off-by: Vincent CUISSARD <vincent.cuissard@gmail.com>
---
drivers/net/usb/cdc_eem.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/net/usb/cdc_eem.c b/drivers/net/usb/cdc_eem.c
index 80e0177..b9e7162 100644
--- a/drivers/net/usb/cdc_eem.c
+++ b/drivers/net/usb/cdc_eem.c
@@ -311,7 +311,7 @@ static int eem_rx_fixup(struct usbnet *dev, struct
sk_buff *skb)
* bmCRC = 0 : CRC = 0xDEADBEEF
*/
if (header & BIT(14))
- crc2 = ~crc32_le(~0, skb2->data, len);
+ crc2 = ~crc32_le(~0, skb2->data, skb2->len);
else
crc2 = 0xdeadbeef;
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] cdc-eem: bad crc checking
2009-07-16 16:08 [PATCH] cdc-eem: bad crc checking Vincent CUISSARD
@ 2009-07-17 1:10 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2009-07-17 1:10 UTC (permalink / raw)
To: vincent.cuissard; +Cc: netdev
From: Vincent CUISSARD <vincent.cuissard@gmail.com>
Date: Thu, 16 Jul 2009 18:08:58 +0200
> When the driver received an EEM packet with CRC option enabled, driver must
> compute and check the CRC of the Ethernet data. Previous version computes CRC
> on Ethernet data plus the original CRC value. Skbuff is correctly trimed but
> the old length is used when CRC is computed.
>
>
> Signed-off-by: Vincent CUISSARD <vincent.cuissard@gmail.com>
Applied, but you need to fix your patch submission so that your
email client doesn't corrupt the patch by splitting up longer
lines like it did here.
Thanks.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-07-17 1:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-16 16:08 [PATCH] cdc-eem: bad crc checking Vincent CUISSARD
2009-07-17 1:10 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).