Re: [PATCH] Add delay-init quirk for Corsair K70 RGB keyboards

2018-02-02 Thread Dmitry Fleytman
> On 2 Feb 2018, at 17:51, JackStocker <jackstocker...@gmail.com> wrote:
> 
> From: Jack Stocker <jackstocker...@gmail.com>
> 
> Following on from this patch: https://lkml.org/lkml/2017/11/3/516,
> Corsair K70 RGB keyboards also require the DELAY_INIT quirk to
> start correctly at boot.
> 
> Device ids found here:
> usb 3-3: New USB device found, idVendor=1b1c, idProduct=1b13
> usb 3-3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
> usb 3-3: Product: Corsair K70 RGB Gaming Keyboard 

Reviewed-by: Dmitry Fleytman <dmitry.fleyt...@gmail.com>

> 
> Signed-off-by: Jack Stocker <jackstocker...@gmail.com>
> ---
> drivers/usb/core/quirks.c | 3 +++
> 1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
> index a6aaf2f..9eb92dc 100644
> --- a/drivers/usb/core/quirks.c
> +++ b/drivers/usb/core/quirks.c
> @@ -221,6 +221,9 @@ static const struct usb_device_id usb_quirk_list[] = {
>   /* Corsair Strafe RGB */
>   { USB_DEVICE(0x1b1c, 0x1b20), .driver_info = USB_QUIRK_DELAY_INIT },
> 
> + /* Corsair K70 RGB */
> + { USB_DEVICE(0x1b1c, 0x1b13), .driver_info = USB_QUIRK_DELAY_INIT },
> +
>   /* MIDI keyboard WORLDE MINI */
>   { USB_DEVICE(0x1c75, 0x0204), .driver_info =
>   USB_QUIRK_CONFIG_INTF_STRINGS },
> -- 
> 2.7.4
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH v2] usb: Add device quirk for Logitech HD Pro Webcam C925e

2017-12-18 Thread Dmitry Fleytman
From: Dmitry Fleytman Dmitry Fleytman <dmitry.fleyt...@gmail.com>

Commit e0429362ab15
("usb: Add device quirk for Logitech HD Pro Webcams C920 and C930e")
introduced quirk to workaround an issue with some Logitech webcams.

There is one more model that has the same issue - C925e, so applying
the same quirk as well.

See aforementioned commit message for detailed explanation of the problem.

Signed-off-by: Dmitry Fleytman <dmitry.fleyt...@gmail.com>
---
 drivers/usb/core/quirks.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
index a10b346b9777..848da96614e8 100644
--- a/drivers/usb/core/quirks.c
+++ b/drivers/usb/core/quirks.c
@@ -52,10 +52,11 @@ static const struct usb_device_id usb_quirk_list[] = {
/* Microsoft LifeCam-VX700 v2.0 */
{ USB_DEVICE(0x045e, 0x0770), .driver_info = USB_QUIRK_RESET_RESUME },
 
-   /* Logitech HD Pro Webcams C920, C920-C and C930e */
+   /* Logitech HD Pro Webcams C920, C920-C, C925e and C930e */
{ USB_DEVICE(0x046d, 0x082d), .driver_info = USB_QUIRK_DELAY_INIT },
{ USB_DEVICE(0x046d, 0x0841), .driver_info = USB_QUIRK_DELAY_INIT },
{ USB_DEVICE(0x046d, 0x0843), .driver_info = USB_QUIRK_DELAY_INIT },
+   { USB_DEVICE(0x046d, 0x085b), .driver_info = USB_QUIRK_DELAY_INIT },
 
/* Logitech ConferenceCam CC3000e */
{ USB_DEVICE(0x046d, 0x0847), .driver_info = USB_QUIRK_DELAY_INIT },
-- 
2.14.1

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] usb: Add device quirk for Logitech HD Pro Webcam C925e

2017-12-18 Thread Dmitry Fleytman


