Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp401221pxu; Tue, 1 Dec 2020 14:19:20 -0800 (PST) X-Google-Smtp-Source: ABdhPJyZprDcrLkijjIOkmdFFmF2ON6aYuGqGsbr6XW2ZZp8CBUVLTbuAhSMIW0LR19Z2flUa8MF X-Received: by 2002:a50:a40a:: with SMTP id u10mr5215699edb.16.1606861160704; Tue, 01 Dec 2020 14:19:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606861160; cv=none; d=google.com; s=arc-20160816; b=fQKXC/gQ7fZUbdvEoxU6CRn43eZJfjS5VY9jxNfX8gemSOLVaEGSaP2fb6J+Km9Ll8 k+cU6z3ufWwW4bet3NRh2mHtdj0BqFRVii2T7UtUTk5E0BK5OCD1Qv82i0288h8btPzb WFpGXhS46pAXEVzcj9KxQ4O/0C7K7xoXF47t4r3UIDM5p82HLYsuj2J1RK56n8w0Lu7o o3uJHX0qXLGWIq8al4BBhlJnzhyfhPspAa6MWf7o6qSa4LY25fpCFDVLV72+3bnbCLYR HRf/zzRfSPhMdIOSRix+ubTghgCgRRNASZsVFgQgzFSlsNhZSJ3SJOn5tW3oOYt6lMYx KlPg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=2TE3SDkpEjjsVxeYsJbPtjP2D3H9VIuSqvtVW1QOQEo=; b=M0PHVkYRzdp1qMLDOxQoaIZViMA4YeKuhJMNeIYXOIDzx8gerpnSnETCWfEfx+WIeA 0s1iXYDX5nonigLhiXxsVqa4z3B4hEoqxVy38lFoDuGkTXlg2e4gJd+creZJwQdOzvAd eddphjvbUHV1znNm5a34Ekjxv+vyFSJZHjh5CLxqgG5b/wFVXgqeVYRP/5FuUXf7lkt2 IejY2k3SPyP+ySLLuXIDIBSk/fhTHS5IQt4WUY8jCia3tpXgMfNl9fgijtul5yk5GYC8 rj/0nGMchuIhOrj+NetF+6rwNuPRYjSqCzkfrm69lMd0oOA7R2nXdpiGkxq32KDzvBaC sTSg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=j10Omjem; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x25si718248edi.388.2020.12.01.14.18.58; Tue, 01 Dec 2020 14:19:20 -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=pass header.i=@linuxfoundation.org header.s=korg header.b=j10Omjem; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388024AbgLAI6w (ORCPT + 99 others); Tue, 1 Dec 2020 03:58:52 -0500 Received: from mail.kernel.org ([198.145.29.99]:34244 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388001AbgLAI6s (ORCPT ); Tue, 1 Dec 2020 03:58:48 -0500 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5AF6022242; Tue, 1 Dec 2020 08:58:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1606813082; bh=/5aYZRAVPI3/P4pxelPqO5iYlEfaT1E9ZRNF2qOQiT0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=j10Omjemhjp5a6nnsF4VYrgc9TdZ2HOQfM99ZCMtPOr4wEWWXtOxk3BNhRcqQAfjI reIujHX4/C9FLZyxobzgl38VVH7aIUkLMM7K2WsesHbIKJQBACmgpB7DEmimEFYXpG bsnLWIN59sy5jgguEo8U7bCwfXk26bzvtxFKZI7E= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hans de Goede , Benjamin Tissoires , Sasha Levin Subject: [PATCH 4.14 19/50] HID: Add Logitech Dinovo Edge battery quirk Date: Tue, 1 Dec 2020 09:53:18 +0100 Message-Id: <20201201084647.538827233@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201201084644.803812112@linuxfoundation.org> References: <20201201084644.803812112@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Hans de Goede [ Upstream commit 7940fb035abd88040d56be209962feffa33b03d0 ] The battery status is also being reported by the logitech-hidpp driver, so ignore the standard HID battery status to avoid reporting the same info twice. Note the logitech-hidpp battery driver provides more info, such as properly differentiating between charging and discharging. Also the standard HID battery info seems to be wrong, reporting a capacity of just 26% after fully charging the device. Signed-off-by: Hans de Goede Signed-off-by: Benjamin Tissoires Signed-off-by: Sasha Levin --- drivers/hid/hid-ids.h | 1 + drivers/hid/hid-input.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h index 222204c2da22a..be0707cfc0fd1 100644 --- a/drivers/hid/hid-ids.h +++ b/drivers/hid/hid-ids.h @@ -696,6 +696,7 @@ #define USB_VENDOR_ID_LOGITECH 0x046d #define USB_DEVICE_ID_LOGITECH_AUDIOHUB 0x0a0e #define USB_DEVICE_ID_LOGITECH_T651 0xb00c +#define USB_DEVICE_ID_LOGITECH_DINOVO_EDGE_KBD 0xb309 #define USB_DEVICE_ID_LOGITECH_C007 0xc007 #define USB_DEVICE_ID_LOGITECH_C077 0xc077 #define USB_DEVICE_ID_LOGITECH_RECEIVER 0xc101 diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c index 07a043ae69f12..0e63cedcc3b51 100644 --- a/drivers/hid/hid-input.c +++ b/drivers/hid/hid-input.c @@ -331,6 +331,9 @@ static const struct hid_device_id hid_battery_quirks[] = { { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_ASUSTEK, USB_DEVICE_ID_ASUSTEK_T100CHI_KEYBOARD), HID_BATTERY_QUIRK_IGNORE }, + { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_LOGITECH, + USB_DEVICE_ID_LOGITECH_DINOVO_EDGE_KBD), + HID_BATTERY_QUIRK_IGNORE }, {} }; -- 2.27.0