Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1683987 > unrolled thread
| Started by | Jim Lin <jilin@nvidia.com> |
|---|---|
| First post | 2017-07-10 08:50 +0200 |
| Last post | 2017-07-14 09:40 +0200 |
| Articles | 4 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH 1/1 V2] media: usb: uvc: Fix incorrect timeout for Get Request Jim Lin <jilin@nvidia.com> - 2017-07-10 08:50 +0200
Re: [PATCH 1/1 V2] media: usb: uvc: Fix incorrect timeout for Get Request Laurent Pinchart <laurent.pinchart@ideasonboard.com> - 2017-07-10 21:50 +0200
Re: [PATCH 1/1 V2] media: usb: uvc: Fix incorrect timeout for Get Request Jim Lin <jilin@nvidia.com> - 2017-07-14 04:20 +0200
Re: [PATCH 1/1 V2] media: usb: uvc: Fix incorrect timeout for Get Request Laurent Pinchart <laurent.pinchart@ideasonboard.com> - 2017-07-14 09:40 +0200
| From | Jim Lin <jilin@nvidia.com> |
|---|---|
| Date | 2017-07-10 08:50 +0200 |
| Subject | [PATCH 1/1 V2] media: usb: uvc: Fix incorrect timeout for Get Request |
| Message-ID | <u1AG5-1v9-1@gated-at.bofh.it> |
Section 9.2.6.4 of USB 2.0/3.x specification describes that "device must be able to return the first data packet to host within 500 ms of receipt of the request. For subsequent data packet, if any, the device must be able to return them within 500 ms". This is to fix incorrect timeout and change it from 300 ms to 500 ms to meet the timing specified by specification for Get Request. Signed-off-by: Jim Lin <jilin@nvidia.com> --- V2: Change patch description drivers/media/usb/uvc/uvcvideo.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/usb/uvc/uvcvideo.h b/drivers/media/usb/uvc/uvcvideo.h index 15e415e..296b69b 100644 --- a/drivers/media/usb/uvc/uvcvideo.h +++ b/drivers/media/usb/uvc/uvcvideo.h @@ -166,7 +166,7 @@ /* Maximum status buffer size in bytes of interrupt URB. */ #define UVC_MAX_STATUS_SIZE 16 -#define UVC_CTRL_CONTROL_TIMEOUT 300 +#define UVC_CTRL_CONTROL_TIMEOUT 500 #define UVC_CTRL_STREAMING_TIMEOUT 5000 /* Maximum allowed number of control mappings per device */ -- 2.7.4
[toc] | [next] | [standalone]
| From | Laurent Pinchart <laurent.pinchart@ideasonboard.com> |
|---|---|
| Date | 2017-07-10 21:50 +0200 |
| Message-ID | <u1MQV-L2-1@gated-at.bofh.it> |
| In reply to | #1683987 |
Hi Jim, Thank you for the patch. On Monday 10 Jul 2017 14:43:49 Jim Lin wrote: > Section 9.2.6.4 of USB 2.0/3.x specification describes that > "device must be able to return the first data packet to host within > 500 ms of receipt of the request. For subsequent data packet, if any, > the device must be able to return them within 500 ms". > > This is to fix incorrect timeout and change it from 300 ms to 500 ms > to meet the timing specified by specification for Get Request. > > Signed-off-by: Jim Lin <jilin@nvidia.com> The patch looks good to me, so Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> but I'm curious, have you noticed issues with some devices in practice ? > --- > V2: Change patch description > > drivers/media/usb/uvc/uvcvideo.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/media/usb/uvc/uvcvideo.h > b/drivers/media/usb/uvc/uvcvideo.h index 15e415e..296b69b 100644 > --- a/drivers/media/usb/uvc/uvcvideo.h > +++ b/drivers/media/usb/uvc/uvcvideo.h > @@ -166,7 +166,7 @@ > /* Maximum status buffer size in bytes of interrupt URB. */ > #define UVC_MAX_STATUS_SIZE 16 > > -#define UVC_CTRL_CONTROL_TIMEOUT 300 > +#define UVC_CTRL_CONTROL_TIMEOUT 500 > #define UVC_CTRL_STREAMING_TIMEOUT 5000 > > /* Maximum allowed number of control mappings per device */ -- Regards, Laurent Pinchart
[toc] | [prev] | [next] | [standalone]
| From | Jim Lin <jilin@nvidia.com> |
|---|---|
| Date | 2017-07-14 04:20 +0200 |
| Subject | Re: [PATCH 1/1 V2] media: usb: uvc: Fix incorrect timeout for Get Request |
| Message-ID | <u2Yn0-5oH-9@gated-at.bofh.it> |
| In reply to | #1684606 |
On 2017年07月11日 03:47, Laurent Pinchart wrote: > Hi Jim, > > Thank you for the patch. > > On Monday 10 Jul 2017 14:43:49 Jim Lin wrote: >> Section 9.2.6.4 of USB 2.0/3.x specification describes that >> "device must be able to return the first data packet to host within >> 500 ms of receipt of the request. For subsequent data packet, if any, >> the device must be able to return them within 500 ms". >> >> This is to fix incorrect timeout and change it from 300 ms to 500 ms >> to meet the timing specified by specification for Get Request. >> >> Signed-off-by: Jim Lin <jilin@nvidia.com> > > The patch looks good to me, so > > Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> > > but I'm curious, have you noticed issues with some devices in practice ? > Sometimes this device takes about 360 ms to respond. usb 1-2: new high-speed USB device number 16 usb 1-2: New USB device found, idVendor=045e, idProduct=0772 usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0 usb 1-2: Product: Microsoft�® LifeCam Studio(TM) usb 1-2: Manufacturer: Microsoft : uvcvideo: Failed to query (GET_DEF) UVC control 2 on unit 4: -110 (exp. 2). And it will be working well with correct timeout value. --nvpublic
[toc] | [prev] | [next] | [standalone]
| From | Laurent Pinchart <laurent.pinchart@ideasonboard.com> |
|---|---|
| Date | 2017-07-14 09:40 +0200 |
| Message-ID | <u33mG-df-5@gated-at.bofh.it> |
| In reply to | #1684606 |
Hi Jim, On Friday 14 Jul 2017 09:58:11 Jim Lin wrote: > On 2017年07月11日 03:47, Laurent Pinchart wrote: > > On Monday 10 Jul 2017 14:43:49 Jim Lin wrote: > >> Section 9.2.6.4 of USB 2.0/3.x specification describes that > >> "device must be able to return the first data packet to host within > >> 500 ms of receipt of the request. For subsequent data packet, if any, > >> the device must be able to return them within 500 ms". > >> > >> This is to fix incorrect timeout and change it from 300 ms to 500 ms > >> to meet the timing specified by specification for Get Request. > >> > >> Signed-off-by: Jim Lin <jilin@nvidia.com> > > > > The patch looks good to me, so > > > > Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> > > > > but I'm curious, have you noticed issues with some devices in practice ? > > Sometimes this device takes about 360 ms to respond. > > usb 1-2: new high-speed USB device number 16 > usb 1-2: New USB device found, idVendor=045e, idProduct=0772 > usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber= 0 > usb 1-2: Product: Microsoft�® LifeCam Studio(TM) > usb 1-2: Manufacturer: Microsoft > > uvcvideo: Failed to query (GET_DEF) UVC control 2 on unit 4: -110 (exp. 2). > > And it will be working well with correct timeout value. Thank you for the information. I've applied the patch to my tree and will push it to v4.14. -- Regards, Laurent Pinchart
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web