From: Julien Massot <julien.massot@iot.bzh>
To: Geert Uytterhoeven <geert@linux-m68k.org>,
Mathieu Poirier <mathieu.poirier@linaro.org>
Cc: "Björn Andersson" <bjorn.andersson@linaro.org>,
"Rob Herring" <robh+dt@kernel.org>,
Linux-Renesas <linux-renesas-soc@vger.kernel.org>,
"open list:REMOTE PROCESSOR (REMOTEPROC) SUBSYSTEM"
<linux-remoteproc@vger.kernel.org>,
"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS"
<devicetree@vger.kernel.org>
Subject: Re: [RFC PATCH 3/3] remoteproc: Add Renesas rcar driver
Date: Mon, 15 Nov 2021 14:30:34 +0100 [thread overview]
Message-ID: <9ba66a3c-2a0e-9f1c-a8eb-e99a8867938e@iot.bzh> (raw)
In-Reply-To: <CAMuHMdWZTXp5O56wkf3Lesd4jDv4tvhpKfagq3uUW5qNTNYdOQ@mail.gmail.com>
Hi Geert, Mathieu,
Thanks for the review
On 11/9/21 09:09, Geert Uytterhoeven wrote:
> On Mon, Nov 8, 2021 at 7:42 PM Mathieu Poirier
> <mathieu.poirier@linaro.org> wrote:
>> On Wed, Oct 27, 2021 at 09:30:20AM +0200, Julien Massot wrote:
>>> Renesas Gen3 platform includes a Cortex-r7 processor.
>>>
>>> Both: the application cores (A5x) and the realtime core (CR7)
>>> share access to the RAM and devices with the same address map,
>>> so device addresses are equal to the Linux physical addresses.
>>>
>>> In order to initialize this remote processor we need to:
>>> - power on the realtime core
>>> - put the firmware in a ram area
>>> - set the boot address for this firmware (reset vector)
>>> - Deassert the reset
>>>
>>> This initial driver allows to start and stop the Cortex R7
>>> processor.
>>>
>>> Signed-off-by: Julien Massot <julien.massot@iot.bzh>
>
>>> --- a/drivers/remoteproc/Kconfig
>>> +++ b/drivers/remoteproc/Kconfig
>>> @@ -261,6 +261,17 @@ config QCOM_WCNSS_PIL
>>> verified and booted with the help of the Peripheral Authentication
>>> System (PAS) in TrustZone.
>>>
>>> +config RCAR_REMOTEPROC
>>> + tristate "Renesas RCAR remoteproc support"
>>
>> It is probably a good idea to include the type of SoC being supported, something
>> like:
>>
>> tristate "Renesas Gen3 RCAR remoteproc support"
>
> R-Car Gen3 please
Thanks changed to "Renesas R-Car Gen3 remoteproc support".
>>
>>> + priv->dev = dev;
>>> +
>>> + priv->rst = devm_reset_control_get_exclusive(&pdev->dev, NULL);
>>> + if (IS_ERR(priv->rst)) {
>>> + ret = PTR_ERR(priv->rst);
>>> + dev_err(dev, "fail to acquire rproc reset\n");
>>> + goto free_rproc;
>>> + }
>>> +
>>> + pm_runtime_enable(priv->dev);
>>> + ret = pm_runtime_get_sync(priv->dev);
>>
>> There is no dev_pm_ops for the platform driver nor clocks to manage for this
>> device - is there something that requires pm_runtime operations to be called?
>
> Given
>
> cr7_rproc: cr7 {
> compatible = "renesas,rcar-cr7";
> memory-region = <&cr7_ram>;
> power-domains = <&sysc R8A7795_PD_CR7>;
> resets = <&cpg 222>;
> status = "okay";
> };
>
> the pm_runtime_get_sync() is intended to power the CR7 power domain,
> right?
That's exactly why I'm calling pm_runtime_get_sync. The Cortex R7 power domain
needs to be enabled.
> However, I have my doubt about the (bindings for) that node, as it
> does not represent the hardware. Shouldn't the Cortex R7 have its
> own CPU node instead, with an appropriate enable-method?
Yes, representation is really from Remoteproc point of view, the Cortex R7 is
represented as other devices, and doesn't have a cpu node. As far I know it's
how others remoteproc CPUs are described in other SoCs such as ST, Qcom, TI, or NXP
SoCs. From what I see, CPU nodes are given for binary compatible CPUs where Linux can
execute on.
Regards,
--
Julien Massot [IoT.bzh]
next prev parent reply other threads:[~2021-11-15 13:32 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-27 7:30 [RFC PATCH 0/3] Initial Renesas R-Car remoteproc support Julien Massot
2021-10-27 7:30 ` [RFC PATCH 1/3] dt-bindings: remoteproc: Add Renesas R-Car Julien Massot
2021-10-27 14:12 ` Rob Herring
2021-11-15 13:34 ` Julien Massot
2021-10-27 7:30 ` [RFC PATCH 2/3] arm64: dts: renesas: r8a77951: Add CR7 realtime processor Julien Massot
2021-10-27 7:30 ` [RFC PATCH 3/3] remoteproc: Add Renesas rcar driver Julien Massot
2021-11-08 18:42 ` Mathieu Poirier
2021-11-09 8:09 ` Geert Uytterhoeven
2021-11-15 13:30 ` Julien Massot [this message]
2021-11-15 13:17 ` Julien Massot
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=9ba66a3c-2a0e-9f1c-a8eb-e99a8867938e@iot.bzh \
--to=julien.massot@iot.bzh \
--cc=bjorn.andersson@linaro.org \
--cc=devicetree@vger.kernel.org \
--cc=geert@linux-m68k.org \
--cc=linux-remoteproc@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=mathieu.poirier@linaro.org \
--cc=robh+dt@kernel.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).