From: Namhyung Kim <namhyung@gmail.com>
To: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: linux-kernel@vger.kernel.org,
Linux PM list <linux-pm@vger.kernel.org>,
Greg Kroah-Hartman <gregkh@suse.de>,
Russell King <linux@arm.linux.org.uk>,
Alan Stern <stern@rowland.harvard.edu>
Subject: Re: [PATCH 1/4] PM / Sleep: Make pm_op() and pm_noirq_op() return callback pointers
Date: Tue, 13 Dec 2011 22:55:16 +0900 [thread overview]
Message-ID: <1323784516.1455.2.camel@leonhard> (raw)
In-Reply-To: <201112130053.37714.rjw@sisk.pl>
2011-12-13 (화), 00:53 +0100, Rafael J. Wysocki:
> On Monday, December 12, 2011, Namhyung Kim wrote:
> > Rafael J. Wysocki <rjw <at> sisk.pl> writes:
> >
> > >
> > > From: Rafael J. Wysocki <rjw <at> sisk.pl>
> > >
> > > Make the pm_op() and pm_noirq_op() functions return pointers to
> > > appropriate callbacks instead of executing those callbacks and
> > > returning their results.
> > >
> > > This change is required for a subsequent modification that will
> > > execute the corresponding driver callback if the subsystem
> > > callback returned by either pm_op(), or pm_noirq_op() is NULL.
> > >
> >
> > Hello Rafael,
> >
> > How about typedef'ing something like pm_callback_t for readability?
> >
> > typedef int (*pm_callback_t)(struct device *);
> >
> > This way, the code will be easier to read.
>
> Do you mean something like in the patch below? It does look a bit simpler.
>
Yes, indeed. The patch looks better to me. :)
Thanks,
Namhyung Kim
next prev parent reply other threads:[~2011-12-13 13:55 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-09 23:18 [PATCH 0/4] PM: Make the PM core execute driver callbacks if subsystem ones are not present Rafael J. Wysocki
2011-12-09 23:20 ` [PATCH 1/4] PM / Sleep: Make pm_op() and pm_noirq_op() return callback pointers Rafael J. Wysocki
2011-12-12 4:04 ` Namhyung Kim
2011-12-12 23:53 ` Rafael J. Wysocki
2011-12-13 13:55 ` Namhyung Kim [this message]
2011-12-09 23:20 ` [PATCH 2/4] PM: Run the driver callback directly if the subsystem one is not there Rafael J. Wysocki
2011-12-10 14:59 ` Alan Stern
2011-12-10 18:21 ` Rafael J. Wysocki
2011-12-09 23:21 ` [PATCH 3/4] PM / Sleep: Remove forward-only callbacks from platform bus type Rafael J. Wysocki
2011-12-09 23:23 ` [PATCH 4/4] PM / Sleep: Remove forward-only callbacks from AMBA " Rafael J. Wysocki
2011-12-09 23:47 ` [PATCH 0/4] PM: Make the PM core execute driver callbacks if subsystem ones are not present Greg KH
2011-12-09 23:52 ` Rafael J. Wysocki
2011-12-15 22:34 ` [Update][PATCH 0/5] " Rafael J. Wysocki
2011-12-15 22:35 ` [Update][PATCH 1/5] PM / Sleep: Make pm_op() and pm_noirq_op() return callback pointers Rafael J. Wysocki
2011-12-15 22:36 ` [Update][PATCH 2/5] PM: Run the driver callback directly if the subsystem one is not there Rafael J. Wysocki
2011-12-15 22:37 ` [Update][PATCH 3/5] PM / Sleep: Remove forward-only callbacks from platform bus type Rafael J. Wysocki
2011-12-15 22:38 ` [Update][PATCH 4/5] PM / Sleep: Remove forward-only callbacks from AMBA " Rafael J. Wysocki
2011-12-15 22:39 ` [Update][PATCH 5/5] PM: Drop generic_subsys_pm_ops Rafael J. Wysocki
2011-12-15 22:47 ` Rafael J. Wysocki
2011-12-15 23:08 ` [Update][PATCH 0/5] PM: Make the PM core execute driver callbacks if subsystem ones are not present Greg KH
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=1323784516.1455.2.camel@leonhard \
--to=namhyung@gmail.com \
--cc=gregkh@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=rjw@sisk.pl \
--cc=stern@rowland.harvard.edu \
/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