Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[media] uvcvideo: Disable hardware timestamps by default

The hardware timestamping implementation has been reported as not
working correctly on at least the Logitech C920. Until this can be
fixed, disable it by default.

Reported-by: Peter Rabbitson <rabbit@rabbit.us>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

authored by

Laurent Pinchart and committed by
Mauro Carvalho Chehab
5d0fd3c8 60f68735

+7
+3
drivers/media/usb/uvc/uvc_driver.c
··· 32 32 #define DRIVER_DESC "USB Video Class driver" 33 33 34 34 unsigned int uvc_clock_param = CLOCK_MONOTONIC; 35 + unsigned int uvc_hw_timestamps_param; 35 36 unsigned int uvc_no_drop_param; 36 37 static unsigned int uvc_quirks_param = -1; 37 38 unsigned int uvc_trace_param; ··· 2079 2078 module_param_call(clock, uvc_clock_param_set, uvc_clock_param_get, 2080 2079 &uvc_clock_param, S_IRUGO|S_IWUSR); 2081 2080 MODULE_PARM_DESC(clock, "Video buffers timestamp clock"); 2081 + module_param_named(hwtimestamps, uvc_hw_timestamps_param, uint, S_IRUGO|S_IWUSR); 2082 + MODULE_PARM_DESC(hwtimestamps, "Use hardware timestamps"); 2082 2083 module_param_named(nodrop, uvc_no_drop_param, uint, S_IRUGO|S_IWUSR); 2083 2084 MODULE_PARM_DESC(nodrop, "Don't drop incomplete frames"); 2084 2085 module_param_named(quirks, uvc_quirks_param, uint, S_IRUGO|S_IWUSR);
+3
drivers/media/usb/uvc/uvc_video.c
··· 623 623 u32 rem; 624 624 u64 y; 625 625 626 + if (!uvc_hw_timestamps_param) 627 + return; 628 + 626 629 spin_lock_irqsave(&clock->lock, flags); 627 630 628 631 if (clock->count < clock->size)
+1
drivers/media/usb/uvc/uvcvideo.h
··· 593 593 extern unsigned int uvc_no_drop_param; 594 594 extern unsigned int uvc_trace_param; 595 595 extern unsigned int uvc_timeout_param; 596 + extern unsigned int uvc_hw_timestamps_param; 596 597 597 598 #define uvc_trace(flag, msg...) \ 598 599 do { \