From patchwork Mon May 5 22:55:32 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peter F. Patel-Schneider" X-Patchwork-Id: 4117901 X-Patchwork-Delegate: jikos@jikos.cz Return-Path: X-Original-To: patchwork-linux-input@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 7BEC8BFF02 for ; Mon, 5 May 2014 22:55:42 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 660B6202EB for ; Mon, 5 May 2014 22:55:41 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0C67A20260 for ; Mon, 5 May 2014 22:55:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756803AbaEEWzj (ORCPT ); Mon, 5 May 2014 18:55:39 -0400 Received: from mail-qa0-f52.google.com ([209.85.216.52]:39356 "EHLO mail-qa0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756752AbaEEWzi (ORCPT ); Mon, 5 May 2014 18:55:38 -0400 Received: by mail-qa0-f52.google.com with SMTP id cm18so6905163qab.11 for ; Mon, 05 May 2014 15:55:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :content-type:content-transfer-encoding; bh=GoAtsNaUqRnor+LQLLztsiMI5NsrnYVNd29li4TuO/4=; b=gMoToWQKDozTnT+EsJhTIFn+YVspMVy5vTtnR+Ecjk7QUGrX0H/b0fD0GDkPbrp6hd nmOjf1EvxR61AotkmdVMv5mwVIIHy5YKazDK/csI2Nbxp81zam1tRVm3y9JWQp1M1DRy /JOlrhbobrAclh2BpMEC8pL9OOa2R3q6kKon2uPxX/2n7rWK4zp/LxZFCxj44tRDrjtm cZepPYETDJ7Blr/xD2AnTxCetK0m31fCJqWBf1srqWcqbd3K8pEDGx7JtClSoL8BXCRB uRi5t0sjsrCKHNOQ41s4zmsF7KRBAeDxFpYJ6/DBqpSABNETN1Vo+o6TmGGeO68YCruK F2aA== X-Received: by 10.224.79.143 with SMTP id p15mr49316398qak.57.1399330537902; Mon, 05 May 2014 15:55:37 -0700 (PDT) Received: from [192.168.95.250] ([199.4.160.88]) by mx.google.com with ESMTPSA id 17sm13218928qgm.6.2014.05.05.15.55.35 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 05 May 2014 15:55:37 -0700 (PDT) Message-ID: <536816E4.2040109@gmail.com> Date: Mon, 05 May 2014 15:55:32 -0700 From: "Peter F. Patel-Schneider" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 MIME-Version: 1.0 To: linux-input@vger.kernel.org, jkosina@suse.cz CC: Srinivas Pandruvada Subject: [PATCH] iio:hid-sensor-hub: Add in quirk for sensor hub in Lenovo Ideapad Yogas Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Spam-Status: No, score=-7.4 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The sensor hub in Lenovo Yogas needs the enumeration quirk. I've been running the patch for over a month with no problems, whereas the unpatched drivers reliably mis-initialized the sensors. (This is a resending of a previous patch that had formatting issues.) Signed-off-by: Peter F. Patel-Schneider Acked-by: Srinivas Pandruvada --- drivers/hid/hid-ids.h | 3 +++ drivers/hid/hid-sensor-hub.c | 3 +++ 2 files changed, 6 insertions(+) -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h index 5a5248f..f944e37 100644 --- a/drivers/hid/hid-ids.h +++ b/drivers/hid/hid-ids.h @@ -823,6 +823,9 @@ #define USB_DEVICE_ID_SYNAPTICS_HD 0x0ac3 #define USB_DEVICE_ID_SYNAPTICS_QUAD_HD 0x1ac3 +#define USB_VENDOR_ID_TEXAS_INSTRUMENTS 0x2047 +#define USB_DEVICE_ID_TEXAS_INSTRUMENTS_LENOVO_YOGA 0x0855 + #define USB_VENDOR_ID_THINGM 0x27b8 #define USB_DEVICE_ID_BLINK1 0x01ed diff --git a/drivers/hid/hid-sensor-hub.c b/drivers/hid/hid-sensor-hub.c index 46f4480..597732b 100644 --- a/drivers/hid/hid-sensor-hub.c +++ b/drivers/hid/hid-sensor-hub.c @@ -665,6 +665,9 @@ static const struct hid_device_id sensor_hub_devices[] = { { HID_DEVICE(HID_BUS_ANY, HID_GROUP_SENSOR_HUB, USB_VENDOR_ID_INTEL_1, USB_DEVICE_ID_INTEL_HID_SENSOR), .driver_data = HID_SENSOR_HUB_ENUM_QUIRK}, + { HID_DEVICE(HID_BUS_ANY, HID_GROUP_SENSOR_HUB, USB_VENDOR_ID_TEXAS_INSTRUMENTS, + USB_DEVICE_ID_TEXAS_INSTRUMENTS_LENOVO_YOGA), + .driver_data = HID_SENSOR_HUB_ENUM_QUIRK}, { HID_DEVICE(HID_BUS_ANY, HID_GROUP_SENSOR_HUB, HID_ANY_ID, HID_ANY_ID) }, { }