Re: [PATCH v12 1/1] serial: core: Start managing serial controllers to enable runtime PM
From: Johan Hovold
Date: Wed Oct 04 2023 - 05:14:18 EST
On Wed, Oct 04, 2023 at 12:03:20PM +0300, Tony Lindgren wrote:
> * Johan Hovold <johan@xxxxxxxxxx> [231004 07:14]:
> > The pm_runtime_get_sync() in serdev_device_open() is supposed to prevent
> > that from happening by default and if that now longer works, then that
> > needs to be fixed.
>
> No changes there, that all should work just as before.
Well, it clearly does not work as before.
> What is broken is that the new serial port device can autosuspend while
> the serdev device is active. This prevents serial tx in the suspend
> path.
>
> The serial port device and serdev device are siblings of the physical
> serial port controller device as seen in the hierarcy printed out by
> Maximilian.
Yeah, and that's precisely the broken part. Keeping the serdev
controller active is supposed to keep the serial controller active. Your
serial core rework appears to have broken just that.
The new "devices" that you've added (I have still not tried to
understand why that was even needed, it looks overly complicated) must
not change that.
If the serdev controller is active, tx should just work (as it did
before).
Johan