> On 18 Dec 2017, at 20:07, Kai-Heng Feng <kai.heng.f...@canonical.com> wrote:
> 
> Hi, 
> 
>> On 19 Dec 2017, at 12:04 AM, Dmitry Fleytman <dmitry.fleyt...@gmail.com> 
>> wrote:
>> 
>> From: Dmitry Fleytman Dmitry Fleytman <dmitry.fleyt...@gmail.com>
>> 
>> Commit e0429362ab15
>> ("usb: Add device quirk for Logitech HD Pro Webcams C920 and C930e")
>> introduced quirk to workaround an issue with some Logitech webcams.
>> 
>> There is one more model that has the same issue - C925e, so applying
>> the same quirk as well.
>> 
>> See aforementioned commit message for detailed explanation of the problem.
>> 
>> Signed-off-by: Dmitry Fleytman <dmitry.fleyt...@gmail.com>
>> ---
>> drivers/usb/core/quirks.c | 3 ++-
>> 1 file changed, 2 insertions(+), 1 deletion(-)
>> 
>> diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
>> index a10b346b9777..6d2d3b0bcc2a 100644
>> --- a/drivers/usb/core/quirks.c
>> +++ b/drivers/usb/core/quirks.c
>> @@ -52,10 +52,11 @@ static const struct usb_device_id usb_quirk_list[] = {
>>  /* Microsoft LifeCam-VX700 v2.0 */
>>  { USB_DEVICE(0x045e, 0x0770), .driver_info = USB_QUIRK_RESET_RESUME },
>> 
>> -/* Logitech HD Pro Webcams C920, C920-C and C930e */
>> +/* Logitech HD Pro Webcams C920, C920-C, C925e and C930e */
>>  { USB_DEVICE(0x046d, 0x082d), .driver_info = USB_QUIRK_DELAY_INIT },
>>  { USB_DEVICE(0x046d, 0x0841), .driver_info = USB_QUIRK_DELAY_INIT },
>>  { USB_DEVICE(0x046d, 0x0843), .driver_info = USB_QUIRK_DELAY_INIT },
>> +{ USB_DEVICE(0x046d, 0x085B), .driver_info = USB_QUIRK_DELAY_INIT },
> 
> Nitpicking here, but maybe use 0x085b instead of 0x085B?

Yes. Sending v2...

> 
> Kai-Heng
> 
>> 
>>  /* Logitech ConferenceCam CC3000e */
>>  { USB_DEVICE(0x046d, 0x0847), .driver_info = USB_QUIRK_DELAY_INIT },
>> -- 
>> 2.14.1

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH] usb: Add device quirk for Logitech HD Pro Webcam C925e

2017-12-18 Thread Dmitry Fleytman
From: Dmitry Fleytman Dmitry Fleytman <dmitry.fleyt...@gmail.com>

Commit e0429362ab15
("usb: Add device quirk for Logitech HD Pro Webcams C920 and C930e")
introduced quirk to workaround an issue with some Logitech webcams.

There is one more model that has the same issue - C925e, so applying
the same quirk as well.

See aforementioned commit message for detailed explanation of the problem.

Signed-off-by: Dmitry Fleytman <dmitry.fleyt...@gmail.com>
---
 drivers/usb/core/quirks.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
index a10b346b9777..6d2d3b0bcc2a 100644
--- a/drivers/usb/core/quirks.c
+++ b/drivers/usb/core/quirks.c
@@ -52,10 +52,11 @@ static const struct usb_device_id usb_quirk_list[] = {
/* Microsoft LifeCam-VX700 v2.0 */
{ USB_DEVICE(0x045e, 0x0770), .driver_info = USB_QUIRK_RESET_RESUME },
 
-   /* Logitech HD Pro Webcams C920, C920-C and C930e */
+   /* Logitech HD Pro Webcams C920, C920-C, C925e and C930e */
{ USB_DEVICE(0x046d, 0x082d), .driver_info = USB_QUIRK_DELAY_INIT },
{ USB_DEVICE(0x046d, 0x0841), .driver_info = USB_QUIRK_DELAY_INIT },
{ USB_DEVICE(0x046d, 0x0843), .driver_info = USB_QUIRK_DELAY_INIT },
+   { USB_DEVICE(0x046d, 0x085B), .driver_info = USB_QUIRK_DELAY_INIT },
 
/* Logitech ConferenceCam CC3000e */
{ USB_DEVICE(0x046d, 0x0847), .driver_info = USB_QUIRK_DELAY_INIT },
-- 
2.14.1

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] usb: Increase quirk delay for USB devices

2017-09-06 Thread Dmitry Fleytman

