linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Todd E Brandt <todd.e.brandt@linux.intel.com>
To: James Bottomley <James.Bottomley@HansenPartnership.com>
Cc: linux-scsi@vger.kernel.org
Subject: Re: [PATCH/RESEND 2/2] Hard disk S3 resume time optimization
Date: Fri, 6 Sep 2013 15:11:53 -0700	[thread overview]
Message-ID: <20130906221152.GA7205@linux.intel.com> (raw)
In-Reply-To: <1378480234.2063.16.camel@dabdike.int.hansenpartnership.com>

Sorry for the missing description, I've submitted it several times so I
just assumed that the previous entries in the thread were enough. I'll
resubmit with a full description.

As for replacing sd_resume altogether, the reason I didn't is because
there are three callbacks which use sd_resume. I've only tested this
functionality for the system resume call, not restore or runtime_resume,
and I didn't know if the other two made sense as asynchronous since
it doesn't really buy anything in runtime_resume, but I understand your
point that it adds unnecessary complexity. I'll fix it.

I'm sure there are no issues but I'll be sure and test all the new scenerios 
before I resubmit.

So, with fixes to those two issues, do you think this technique is something 
you'd accept? I've tried it two different ways, one where I changed the pm
code to allow nonblocking resume callbacks, which just finalized system 
resume without waiting for the ata and scsi drivers to finish. But that 
didn't fly well with Rafael as it violates some implicit assumptions 
about how the callbacks function. I worked with Rafael to come up with a 
"skip_resume" version which just skipped the system resume of the disks, 
changed them to runtime suspended, and let them runtime resume whenever 
they were accessed, but it proved to be impractical in a real OS environment 
because the OS tends to access everything at once when it comes back online.

This approach is really the only remaining way (that I can think of) to 
remove the ata-port wakeup delay in software, so given the massive 
performance benefit I hope you'll consider it. Thanks for the reply!

On Fri, Sep 06, 2013 at 08:10:34AM -0700, James Bottomley wrote:
> On Thu, 2013-09-05 at 17:44 -0700, Todd E Brandt wrote:
> > Part 2 of the hard disk resume optimization patch, this one applies
> > to the scsi subsystem.
> 
> This is a horrible patch description, it won't tell the next reader
> anything about what is going on and why.  Give the patches two separate
> summaries and refer back by summary explaining what this one does.
> 
> Also, having two code paths do the same thing is always a bad idea:
> someone will update one and not the other.  sd_resume() should be come
> sd_resume_async(); wait for async event
> 
> James
> 
> 

  reply	other threads:[~2013-09-06 22:11 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-06  0:44 [PATCH/RESEND 2/2] Hard disk S3 resume time optimization Todd E Brandt
2013-09-06 12:37 ` Sergei Shtylyov
2013-09-06 22:13   ` Todd E Brandt
2013-09-06 15:10 ` James Bottomley
2013-09-06 22:11   ` Todd E Brandt [this message]
2013-09-06 17:03 ` Bartlomiej Zolnierkiewicz
2013-09-06 22:19   ` 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=20130906221152.GA7205@linux.intel.com \
    --to=todd.e.brandt@linux.intel.com \
    --cc=James.Bottomley@HansenPartnership.com \
    --cc=linux-scsi@vger.kernel.org \
    /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).