From: Geert Uytterhoeven <geert@linux-m68k.org>
To: Ben Dooks <ben.dooks@codethink.co.uk>
Cc: linux-kernel@lists.codethink.co.uk,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
Linux-sh list <linux-sh@vger.kernel.org>,
"David S. Miller" <davem@davemloft.net>
Subject: Re: [PATCH] sh_eth: pm_runtime should not need null operations
Date: Fri, 21 Mar 2014 11:30:16 +0100 [thread overview]
Message-ID: <CAMuHMdWO-kNdWT_AxzAmCTrx3NerWpTG+auFNZTcL5hsbN+++A@mail.gmail.com> (raw)
In-Reply-To: <1395396913-24354-1-git-send-email-ben.dooks@codethink.co.uk>
Hi Ben,
On Fri, Mar 21, 2014 at 11:15 AM, Ben Dooks <ben.dooks@codethink.co.uk> wrote:
> The driver has a no-op for the pm_runtime callbacks but
> the pm_runtime core should correctly ignore drivers without
> any pm_rumtime callback ops.
The pm_runtime core doesn't ignore non-existing runtime_{suspend,resume}
callbacks, it turns them into a failure withv -ENOSYS.
Only non-existing runtime_idle callbacks are ignored.
rpm_suspend():
callback = rpm_get_suspend_cb(dev);
retval = rpm_callback(callback, dev);
if (retval)
goto fail;
(rpm_callback() returns -ENOSYS if !callback).
pm_runtime_force_suspend():
callback = rpm_get_suspend_cb(dev);
if (!callback) {
ret = -ENOSYS;
goto err;
}
Same for resume.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
next prev parent reply other threads:[~2014-03-21 10:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-21 10:15 [PATCH] sh_eth: pm_runtime should not need null operations Ben Dooks
2014-03-21 10:30 ` Geert Uytterhoeven [this message]
2014-03-21 10:57 ` Ben Dooks
2014-03-28 18:22 ` David Miller
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=CAMuHMdWO-kNdWT_AxzAmCTrx3NerWpTG+auFNZTcL5hsbN+++A@mail.gmail.com \
--to=geert@linux-m68k.org \
--cc=ben.dooks@codethink.co.uk \
--cc=davem@davemloft.net \
--cc=linux-kernel@lists.codethink.co.uk \
--cc=linux-sh@vger.kernel.org \
--cc=netdev@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).