> On 5 Sep 2017, at 23:22 PM, Guenter Roeck <li...@roeck-us.net> wrote:
> 
> On Tue, Sep 05, 2017 at 11:40:56AM +0300, Dmitry Fleytman wrote:
>> Commit e0429362ab15
>> ("usb: Add device quirk for Logitech HD Pro Webcams C920 and C930e")
>> introduced quirk to workaround an issue with some Logitech webcams.
>> 
>> The workaround is introducing delay for some USB operations.
>> 
>> According to our testing, delay introduced by original commit
>> is not long enough and in rare cases we still see issues described
>> by the aforementioned commit.
>> 
>> This patch increases delays introduced by original commit.
>> Having this patch applied we do not see those problems anymore.
>> 
>> Signed-off-by: Dmitry Fleytman <dmi...@daynix.com>
>> ---
>> drivers/usb/core/config.c | 2 +-
>> drivers/usb/core/hub.c| 2 +-
>> 2 files changed, 2 insertions(+), 2 deletions(-)
>> 
>> diff --git a/drivers/usb/core/config.c b/drivers/usb/core/config.c
>> index 4be52c6..854c8d6 100644
>> --- a/drivers/usb/core/config.c
>> +++ b/drivers/usb/core/config.c
>> @@ -852,7 +852,7 @@ int usb_get_configuration(struct usb_device *dev)
>>  }
>> 
>>  if (dev->quirks & USB_QUIRK_DELAY_INIT)
>> -msleep(100);
>> +msleep(200);
> 
> How did you determine the new delays ? Was it discussed with the vendor,
> or is it based on trial and error ?

It was based in trial and error.

> 
> Either case, did you confirm that you need to increase both delays
> for the problem to disappear ?

Yes, according to testing results on our setups.

Thanks,
Dmitry

> 
> Thanks,
> Guenter
> 
>> 
>>  result = usb_get_descriptor(dev, USB_DT_CONFIG, cfgno,
>>  bigbuffer, length);
>> diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
>> index 822f8c5..78c2aca 100644
>> --- a/drivers/usb/core/hub.c
>> +++ b/drivers/usb/core/hub.c
>> @@ -4825,7 +4825,7 @@ static void hub_port_connect(struct usb_hub *hub, int 
>> port1, u16 portstatus,
>>  goto loop;
>> 
>>  if (udev->quirks & USB_QUIRK_DELAY_INIT)
>> -msleep(1000);
>> +msleep(2000);
>> 
>>  /* consecutive bus-powered hubs aren't reliable; they can
>>   * violate the voltage drop budget.  if the new child has
>> -- 
>> 2.7.4

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH] usb: Increase quirk delay for USB devices

2017-09-05 Thread Dmitry Fleytman
Commit e0429362ab15
("usb: Add device quirk for Logitech HD Pro Webcams C920 and C930e")
introduced quirk to workaround an issue with some Logitech webcams.

The workaround is introducing delay for some USB operations.

According to our testing, delay introduced by original commit
is not long enough and in rare cases we still see issues described
by the aforementioned commit.

This patch increases delays introduced by original commit.
Having this patch applied we do not see those problems anymore.

Signed-off-by: Dmitry Fleytman <dmi...@daynix.com>
---
 drivers/usb/core/config.c | 2 +-
 drivers/usb/core/hub.c| 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/core/config.c b/drivers/usb/core/config.c
index 4be52c6..854c8d6 100644
--- a/drivers/usb/core/config.c
+++ b/drivers/usb/core/config.c
@@ -852,7 +852,7 @@ int usb_get_configuration(struct usb_device *dev)
}
 
if (dev->quirks & USB_QUIRK_DELAY_INIT)
-   msleep(100);
+   msleep(200);
 
result = usb_get_descriptor(dev, USB_DT_CONFIG, cfgno,
bigbuffer, length);
diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
index 822f8c5..78c2aca 100644
--- a/drivers/usb/core/hub.c
+++ b/drivers/usb/core/hub.c
@@ -4825,7 +4825,7 @@ static void hub_port_connect(struct usb_hub *hub, int 
port1, u16 portstatus,
goto loop;
 
if (udev->quirks & USB_QUIRK_DELAY_INIT)
-   msleep(1000);
+   msleep(2000);
 
/* consecutive bus-powered hubs aren't reliable; they can
 * violate the voltage drop budget.  if the new child has
-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] usb: Add device quirk for Logitech HD Pro Webcam C920-C

2017-08-25 Thread Dmitry Fleytman

> On 24 Aug 2017, at 10:58 AM, Kai-Heng Feng <kai.heng.f...@canonical.com> 
> wrote:
> 
> On Mon, Aug 21, 2017 at 6:03 PM, Dmitry Fleytman <dmi...@daynix.com> wrote:
>> Commit e0429362ab15
>> ("usb: Add device quirk for Logitech HD Pro Webcams C920 and C930e")
>> introduced quirk to workaround an issue with some Logitech webcams.
>> 
>> Apparently model C920-C has the same issue so applying
>> the same quirk as well.
> 
> I think it's better to also mention "C920-C" in the comment section.


I agree. See v2 (just sent).

Thanks,
Dmitry


> 
>> 
>> See aforementioned commit message for detailed explanation of the problem.
>> 
>> Signed-off-by: Dmitry Fleytman <dmi...@daynix.com>
>> ---
>> drivers/usb/core/quirks.c | 1 +
>> 1 file changed, 1 insertion(+)
>> 
>> diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
>> index 574da2b..36d4841 100644
>> --- a/drivers/usb/core/quirks.c
>> +++ b/drivers/usb/core/quirks.c
>> @@ -59,6 +59,7 @@ static const struct usb_device_id usb_quirk_list[] = {
>> 
>>/* Logitech HD Pro Webcams C920 and C930e */
>>{ USB_DEVICE(0x046d, 0x082d), .driver_info = USB_QUIRK_DELAY_INIT },
>> +   { USB_DEVICE(0x046d, 0x0841), .driver_info = USB_QUIRK_DELAY_INIT },
>>{ USB_DEVICE(0x046d, 0x0843), .driver_info = USB_QUIRK_DELAY_INIT },
>> 
>>/* Logitech ConferenceCam CC3000e */
>> --
>> 2.7.4
>> 

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH v2] usb: Add device quirk for Logitech HD Pro Webcam C920-C

