usbnet: fix oops in usbnet_start_xmit

This patch fixes the bug added in commit v3.1-rc7-1055-gf9b491e
SKB can be NULL at this point, at least for cdc-ncm.

Signed-off-by: Konstantin Khlebnikov <khlebnikov@openvz.org>
Acked-by: Richard Cochran <richardcochran@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Konstantin Khlebnikov 2011-11-07 05:54:58 +00:00 committed by David S. Miller
parent 012641082b
commit 23ba07991d
1 changed files with 2 additions and 1 deletions

View File

@ -1057,6 +1057,7 @@ netdev_tx_t usbnet_start_xmit (struct sk_buff *skb,
unsigned long flags;
int retval;
if (skb)
skb_tx_timestamp(skb);
// some devices want funky USB-level framing, for