Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1350594pxb; Fri, 22 Jan 2021 13:29:49 -0800 (PST) X-Google-Smtp-Source: ABdhPJy3F9PwEmenJ1PV6xhImDhLaoHBEHEmUbBi90342TeahUpV4JPwJYq5bNqTo0fk6IyjwLdp X-Received: by 2002:a17:906:dbe7:: with SMTP id yd7mr4317109ejb.242.1611350989124; Fri, 22 Jan 2021 13:29:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611350989; cv=none; d=google.com; s=arc-20160816; b=xhX3cyMbBpsR6HSEK2F/+wLc0wqG1oyoqC05Fc601GWRx6jSg/SECe9JBjzsJYFLrj sbRDD9HWLOFkpUphmB1GdJ0jmmukiipLnOGpKNEgifH4TY655qQXPsnrH5D4TY+ZG4zx BoMWbeFSZ0/BMnf/g+9yQJslhl9WZ4virucAJCwZCGOShOkbVDy20Z8Rm2U5C93Ab56y BszBsUeQ5AF6h7UUbHVwNa2+po6VPHUEeibQtEqwR4xB5HkvDLY/Uw5ULfTO5u6XTMfi Ae6ng3YKk89t1hRzVSex67iZmynXqC1pZF2/no6SWtMBjZAs5D8WZqvXeSMFysjzlHg/ GM/w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:content-transfer-encoding:mime-version :message-id:date:subject:cc:from:dkim-signature; bh=TdBClChG74PdzxlB6jNRbLR1P/Chu7Exwe8kc5GSg3c=; b=ooEMWAidpAxB8lZVzfRtruOCTO+ITQfu9Q5+rZHB2wYU8hhKhhubKCsBIWa6GJBTtO cdsc4p+d3uZOE3ozkkdwIzKHUnyrlLhaKu5FgWX5XBZPKNEgz6dovwHWrUi/sw+zhS6w 8IIBosmeG7ymf9s+uhPmoiT5yWk0a3UV3PLDi7pP0LebeyjOYmHseMt+OPkkFIA01l9P JuL681f25oL8Hf67hhX6mGhfFysjf8UItuN4ReAMs9fk+iEo7p1NVYP1JnHy7XwDnrFc 90e1O5wYUnOfcSZiGOsXFEVg3iCpggAGRIIt+FTMPgUYvYMjX2awPTFTbF08ZbZDTHbw 1+wQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=DSjYSf6s; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d9si4151717edt.564.2021.01.22.13.29.25; Fri, 22 Jan 2021 13:29:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=DSjYSf6s; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728410AbhAVV0Z (ORCPT + 99 others); Fri, 22 Jan 2021 16:26:25 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57296 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729270AbhAVVZ6 (ORCPT ); Fri, 22 Jan 2021 16:25:58 -0500 Received: from mail-ed1-x52d.google.com (mail-ed1-x52d.google.com [IPv6:2a00:1450:4864:20::52d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E8C15C0613D6; Fri, 22 Jan 2021 13:25:17 -0800 (PST) Received: by mail-ed1-x52d.google.com with SMTP id g1so8173280edu.4; Fri, 22 Jan 2021 13:25:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=TdBClChG74PdzxlB6jNRbLR1P/Chu7Exwe8kc5GSg3c=; b=DSjYSf6swflJPfJ0qDwV9T3GZRyOMC7UAIxnEyigiaJVPFjgLXOvt/eVRSayftV6NW ga1Ml4rflc41djbqoqu3aSeQZUJIRWEp8OjL5cL4czXhqWM3fl57JqhjNf6ZTkFPUZ3R 6jvDnxju+gmtPlFaob89BgM5bO40j+0GBOKFzWXzESX8xbekNHjU6UtcpcI1usitc2gc PQG99FAmy/7WR1UwpkSLgyemNiEtvMknMCHU6diN21rokOpRmPxIldLcf8hatjRLRbfg +SKp1DJD8A2Z/i/K7yZFWdSGrFxvVkzCKCqo0fEOIIHolGkqucB9snkT5xgp/+yZbUYN hfvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=TdBClChG74PdzxlB6jNRbLR1P/Chu7Exwe8kc5GSg3c=; b=U8q4GpHodi5UqBAd6JkNDujKQPel2c4ztgB3ELs1Cbt+/dfsamlbPLjKbPq7VVlWWd Q4ClDsPJ0v9HykGALmddiRmCBwG9OVF2z8rY4FWVJlg6Vt/k/AUEXzF+Ft46oHT8B4CY BTfYY69LBnvko+0vXpA+31Q6W2QreIj6KmgPbM78qGh+jDnJTTSC/ky72EsZ6YxS9ECW qE81gCz+rJZez4hN09R/r+6jQ/x7GwTpuxUq42ryqHbHBGzAFN+AH7gE406j6xp6qeaf F5Y9lDunpsPqlDYYyuGFRvVdw8F+FXA7Tfb7oNORll2wBcwaiZEuJ7zX/LfkO/E4TGRC aIIg== X-Gm-Message-State: AOAM53082Rb5O+humbqbvcg0FC+Dp1o6pKS0IGO3rHOKOtespxjfLjHN q7LNPaAwsJ1sTNZVsLcCLl8= X-Received: by 2002:a50:8004:: with SMTP id 4mr4638043eda.155.1611350716567; Fri, 22 Jan 2021 13:25:16 -0800 (PST) Received: from localhost.localdomain (a-tm1-24.tin.it. [212.216.206.55]) by smtp.gmail.com with ESMTPSA id c14sm6538889edr.46.2021.01.22.13.25.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Jan 2021 13:25:15 -0800 (PST) From: Elia Devito Cc: Elia Devito , Jiri Kosina , Benjamin Tissoires , linux-input@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] HID: Ignore battery for Elan touchscreen on HP Spectre X360 15-df0xxx Date: Fri, 22 Jan 2021 22:24:37 +0100 Message-Id: <20210122212438.4122-1-eliadevito@gmail.com> X-Mailer: git-send-email 2.29.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Battery status is reported for the HP Spectre X360 Convertible 15-df0xxx even if it does not have a battery. Prevent it to always report the battery as low. Signed-off-by: Elia Devito --- drivers/hid/hid-ids.h | 1 + drivers/hid/hid-input.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h index 5ba0aa1d2335..899449ced29e 100644 --- a/drivers/hid/hid-ids.h +++ b/drivers/hid/hid-ids.h @@ -389,6 +389,7 @@ #define USB_DEVICE_ID_TOSHIBA_CLICK_L9W 0x0401 #define USB_DEVICE_ID_HP_X2 0x074d #define USB_DEVICE_ID_HP_X2_10_COVER 0x0755 +#define I2C_DEVICE_ID_HP_SPECTRE_X360_15 0x2817 #define USB_DEVICE_ID_ASUS_UX550_TOUCHSCREEN 0x2706 #define USB_VENDOR_ID_ELECOM 0x056e diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c index f23027d2795b..8ed7f468bd95 100644 --- a/drivers/hid/hid-input.c +++ b/drivers/hid/hid-input.c @@ -324,6 +324,8 @@ static const struct hid_device_id hid_battery_quirks[] = { HID_BATTERY_QUIRK_IGNORE }, { HID_USB_DEVICE(USB_VENDOR_ID_ELAN, USB_DEVICE_ID_ASUS_UX550_TOUCHSCREEN), HID_BATTERY_QUIRK_IGNORE }, + { HID_I2C_DEVICE(USB_VENDOR_ID_ELAN, I2C_DEVICE_ID_HP_SPECTRE_X360_15), + HID_BATTERY_QUIRK_IGNORE }, {} }; -- 2.29.2