From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_MUTT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B7B86C31E44 for ; Fri, 14 Jun 2019 10:45:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9674C208CA for ; Fri, 14 Jun 2019 10:45:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727365AbfFNKpP (ORCPT ); Fri, 14 Jun 2019 06:45:15 -0400 Received: from mga05.intel.com ([192.55.52.43]:1446 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727018AbfFNKpP (ORCPT ); Fri, 14 Jun 2019 06:45:15 -0400 X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 14 Jun 2019 03:45:14 -0700 X-ExtLoop1: 1 Received: from lahna.fi.intel.com (HELO lahna) ([10.237.72.157]) by fmsmga001.fm.intel.com with SMTP; 14 Jun 2019 03:45:12 -0700 Received: by lahna (sSMTP sendmail emulation); Fri, 14 Jun 2019 13:45:11 +0300 Date: Fri, 14 Jun 2019 13:45:11 +0300 From: Mika Westerberg To: "Rafael J. Wysocki" Cc: Furquan Shaikh , Len Brown , linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, rajatja@google.com Subject: Re: [PATCH] ACPI: PM: Clear wake-up device GPEs before enabling Message-ID: <20190614104511.GC2640@lahna.fi.intel.com> References: <20190516193616.252788-1-furquan@google.com> <13361760.nMXA0SR1Mq@kreacher> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <13361760.nMXA0SR1Mq@kreacher> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo User-Agent: Mutt/1.11.4 (2019-03-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jun 13, 2019 at 10:24:41PM +0200, Rafael J. Wysocki wrote: > This patch may cause events to be missed if the GPE. I guess what you reall mean is > something like the patch below. > > This should allow the kernel to see the events generated before the GPEs are > implicitly enabled, but it should clear them for the explicit users of acpi_enable_gpe(). > > Mika, what do you think? Looks good to me. I also tested this with two TBT systems (Skull Canyon NUC and Dell XPS 9370) using ACPI hotplug and it did not cause any problems if I boot the system with device connected.