From patchwork Mon Oct 31 15:25:40 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marcel Hasler X-Patchwork-Id: 9405693 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 2591260588 for ; Mon, 31 Oct 2016 15:25:48 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 280F629329 for ; Mon, 31 Oct 2016 15:25:48 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1C7FC2932D; Mon, 31 Oct 2016 15:25:48 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BEEF829329 for ; Mon, 31 Oct 2016 15:25:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S943907AbcJaPZr (ORCPT ); Mon, 31 Oct 2016 11:25:47 -0400 Received: from mail-wm0-f68.google.com ([74.125.82.68]:35258 "EHLO mail-wm0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S943729AbcJaPZq (ORCPT ); Mon, 31 Oct 2016 11:25:46 -0400 Received: by mail-wm0-f68.google.com with SMTP id 68so12155396wmz.2 for ; Mon, 31 Oct 2016 08:25:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:mime-version:content-disposition :user-agent; bh=8i1MSTH7M7gZ5rH9STC8bVDSDMU9Ma8R+QqP2TT/III=; b=1CIXZLzFVat7Vs7gcm7uMeqaY8DJEW7jRPYdHUFPqXavqq7i/IKUdsATu6R0k3V3Kl iMSvieJonhKTyj4gNVGqLuAZ6bqVmlRW+I+Jlx2nMBNIrO8IErW6Z9is48L6twVNdn/+ qZ3LP/HTsTjxoG0/crVN7PsbdqG9P/G0RKiiXfBBqovR11uB9OstAXv1/gERtlQYTS7q Es+hO3ov7rAq1XSweZ+9xlFx1jKCEamUd/kgPDKvGhnavnplzXHcvc6j2Z5lLPONVUbQ pCHqDpMPJjUSDtnTO7hG/1hBgCW7RiTaXp03GiKgrcM/qA08v/c1a5BQaBnZZZSdTfIB JQOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:mime-version :content-disposition:user-agent; bh=8i1MSTH7M7gZ5rH9STC8bVDSDMU9Ma8R+QqP2TT/III=; b=AVvxkNkRlLc+lsfW0m/8oU4zwXttMCoybN+KlwSD7Hh7WLr/3zmWZ7jGqcNKi6cs1I +14eTKrc0XLGzfbcVib2h4JXewABe45AWx13u5DBVsH709nPj3d6Ac7iVbAZYubYIX3c J3Ln6iBPImp+PKxXCmtTiTfP3AgzUPZgjFNPatNS04Hxrdpnatny7uIEPYWBbK7XdRbF 4/tHt9iscSKqt82hmnd5V0gddaKwAIxEFYaBjOPDQERNJ6yIHUGIN71VfD/1ve9tHIgD +bZvc0pzrF7g2OpIb29pfv+LvSeDV3IRF1KRpHJJzRXCE7irbzX74B8sEd5aMsOLJ/nc qUMA== X-Gm-Message-State: ABUngvffMjqkoOLSlz06QZdR9MWhERyxQ+xAKskFggRgZETm+b9wkYEsCVmgF8JvOColtA== X-Received: by 10.28.91.141 with SMTP id p135mr862324wmb.128.1477927545078; Mon, 31 Oct 2016 08:25:45 -0700 (PDT) Received: from arch-desktop ([2a02:908:672:a420:922b:34ff:fe11:2b9f]) by smtp.gmail.com with ESMTPSA id q125sm25388015wmd.2.2016.10.31.08.25.44 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 31 Oct 2016 08:25:44 -0700 (PDT) Date: Mon, 31 Oct 2016 16:25:40 +0100 From: Marcel Hasler To: Jiri Kosina , Benjamin Tissoires Cc: linux-input@vger.kernel.org Subject: [PATCH v2 1/2] usbhid: Add quirks for Mayflash/Dragonrise GameCube and PS3 adapters. Message-ID: <20161031152540.GA23060@arch-desktop> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.7.1 (2016-10-04) Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP All known gamepad adapters by Mayflash (identified as Dragonrise) need HID_QUIRK_MULTI_INPUT to split them up into four input devices. Without this quirk those adapters are falsely recognized as tablets. Fixes bug 115841 (https://bugzilla.kernel.org/show_bug.cgi?id=115841). Signed-off-by: Marcel Hasler --- drivers/hid/hid-ids.h | 6 ++++-- drivers/hid/usbhid/hid-quirks.c | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h index 6cfb5ca..642e648 100644 --- a/drivers/hid/hid-ids.h +++ b/drivers/hid/hid-ids.h @@ -314,8 +314,10 @@ #define USB_VENDOR_ID_DMI 0x0c0b #define USB_DEVICE_ID_DMI_ENC 0x5fab -#define USB_VENDOR_ID_DRAGONRISE 0x0079 -#define USB_DEVICE_ID_DRAGONRISE_WIIU 0x1800 +#define USB_VENDOR_ID_DRAGONRISE 0x0079 +#define USB_DEVICE_ID_DRAGONRISE_WIIU 0x1800 +#define USB_DEVICE_ID_DRAGONRISE_PS3 0x1801 +#define USB_DEVICE_ID_DRAGONRISE_GAMECUBE 0x1843 #define USB_VENDOR_ID_DWAV 0x0eef #define USB_DEVICE_ID_EGALAX_TOUCHCONTROLLER 0x0001 diff --git a/drivers/hid/usbhid/hid-quirks.c b/drivers/hid/usbhid/hid-quirks.c index 354d49e..05f6f61 100644 --- a/drivers/hid/usbhid/hid-quirks.c +++ b/drivers/hid/usbhid/hid-quirks.c @@ -81,6 +81,8 @@ static const struct hid_blacklist { { USB_VENDOR_ID_CREATIVELABS, USB_DEVICE_ID_CREATIVE_SB_OMNI_SURROUND_51, HID_QUIRK_NOGET }, { USB_VENDOR_ID_DMI, USB_DEVICE_ID_DMI_ENC, HID_QUIRK_NOGET }, { USB_VENDOR_ID_DRAGONRISE, USB_DEVICE_ID_DRAGONRISE_WIIU, HID_QUIRK_MULTI_INPUT }, + { USB_VENDOR_ID_DRAGONRISE, USB_DEVICE_ID_DRAGONRISE_PS3, HID_QUIRK_MULTI_INPUT }, + { USB_VENDOR_ID_DRAGONRISE, USB_DEVICE_ID_DRAGONRISE_GAMECUBE, HID_QUIRK_MULTI_INPUT }, { USB_VENDOR_ID_ELAN, HID_ANY_ID, HID_QUIRK_ALWAYS_POLL }, { USB_VENDOR_ID_ELO, USB_DEVICE_ID_ELO_TS2700, HID_QUIRK_NOGET }, { USB_VENDOR_ID_FORMOSA, USB_DEVICE_ID_FORMOSA_IR_RECEIVER, HID_QUIRK_NO_INIT_REPORTS },