2017-08-25 Thread Dmitry Fleytman
Changes since v1:

 - C920-C added to the comments section

Dmitry Fleytman (1):
  usb: Add device quirk for Logitech HD Pro Webcam C920-C

 drivers/usb/core/quirks.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH v2] usb: Add device quirk for Logitech HD Pro Webcam C920-C

2017-08-25 Thread Dmitry Fleytman
Commit e0429362ab15
("usb: Add device quirk for Logitech HD Pro Webcams C920 and C930e")
introduced quirk to workaround an issue with some Logitech webcams.

Apparently model C920-C has the same issue so applying
the same quirk as well.

See aforementioned commit message for detailed explanation of the problem.

Signed-off-by: Dmitry Fleytman <dmi...@daynix.com>
---
 drivers/usb/core/quirks.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
index 574da2b..2583224 100644
--- a/drivers/usb/core/quirks.c
+++ b/drivers/usb/core/quirks.c
@@ -57,8 +57,9 @@ static const struct usb_device_id usb_quirk_list[] = {
/* Microsoft LifeCam-VX700 v2.0 */
{ USB_DEVICE(0x045e, 0x0770), .driver_info = USB_QUIRK_RESET_RESUME },
 
-   /* Logitech HD Pro Webcams C920 and C930e */
+   /* Logitech HD Pro Webcams C920, C920-C and C930e */
{ USB_DEVICE(0x046d, 0x082d), .driver_info = USB_QUIRK_DELAY_INIT },
+   { USB_DEVICE(0x046d, 0x0841), .driver_info = USB_QUIRK_DELAY_INIT },
{ USB_DEVICE(0x046d, 0x0843), .driver_info = USB_QUIRK_DELAY_INIT },
 
/* Logitech ConferenceCam CC3000e */
-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH] usb: Add device quirk for Logitech HD Pro Webcam C920-C

2017-08-21 Thread Dmitry Fleytman
Commit e0429362ab15
("usb: Add device quirk for Logitech HD Pro Webcams C920 and C930e")
introduced quirk to workaround an issue with some Logitech webcams.

Apparently model C920-C has the same issue so applying
the same quirk as well.

See aforementioned commit message for detailed explanation of the problem.

Signed-off-by: Dmitry Fleytman <dmi...@daynix.com>
---
 drivers/usb/core/quirks.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
index 574da2b..36d4841 100644
--- a/drivers/usb/core/quirks.c
+++ b/drivers/usb/core/quirks.c
@@ -59,6 +59,7 @@ static const struct usb_device_id usb_quirk_list[] = {
 
/* Logitech HD Pro Webcams C920 and C930e */
{ USB_DEVICE(0x046d, 0x082d), .driver_info = USB_QUIRK_DELAY_INIT },
+   { USB_DEVICE(0x046d, 0x0841), .driver_info = USB_QUIRK_DELAY_INIT },
{ USB_DEVICE(0x046d, 0x0843), .driver_info = USB_QUIRK_DELAY_INIT },
 
/* Logitech ConferenceCam CC3000e */
-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html