public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Vinod Koul <vinod.koul@intel.com>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: "Subhransu S. Prusty" <subhransu.s.prusty@intel.com>,
	"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
	Ulf Hansson <ulf.hansson@linaro.org>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] PM: Add helper to mark last busy and autosuspend
Date: Tue, 16 Sep 2014 23:01:20 +0530	[thread overview]
Message-ID: <20140916173120.GT3131@intel.com> (raw)
In-Reply-To: <Pine.LNX.4.44L0.1409161318510.1166-100000@iolanthe.rowland.org>

On Tue, Sep 16, 2014 at 01:22:11PM -0400, Alan Stern wrote:
> On Tue, 16 Sep 2014, Vinod Koul wrote:
> 
> > > > > What's the advantage?  Removing a few bytes of source code?  There will 
> > > > > no change to the object code.  (Not to mention that your patch didn't 
> > > > > actually change _any_ of the places where both routines get called!)
> > > > Yes we didnt change users, as we need this for one of our drivers we are
> > > > trying to push.
> > > 
> > > Why do you need it?  Just change your driver to call
> > > 
> > > 	pm_runtime_mark_last_busy(dev);
> > > 	pm_runtime_put_autosuspend(dev);
> > > 
> > > instead of
> > > 
> > > 	pm_runtime_last_busy_and_autosuspend(dev);
> > > 
> > > Or create a subroutine in your driver to do this.
> > Well since this is common why not add a helper in framework!
> 
> You said this was common, but you didn't change any of the other places
> these routines get used.  I asked why and you didn't asnwer; all you
> said was that you needed it for one of your drivers.
I didnt say we wont change users either. If you do a quick search you would
see a good numbers of folks who are using above and also have their own
helpers.

> I then pointed out that you don't need it.  You didn't asnwer.
Since we have lot of users as well as my driver which we have already posted
we would like this to be in framwork
 
> I asked what advantage this change brings.  You didn't answer.
IMHO helpers like these should be part of framework rather than everyone
having their own versions!
Yes it doesnt change the object code at all, but will reduce LOC and driver
macros

Hope this explains your questions, Will come back witha a v2 with users
converted as well

-- 
~Vinod

      reply	other threads:[~2014-09-16 17:56 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-16 10:43 [PATCH] PM: Add helper to mark last busy and autosuspend Subhransu S. Prusty
2014-09-16 14:27 ` Alan Stern
2014-09-16 15:14   ` Vinod Koul
2014-09-16 15:58     ` Alan Stern
2014-09-16 15:36       ` Vinod Koul
2014-09-16 17:22         ` Alan Stern
2014-09-16 17:31           ` Vinod Koul [this message]

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=20140916173120.GT3131@intel.com \
    --to=vinod.koul@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rafael.j.wysocki@intel.com \
    --cc=stern@rowland.harvard.edu \
    --cc=subhransu.s.prusty@intel.com \
    --cc=ulf.hansson@linaro.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