Linux ACPI
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
To: "Bjørn Mork" <bjorn@mork.no>
Cc: Greg KH <gregkh@linuxfoundation.org>,
	Markus Demleitner <m@tfiu.de>, Lv Zheng <lv.zheng@intel.com>,
	Andreas Lindhe <andreas@lindhe.io>,
	Gjorgji Jankovski <j.gjorgji@gmail.com>,
	Damjan Georgievski <gdamjan@gmail.com>,
	Fernando Chaves <nanochaves@gmail.com>,
	Tomislav Ivek <tomislav.ivek@gmail.com>,
	"Denis P." <theoriginal.skullburner@gmail.com>,
	All applicable <stable@vger.kernel.org>,
	linux-usb@vger.kernel.org,
	"linux-acpi@vger.kernel.org" <linux-acpi@vger.kernel.org>
Subject: Re: [Bug 197863] Thinkpad X240 resume dramatically slower on kernels 4.13+
Date: Mon, 5 Feb 2018 11:55:27 +0100	[thread overview]
Message-ID: <fe58e542-81c6-9c44-8930-7d91120e80cb@intel.com> (raw)
In-Reply-To: <874lmw33fe.fsf@miraculix.mork.no>

On 2/4/2018 9:28 PM, Bjørn Mork wrote:
> Greg KH <gregkh@linuxfoundation.org> writes:
>> On Sat, Feb 03, 2018 at 07:25:54PM +0100, Markus Demleitner wrote:
>>
>>> It's 662591461c4b9a1e3b9b159dbf37648a585ebaae.  To my eyes, it even
>>> looks plausible that it's causing the problematic behaviour, but
>>> since I can't say I understand what I'd be doing if I dabbled with
>>> the change, I've refrained from guessing how to fix it.
>>>
>>> I'm happy to try patches, though.
>> Ok, thanks.  I've added the authors of this patch to the email here,
>> perhaps they have an idea of what is going on?
> This thing made me curious enough to dive into code I don't understand,
> as I have experienced the annoying crazy fan behaviour in resume a few
> times on my X1 Carbon 4th gen.
>
> Maybe I missed something, but it looks like commit
>
>   c3a696b6e8f8 ("ACPI / EC: Use busy polling mode when GPE is not enabled")
>
> introduced suspend/resume busy polling for the "boot EC" unintentionally?
>
> The patch moved acpi_ec_leave_noirq() and acpi_ec_leave_noirq()
> functions outside the #ifdef CONFIG_PM_SLEEP, so they could be reused
> while installing handlers.  But when doing that the
>
>         if (ec == first_ec)
>
> conditions on suspend/resume were silently dropped.  I assume the
> intention might have been to move those intto acpi_ec_suspend_noirq()
> and acpi_ec_resume_noirq() instead? But that didn't happen AFAICS.
>
> Or did I misunderstand this completely?  Not unlikely given that I have
> zero clue about what this code is doing...
>
> But I do wonder if the attached (completely untested!!) patch makes
> things any better?

I don't think so, the macro is needed too.

I'll queue up a full revert of 662591461c4b9a1e3b.

Thanks,
Rafael


       reply	other threads:[~2018-02-05 10:55 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <bug-197863-190391@https.bugzilla.kernel.org/>
     [not found] ` <bug-197863-190391-0fyd51NsnV@https.bugzilla.kernel.org/>
     [not found]   ` <20180129182109.neh34gh7uaxymcb5@victor>
     [not found]     ` <20180130063204.GA8652@kroah.com>
     [not found]       ` <20180203182554.rpjvmjbptuqemul2@victor>
     [not found]         ` <20180204061804.GB31023@kroah.com>
     [not found]           ` <874lmw33fe.fsf@miraculix.mork.no>
2018-02-05 10:55             ` Rafael J. Wysocki [this message]
2018-02-05 14:14               ` [Bug 197863] Thinkpad X240 resume dramatically slower on kernels 4.13+ Bjørn Mork
2018-02-05 17:06                 ` Rafael J. Wysocki
2018-02-07 22:44                   ` Rafael J. Wysocki
2018-02-08 19:12                     ` Rafael J. Wysocki
2018-02-09 13:43                       ` Markus Demleitner
2018-02-09 21:26                         ` Rafael J. Wysocki
2018-02-09 21:55               ` [PATCH] ACPI / EC: Restore polling during noirq suspend/resume phases Rafael J. Wysocki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fe58e542-81c6-9c44-8930-7d91120e80cb@intel.com \
    --to=rafael.j.wysocki@intel.com \
    --cc=andreas@lindhe.io \
    --cc=bjorn@mork.no \
    --cc=gdamjan@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=j.gjorgji@gmail.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=lv.zheng@intel.com \
    --cc=m@tfiu.de \
    --cc=nanochaves@gmail.com \
    --cc=stable@vger.kernel.org \
    --cc=theoriginal.skullburner@gmail.com \
    --cc=tomislav.ivek@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox