From patchwork Tue Apr 10 09:49:31 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kai-Heng Feng X-Patchwork-Id: 896564 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=canonical.com Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) by ozlabs.org (Postfix) with ESMTP id 40L2T95NBlz9s2S; Tue, 10 Apr 2018 19:49:49 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1f5puM-0001Wi-78; Tue, 10 Apr 2018 09:49:46 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by huckleberry.canonical.com with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.86_2) (envelope-from ) id 1f5puL-0001W7-Mf for kernel-team@lists.ubuntu.com; Tue, 10 Apr 2018 09:49:45 +0000 Received: from [175.41.48.77] (helo=localhost) by youngberry.canonical.com with esmtpsa (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from ) id 1f5puK-0001fu-Vk for kernel-team@lists.ubuntu.com; Tue, 10 Apr 2018 09:49:45 +0000 From: Kai-Heng Feng To: kernel-team@lists.ubuntu.com Subject: [Bionic] [PATCH 3/3] usb: core: Add USB_QUIRK_DELAY_CTRL_MSG to usbcore quirks Date: Tue, 10 Apr 2018 17:49:31 +0800 Message-Id: <20180410094931.22512-4-kai.heng.feng@canonical.com> X-Mailer: git-send-email 2.15.1 In-Reply-To: <20180410094931.22512-1-kai.heng.feng@canonical.com> References: <20180410094931.22512-1-kai.heng.feng@canonical.com> X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" BugLink: https://bugs.launchpad.net/bugs/1762695 There's a new quirk, USB_QUIRK_DELAY_CTRL_MSG. Add it to usbcore quirks for completeness. Signed-off-by: Kai-Heng Feng Signed-off-by: Greg Kroah-Hartman (cherry picked from commit 4d8d5a392ae110d9b5889afd2b4beef9a09e712d) Signed-off-by: Kai-Heng Feng --- Documentation/admin-guide/kernel-parameters.txt | 4 +++- drivers/usb/core/quirks.c | 3 +++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt index 969f48683313..6091973f844a 100644 --- a/Documentation/admin-guide/kernel-parameters.txt +++ b/Documentation/admin-guide/kernel-parameters.txt @@ -4407,7 +4407,9 @@ calculation); m = USB_QUIRK_DISCONNECT_SUSPEND (Device needs to be disconnected before suspend to - prevent spurious wakeup) + prevent spurious wakeup); + n = USB_QUIRK_DELAY_CTRL_MSG (Device needs a + pause after every control message); Example: quirks=0781:5580:bk,0a5c:5834:gij usbhid.mousepoll= diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c index a4f53e1f1ce1..84ccbb0424c2 100644 --- a/drivers/usb/core/quirks.c +++ b/drivers/usb/core/quirks.c @@ -124,6 +124,9 @@ static int quirks_param_set(const char *val, const struct kernel_param *kp) case 'm': flags |= USB_QUIRK_DISCONNECT_SUSPEND; break; + case 'n': + flags |= USB_QUIRK_DELAY_CTRL_MSG; + break; /* Ignore unrecognized flag characters */ } }