linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tony Lindgren <tony@atomide.com>
To: John Ogness <john.ogness@linutronix.de>
Cc: "Chen-Yu Tsai" <wenst@chromium.org>,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	"Jiri Slaby" <jirislaby@kernel.org>,
	"Andy Shevchenko" <andriy.shevchenko@intel.com>,
	"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,
	"Andy Shevchenko" <andriy.shevchenko@linux.intel.com>,
	linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org,
	"Nícolas F. R. A. Prado" <nfraprado@collabora.com>,
	"AngeloGioacchino Del Regno"
	<angelogioacchino.delregno@collabora.com>,
	linux-mediatek@lists.infradead.org
Subject: Re: [PATCH v12 1/1] serial: core: Start managing serial controllers to enable runtime PM
Date: Sat, 3 Jun 2023 08:41:39 +0300	[thread overview]
Message-ID: <20230603054139.GR14287@atomide.com> (raw)
In-Reply-To: <87a5xii33r.fsf@jogness.linutronix.de>

Hi,

* John Ogness <john.ogness@linutronix.de> [230602 10:13]:
> Unfortunately next-20230601 also brought in a series that added
> spinlocking to the 8250 driver. That may be the issue here instead.

I think you're off the hook here with the spinlocking changes :)

My guess right now is that 8250_mtk does not want runtime PM resume called
on probe for some reason, and assumes it won't happen until until in
mtk8250_do_pm()?

Looking at the probe, the driver does pm_runtime_enable(), but then calls
mtk8250_runtime_resume() directly. Not sure what the intention here is.
Maybe adding pm_runtime_set_active() in probe might provide more clues.

When we add the new serial_ctrl and serial_port devices, their runtime PM
functions propagate to the parent 8250_mtk device. And then something goes
wrong, well this is my guess on what's going on..

To me it seems the 8250_mtk should just do pm_runtime_resume_and_get()
instead of mtk8250_runtime_resume(), then do pm_runtime_put() at the end
of the probe?

I don't think 8250_mtk needs to do register access before and after the
serial port registration, but if it does, then adding custom read/write
functions can be done that do not rely on initialized port like
serial_out().

Looking at the kernelci.org test boot results for Linux next [0], seems
this issue is somehow 8250_mtk specific. I don't think the rk3399 boot
issue is serial port related.

Regards,

Tony

[0] https://linux.kernelci.org/test/job/next/branch/master/kernel/next-20230602/plan/baseline/

  reply	other threads:[~2023-06-03  5:41 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-25 11:30 [PATCH v12 1/1] serial: core: Start managing serial controllers to enable runtime PM Tony Lindgren
2023-05-27  8:25 ` Andy Shevchenko
2023-05-30 14:43 ` Greg Kroah-Hartman
2023-06-01 10:04 ` Steven Price
2023-06-01 10:44   ` Tony Lindgren
2023-06-01 10:53     ` Steven Price
2023-06-01 10:57       ` Tony Lindgren
     [not found] ` <CGME20230601110030eucas1p2eed547c326a51a6110100fb50799d136@eucas1p2.samsung.com>
2023-06-01 11:00   ` Marek Szyprowski
2023-06-01 11:11     ` Tony Lindgren
2023-06-01 13:20       ` Tony Lindgren
2023-06-01 14:16         ` Marek Szyprowski
2023-06-01 14:20           ` Tony Lindgren
2023-06-02  8:33 ` Chen-Yu Tsai
2023-06-02  9:27   ` Tony Lindgren
2023-06-02 10:13   ` John Ogness
2023-06-03  5:41     ` Tony Lindgren [this message]
2023-06-03  6:35       ` Tony Lindgren
2023-06-05  6:15         ` Tony Lindgren
2023-06-05 11:28           ` Andy Shevchenko
2023-06-05 12:25             ` Tony Lindgren
2023-06-05 11:34           ` Chen-Yu Tsai
2023-06-05 12:24             ` Tony Lindgren
2023-06-05 13:01               ` Chen-Yu Tsai
2023-06-05 13:18                 ` Tony Lindgren
2023-06-06  9:16                   ` Chen-Yu Tsai
2023-06-06 12:20                     ` Tony Lindgren
2023-06-07  4:46                       ` Chen-Yu Tsai
2023-06-07  7:17                         ` AngeloGioacchino Del Regno
2023-06-07 20:20                         ` Andy Shevchenko
2023-06-03 21:57       ` Sebastian Reichel
2023-06-04  6:04         ` Tony Lindgren
2023-06-05  3:04     ` Chen-Yu Tsai
2023-10-03 11:57 ` Maximilian Luz
2023-10-03 12:14   ` Tony Lindgren
2023-10-03 12:21     ` Tony Lindgren
2023-10-03 22:09       ` Maximilian Luz
2023-10-04  6:17         ` Tony Lindgren
2023-10-04  7:14           ` Johan Hovold
2023-10-04  9:03             ` Tony Lindgren
2023-10-04  9:14               ` Johan Hovold
2023-10-04 10:01                 ` Tony Lindgren
2023-10-04 18:44                   ` Maximilian Luz
2023-10-04  7:39           ` Maximilian Luz

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=20230603054139.GR14287@atomide.com \
    --to=tony@atomide.com \
    --cc=andriy.shevchenko@intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=angelogioacchino.delregno@collabora.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=john.ogness@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=nfraprado@collabora.com \
    --cc=vigneshr@ti.com \
    --cc=wenst@chromium.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).