Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3288273ybb; Tue, 31 Mar 2020 02:10:00 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuENmXyfy2yh/4H/Mio7xzv6tUQO7IJNy3/hMr+xadZ/eUwbZtBYr5VfRKlYl1Aqp7oyVhD X-Received: by 2002:a9d:719a:: with SMTP id o26mr12674594otj.290.1585645800420; Tue, 31 Mar 2020 02:10:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585645800; cv=none; d=google.com; s=arc-20160816; b=HlEjR6sjQFDIrDJ5v/zM7HqntL1UkpX//99OmI4ENX8KC1mYDkMfW9h679OTL7b4rm 6dOzGOeltQzp6LfiGsTUvaJfx+AXhAn+MKizgOrSnD8x/REqvDSCfyE8wBQ6U/P75hV/ 6bGIZwnQxA9eXrDvD4mwGEa4i1GVYHeX0oLK897/lbVBcaZySiMG1+oRv8en0hv+ua8f jQcJ0JVgCSlGqFfc+DdpRfen2lj3wKEOSpHiI6y/hUEvigB0ETSMjfIFD6L3Y2EwSFFs Cee0gvq2TzawwbIAv27bIKrr+5V7PENzwS1Vd6Wv23UyFT4HXX/7dXXTZZslccfMV3hy xilQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=7MCZUTxXE19B60W1QzbCLzIhO6AwnA2fBFylXXWtRGU=; b=BlQr3WTk2XYtLtJHVNdFU6IXXfD9T1TRP1tRQirvyow2n0IJLwftGwhpDY9uXkXXOf pQZo1PfaGg+lX2wHLqsB6u3tsFn0BPOCAjozFLsH1YDwjOneIzQxiUjNcLcjd4LUYT8M 5q4gEc3meMS/JZg1E/En+8VOYYlB+/MapTK8O1ifyaFEhAwsqiCT+MxHY02OJk+0JuWM 2X7pjqzjCJvtt2rWl6nUogbqhRD6SkGxipyf/1vhXrGf/QAPBQLk66pLBls60gx2ifjg mwVW5ARxlcPrQpWlOfFMcCUtAR5lXO7Zec7wIIPbszq3eZuIVfT4xIEBluOz1ex0/pW4 3E+w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Jcex5ILP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b2si7150440otl.298.2020.03.31.02.09.48; Tue, 31 Mar 2020 02:10:00 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Jcex5ILP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731314AbgCaJJV (ORCPT + 99 others); Tue, 31 Mar 2020 05:09:21 -0400 Received: from mail.kernel.org ([198.145.29.99]:52386 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730948AbgCaJJU (ORCPT ); Tue, 31 Mar 2020 05:09:20 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (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 058BA214D8; Tue, 31 Mar 2020 09:09:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1585645759; bh=QQ8uxzE0m3Qe632C1J+UGb4+Do/hmYs1d9rsBwK0nvU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Jcex5ILPUNbNJYsZIcNZoFz/k0uw2Zln/ieQ8ZgrbOTR7JRLGja3QYt528Ku3Ycrj VtY4S4zPHRxyEuoYZEYcjy0hsdZ0bFzGqSn8C+LlRhys+QFx6CIugfG1TBkN8CcoWL rKszGxwQl0F6b1ij8k9JIMMUz0xh5/TxVtIUC/lk= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hans de Goede , Mika Westerberg , Linus Walleij Subject: [PATCH 5.5 115/170] gpiolib: acpi: Correct comment for HP x2 10 honor_wakeup quirk Date: Tue, 31 Mar 2020 10:58:49 +0200 Message-Id: <20200331085436.389224130@linuxfoundation.org> X-Mailer: git-send-email 2.26.0 In-Reply-To: <20200331085423.990189598@linuxfoundation.org> References: <20200331085423.990189598@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Hans de Goede commit efaa87fa0947d525cf7c075316adde4e3ac7720b upstream. Commit aa23ca3d98f7 ("gpiolib: acpi: Add honor_wakeup module-option + quirk mechanism") added a quirk for some models of the HP x2 10 series. There are 2 issues with the comment describing the quirk: 1) The comment claims the DMI quirk applies to all Cherry Trail based HP x2 10 models. In the mean time I have learned that there are at least 3 models of the HP x2 10 models: Bay Trail SoC + AXP288 PMIC Cherry Trail SoC + AXP288 PMIC Cherry Trail SoC + TI PMIC And this quirk's DMI matches only match the Cherry Trail SoC + TI PMIC SoC, which is good because we want a slightly different quirk for the others. This commit updates the comment to make it clear that the quirk is only for the Cherry Trail SoC + TI PMIC models. 2) The comment says that it is ok to disable wakeup on all ACPI GPIO event handlers, because there is only the one for the embedded-controller events. This is not true, there also is a handler for the special INT0002 device which is related to USB wakeups. We need to also disable wakeups on that one because the device turns of the USB-keyboard built into the dock when closing the lid. The XHCI controller takes a while to notice this, so it only notices it when already suspended, causing a spurious wakeup because of this. So disabling wakeup on all handlers is the right thing to do, but not because there only is the one handler for the EC events. This commit updates the comment to correctly reflect this. Fixes: aa23ca3d98f7 ("gpiolib: acpi: Add honor_wakeup module-option + quirk mechanism") Signed-off-by: Hans de Goede Link: https://lore.kernel.org/r/20200302111225.6641-1-hdegoede@redhat.com Acked-by: Mika Westerberg Signed-off-by: Linus Walleij Signed-off-by: Greg Kroah-Hartman --- drivers/gpio/gpiolib-acpi.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) --- a/drivers/gpio/gpiolib-acpi.c +++ b/drivers/gpio/gpiolib-acpi.c @@ -1345,12 +1345,14 @@ static const struct dmi_system_id gpioli }, { /* - * Various HP X2 10 Cherry Trail models use an external - * embedded-controller connected via I2C + an ACPI GPIO - * event handler. The embedded controller generates various - * spurious wakeup events when suspended. So disable wakeup - * for its handler (it uses the only ACPI GPIO event handler). - * This breaks wakeup when opening the lid, the user needs + * HP X2 10 models with Cherry Trail SoC + TI PMIC use an + * external embedded-controller connected via I2C + an ACPI GPIO + * event handler on INT33FF:01 pin 0, causing spurious wakeups. + * When suspending by closing the LID, the power to the USB + * keyboard is turned off, causing INT0002 ACPI events to + * trigger once the XHCI controller notices the keyboard is + * gone. So INT0002 events cause spurious wakeups too. Ignoring + * EC wakes breaks wakeup when opening the lid, the user needs * to press the power-button to wakeup the system. The * alternative is suspend simply not working, which is worse. */