linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tony Lindgren <tony@atomide.com>
To: Andy Shevchenko <andriy.shevchenko@intel.com>
Cc: "Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	"Jiri Slaby" <jirislaby@kernel.org>,
	"Dhruva Gole" <d-gole@ti.com>,
	"Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>,
	"Johan Hovold" <johan@kernel.org>,
	"Sebastian Andrzej Siewior" <bigeasy@linutronix.de>,
	"Vignesh Raghavendra" <vigneshr@ti.com>,
	linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-serial@vger.kernel.org
Subject: Re: [PATCH v10 1/1] serial: core: Start managing serial controllers to enable runtime PM
Date: Mon, 8 May 2023 16:35:03 +0300	[thread overview]
Message-ID: <20230508133503.GX14287@atomide.com> (raw)
In-Reply-To: <ZFjm3/aKHNKch1lA@smile.fi.intel.com>

* Andy Shevchenko <andriy.shevchenko@intel.com> [230508 12:11]:
> On Mon, May 08, 2023 at 02:03:35PM +0300, Tony Lindgren wrote:
> > We want to enable runtime PM for serial port device drivers in a generic
> > way. To do this, we want to have the serial core layer manage the
> > registered physical serial controller devices.
> > 
> > To do this, let's set up a struct bus and struct device for the serial
> > core controller as suggested by Greg and Jiri. The serial core controller
> > devices are children of the physical serial port device. The serial core
> > controller device is needed to support multiple different kind of ports
> > connected to single physical serial port device.
> > 
> > Let's also set up a struct device for the serial core port. The serial
> > core port instances are children of the serial core controller device.
> > 
> > With the serial core port device we can now flush pending TX on the
> > runtime PM resume as suggested by Johan.
> 
> Sorry, I'm on vacation. But just brief comments below.
> In general looks good to me.

OK have a nice vacation :)

> > -obj-$(CONFIG_SERIAL_CORE) += serial_core.o
> > +obj-$(CONFIG_SERIAL_CORE) += serial_base.o
> > +serial_base-objs := serial_core.o serial_base_bus.o serial_ctrl.o serial_port.o
> 
> 'objs' is for user space tools, kernel should use 'y'

Oh OK.

> > +static DEFINE_RUNTIME_DEV_PM_OPS(serial_port_pm, NULL,
> > +				 serial_port_runtime_resume, NULL);
> 
> Maybe
> 
> static DEFINE_RUNTIME_DEV_PM_OPS(serial_port_pm,
> 				 NULL, serial_port_runtime_resume, NULL);
> 
> for better logical split?

Sure.

Thanks,

Tony

  reply	other threads:[~2023-05-08 13:35 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-08 11:03 [PATCH v10 1/1] serial: core: Start managing serial controllers to enable runtime PM Tony Lindgren
2023-05-08 12:11 ` Andy Shevchenko
2023-05-08 13:35   ` Tony Lindgren [this message]
2023-05-08 23:13 ` kernel test robot
2023-05-09  6:57   ` 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=20230508133503.GX14287@atomide.com \
    --to=tony@atomide.com \
    --cc=andriy.shevchenko@intel.com \
    --cc=bigeasy@linutronix.de \
    --cc=d-gole@ti.com \
    --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).