linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Michael Tretter <m.tretter@pengutronix.de>
To: Rajan Vaja <RAJANV@xilinx.com>
Cc: "linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>,
	 Michal Simek <michals@xilinx.com>,
	Jolly Shah <JOLLYS@xilinx.com>
Subject: Re: [PATCH 0/4] soc: xilinx: pm_domains: cleanup and fix PM_INIT_FINALIZE
Date: Mon, 19 Apr 2021 09:32:39 +0200	[thread overview]
Message-ID: <20210419073239.GA12636@pengutronix.de> (raw)
In-Reply-To: <BYAPR02MB394191514C07A76D037D1618B74D9@BYAPR02MB3941.namprd02.prod.outlook.com>

Hi Rajan,

On Thu, 15 Apr 2021 16:27:58 +0000, Rajan Vaja wrote:
> Thanks for the patch.
> 
> > -----Original Message-----
> > From: Michael Tretter <m.tretter@pengutronix.de>
> > Sent: 17 March 2021 09:34 PM
> > To: linux-arm-kernel@lists.infradead.org
> > Cc: Michal Simek <michals@xilinx.com>; Rajan Vaja <RAJANV@xilinx.com>; Jolly
> > Shah <JOLLYS@xilinx.com>; m.tretter@pengutronix.de
> > Subject: [PATCH 0/4] soc: xilinx: pm_domains: cleanup and fix PM_INIT_FINALIZE
> > 
> > Patch 1 of this series fixes the ZynqMP PMU FW power management
> > initialization, which was done by the wrong driver. PM_INIT_FINALIZE must be
> > called from the zynqmp_pm_domains driver, which handles power domains, instead
> > of the zynmp_power driver, which is responsible for suspend and shutdown.
> [Rajan] I am fine with moving to genpd but zynqmp_pm_init_finalize() needs to be late call.
> zynqmp_pm_init_finalize() should be called when Linux has requested all the devices through
> genpd driver. Making it late call will make sure it. 

What is the reason why all devices have to be requested before calling
zynqmp_pm_init_finalize()?

I was expecting that calling PM_INIT_FINALIZE only would tell the PMU_FW that
Linux is using the PM API and the PMU_FW should power down/up PM slaves as
requested by Linux. It is somewhat surprising that this isn't the case and all
PM slaves have to be powered up before calling PM_INIT_FINALIZE.

What would happen if some driver is built as a module? In that case, the
module would be loaded and request the pm node only after PM_INIT_FINALIZE was
called. Do we have to avoid/disallow such cases?

For USB, I am actually observing a similar situation: If I do not request the
USB PM slave before I call PM_INIT_FINALIZE, I see communication errors with
connected USB devices. Could this be related?

Thanks,

Michael

> 
> > 
> > Patches 2 to 4 are various cleanup patches to improve the readability and
> > debugging experience of the zynqmp_pm_domains driver.
> > 
> > Michael
> > 
> > Michael Tretter (4):
> >   soc: xilinx: move PM_INIT_FINALIZE to zynqmp_pm_domains driver
> >   soc: xilinx: cleanup debug and error messages
> >   soc: xilinx: use a properly named field instead of flags
> >   soc: xilinx: add a to_zynqmp_pm_domain macro
> > 
> >  drivers/soc/xilinx/zynqmp_pm_domains.c | 79 +++++++++++++-------------
> >  drivers/soc/xilinx/zynqmp_power.c      |  1 -
> >  2 files changed, 38 insertions(+), 42 deletions(-)
> > 
> > --
> > 2.29.2

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2021-04-19  7:35 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-17 16:04 [PATCH 0/4] soc: xilinx: pm_domains: cleanup and fix PM_INIT_FINALIZE Michael Tretter
2021-03-17 16:04 ` [PATCH 1/4] soc: xilinx: move PM_INIT_FINALIZE to zynqmp_pm_domains driver Michael Tretter
2021-03-17 16:04 ` [PATCH 2/4] soc: xilinx: cleanup debug and error messages Michael Tretter
2021-03-17 16:04 ` [PATCH 3/4] soc: xilinx: use a properly named field instead of flags Michael Tretter
2021-03-17 16:04 ` [PATCH 4/4] soc: xilinx: add a to_zynqmp_pm_domain macro Michael Tretter
2021-04-15 16:27 ` [PATCH 0/4] soc: xilinx: pm_domains: cleanup and fix PM_INIT_FINALIZE Rajan Vaja
2021-04-19  7:32   ` Michael Tretter [this message]
2021-04-19 12:29     ` Rajan Vaja
2021-04-20 14:18     ` Sudeep Holla
2021-04-28 13:17       ` Michal Simek
2021-06-01  8:49         ` Michael Tretter
2021-06-01  9:17           ` Rajan Vaja

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=20210419073239.GA12636@pengutronix.de \
    --to=m.tretter@pengutronix.de \
    --cc=JOLLYS@xilinx.com \
    --cc=RAJANV@xilinx.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=michals@xilinx.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).