[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 7 Jun 2018 01:21:24 +0200
From: "Rafael J. Wysocki" <rafael@...nel.org>
To: Benson Leung <bleung@...gle.com>
Cc: "Rafael J. Wysocki" <rafael@...nel.org>,
Ravi Chandra Sadineni <ravisadineni@...omium.org>,
"Rafael J. Wysocki" <rjw@...ysocki.net>,
Len Brown <lenb@...nel.org>,
Ravi Chandra Sadineni <ravisadineni@...gle.com>,
Dmitry Torokhov <dmitry.torokhov@...il.com>,
Todd Broch <tbroch@...gle.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
ACPI Devel Maling List <linux-acpi@...r.kernel.org>,
Rajat Jain <rajatja@...gle.com>,
Furquan Shaikh <furquan@...omium.org>,
Benson Leung <bleung@...omium.org>
Subject: Re: [PATCH] ACPI LID: increment wakeup count only when notified.
On Thu, Jun 7, 2018 at 1:11 AM, Benson Leung <bleung@...gle.com> wrote:
> Hi Rafael,
>
> On Wed, Jun 06, 2018 at 09:00:43AM +0200, Rafael J. Wysocki wrote:
>> > @@ -417,6 +414,7 @@ static void acpi_button_notify(struct acpi_device *device, u32 event)
>> > /* fall through */
>> > case ACPI_BUTTON_NOTIFY_STATUS:
>> > input = button->input;
>> > + acpi_pm_wakeup_event(&device->dev);
>>
>> Not really.
>>
>> There already is an acpi_pm_wakeup_event() call in the else branch below.
>>
>
> Ravi removes that other call below.
OK, I missed that, not sure why, sorry.
> The intent for this is to call
> acpi_pm_wakeup_event() regardless if the button->type is ACPI_BUTTON_TYPE_LID,
> in case that event is ACPI_BUTTON_NOTIFY_STATUS.
Well, the patch really drops the acpi_pm_wakeup_event() call from
acpi_lid_notify_state() and so it has to ensure that this function
will be called here for ACPI_BUTTON_NOTIFY_STATUS regardless of the
button->type value.
That's fine, but still the changelog doesn't make it clear why the
acpi_pm_wakeup_event() call in acpi_lid_notify_state() is not
necessary in general.
Thanks,
Rafael
Powered by blists - more mailing lists