]> git.karo-electronics.de Git - karo-tx-linux.git/commit
can: peak_usb: fix hwtstamp assignment
authorOliver Hartkopp <socketcan@hartkopp.net>
Wed, 21 Nov 2012 21:43:59 +0000 (22:43 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 3 Dec 2012 19:47:09 +0000 (11:47 -0800)
commit5e937c8ffe7d6ba56a699684a4bc5f6b3edd05a5
tree4edc36af87734d0fbc29cacb9457ecb9b0e38d07
parentd6e782e1275740a5ca4c1a32cc9acfe1b6f82203
can: peak_usb: fix hwtstamp assignment

commit c9faaa09e2a1335678f09c70a0d0eda095564bab upstream.

The skb->tstamp is set to the hardware timestamp when available in the USB
urb message. This leads to user visible timestamps which contain the 'uptime'
of the USB adapter - and not the usual system generated timestamp.

Fix this wrong assignment by applying the available hardware timestamp to the
skb_shared_hwtstamps data structure - which is intended for this purpose.

Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/can/usb/peak_usb/pcan_usb.c
drivers/net/can/usb/peak_usb/pcan_usb_pro.c