From: Phillip Susi <psusi@ubuntu.com>
To: todd.e.brandt@linux.intel.com, tj@kernel.org,
James.Bottomley@HansenPartnership.com
Cc: linux-ide@vger.kernel.org, linux-scsi@vger.kernel.org
Subject: Re: [PATCH/RESEND v2 1/2] Hard disk S3 resume time optimization
Date: Thu, 09 Jan 2014 12:03:58 -0500 [thread overview]
Message-ID: <52CED67E.7080706@ubuntu.com> (raw)
In-Reply-To: <20140108005607.GB29556@linux.intel.com>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 1/7/2014 7:56 PM, Todd E Brandt wrote:
> On resume, the ATA port driver currently waits until the AHCI
> controller finishes executing the port wakeup command. This patch
> changes the ata_port_resume callback to issue the wakeup and then
> return immediately, thus allowing the next device in the pm queue
> to resume. Any commands issued to the AHCI hardware during the
> wakeup will be queued up and executed once the port is physically
> online. Thus no information is lost.
>
> This patch only changes the behavior of the resume callback, not
> restore, thaw, or runtime-resume. This is because thaw and restore
> are used after a suspend-to-disk, which means that an image needs
> to be read from swap and reloaded into RAM. The swap disk will
> always need to be fully restored/thawed in order for resume to
> continue.
>
> The return value from ata_resume_async is now an indicator of
> whether the resume was initiated, rather than if it was completed.
> I'm letting the ata driver assume control over its own error
> reporting in this case (which it does already). If you look at the
> ata_port resume code you'll see that the ata_port_resume callback
> returns the status of the ahci_port_resume callback, which is
> always 0. So I don't see any harm in ignoring it.
>
> If somebody requests suspend while ATA port resume is still
> running, the request is queued until the resume has completed. I've
> tested that case very heavily. Basically if you do two suspends in
> a row (within seconds of each other) you lose any performance
> benefit, but that's a use case that should happen only very rarerly
> (and wouldn't be expected to be of any power benefit since too many
> sequential suspends actually takes more power than just letting the
> machine stay in run mode).
I think my patch for this "libata: resume in the background" was a LOT
simpler. It just used the existing behavior of becoming async when
the async argument was !NULL, and fixed the one caller that didn't
actually care about the result to pass in a pointer anyhow.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iQEcBAEBAgAGBQJSztZ+AAoJEI5FoCIzSKrwQ6QH/jA1kIDsDC5LBQDGtDjZ/cvB
hLddAkDmqswfMXDmtD+u5lQuc+a0GbjINvrMYtq6bilDuPO39ccR//jUL69PULDo
qcn3RMjzSIIqyfCiKj6iAIZyuTTR9SLgA9F9V2b0RBPn1FFD84y+qEitzrqb+/z6
pBjVYbbjfpj+Sfr00dbk7a6BTzB2FHTSEwA/Kv5gM2MJKGPrjmML8awl3gSG+lGT
mOYV8yR+kycrnkp8Rcr+7hNb6LfJlKWBh33UA4TKxrE5WZg0nX+kU83BoCpRgvCm
nfYynvakJ1E0Wz2fiYQq1NeNy1ZUZ7iyDdsl70KslaAhPFBQUH/tsoXL1syHSRo=
=rXVR
-----END PGP SIGNATURE-----
next prev parent reply other threads:[~2014-01-09 17:04 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-08 0:56 [PATCH/RESEND v2 1/2] Hard disk S3 resume time optimization Todd E Brandt
2014-01-09 17:03 ` Phillip Susi [this message]
2014-01-10 23:11 ` Brandt, Todd E
2014-01-11 2:13 ` Phillip Susi
2014-01-11 3:13 ` Dan Williams
2014-01-13 20:06 ` Todd E Brandt
2014-01-13 20:37 ` Dan Williams
2014-01-13 23:51 ` Todd E Brandt
2014-01-14 0:05 ` Dan Williams
2014-01-11 19:13 ` Tejun Heo
2014-01-13 19:55 ` Todd E Brandt
2014-01-13 20:30 ` Tejun Heo
2014-01-13 23:30 ` Todd E Brandt
2014-01-14 14:31 ` Tejun Heo
2014-01-15 0:31 ` [PATCH v3 0/2] " Todd E Brandt
2014-01-15 12:55 ` Tejun Heo
2014-01-15 0:31 ` [PATCH v3 1/2] " Todd E Brandt
2014-01-15 13:01 ` Tejun Heo
2014-01-15 20:04 ` Todd E Brandt
2014-01-15 0:32 ` [PATCH v3 2/2] " Todd E Brandt
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=52CED67E.7080706@ubuntu.com \
--to=psusi@ubuntu.com \
--cc=James.Bottomley@HansenPartnership.com \
--cc=linux-ide@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=tj@kernel.org \
--cc=todd.e.brandt@linux.intel.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;
as well as URLs for NNTP newsgroup(s).