From: Tony Lindgren <tony@atomide.com>
To: Andy Shevchenko <andriy.shevchenko@intel.com>
Cc: "Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>,
"Jiri Slaby" <jirislaby@kernel.org>,
"Johan Hovold" <johan@kernel.org>,
"Sebastian Andrzej Siewior" <bigeasy@linutronix.de>,
"Vignesh Raghavendra" <vigneshr@ti.com>,
linux-serial@vger.kernel.org, linux-omap@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH v4 1/1] serial: core: Start managing serial controllers to enable runtime PM
Date: Thu, 8 Dec 2022 08:06:30 +0200 [thread overview]
Message-ID: <Y5F+5kAAr7pMeGWE@atomide.com> (raw)
In-Reply-To: <Y5F7i8Ee/jAQKu9n@atomide.com>
* Tony Lindgren <tony@atomide.com> [221208 05:52]:
> * Andy Shevchenko <andriy.shevchenko@intel.com> [221207 20:28]:
> > We can avoid this check by caching the platform device.
> >
> > struct platform_device *ctrl_pdev = NULL;
> >
> > if (...) {
> > ctrl_pdev = to_platform_device(ctrl_dev);
> > }
> >
> > platform_device_del(ctrl_pdev);
>
> OK yeah that's nicer :)
>
> > > Shouldn't you call platform_device_unregister()?
>
> Outside the error path it should be platform_device_unregister(),
> I'll check. Thanks also for your other comments.
To me looks like we should just use platform_device_unregister()
in call cases here like you noted.
Regards,
Tony
next prev parent reply other threads:[~2022-12-08 6:06 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-07 12:43 [RFC PATCH v4 1/1] serial: core: Start managing serial controllers to enable runtime PM Tony Lindgren
2022-12-07 20:22 ` Andy Shevchenko
2022-12-07 20:28 ` Andy Shevchenko
2022-12-08 5:52 ` Tony Lindgren
2022-12-08 6:06 ` Tony Lindgren [this message]
2022-12-08 9:12 ` Ilpo Järvinen
2022-12-08 10:15 ` Tony Lindgren
2022-12-08 10:48 ` Ilpo Järvinen
2022-12-08 11:13 ` Tony Lindgren
2022-12-12 7:09 ` Tony Lindgren
2022-12-12 12:49 ` Ilpo Järvinen
2022-12-12 12:53 ` Tony Lindgren
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=Y5F+5kAAr7pMeGWE@atomide.com \
--to=tony@atomide.com \
--cc=andriy.shevchenko@intel.com \
--cc=bigeasy@linutronix.de \
--cc=gregkh@linuxfoundation.org \
--cc=ilpo.jarvinen@linux.intel.com \
--cc=jirislaby@kernel.org \
--cc=johan@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=vigneshr@ti.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).