From: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
To: Phil Elwell <phil@raspberrypi.com>
Cc: Florian Fainelli <f.fainelli@gmail.com>,
linux-kernel@vger.kernel.org, Ray Jui <rjui@broadcom.com>,
Scott Branden <sbranden@broadcom.com>,
"maintainer:BROADCOM BCM7XXX ARM ARCHITECTURE"
<bcm-kernel-feedback-list@broadcom.com>,
"moderated list:BROADCOM BCM2711/BCM2835 ARM ARCHITECTURE"
<linux-rpi-kernel@lists.infradead.org>,
wahrenst@gmx.net, linux-arm-kernel@lists.infradead.org,
mripard@kernel.org, eric@anholt.net
Subject: Re: [RFC/PATCH v2 09/16] soc: bcm: bcm2835-power: Add support for BCM2711's Argon ASB
Date: Tue, 09 Feb 2021 15:00:18 +0100 [thread overview]
Message-ID: <56e237a8d0646c03d4ff44e439d1b0f81c800a9b.camel@suse.de> (raw)
In-Reply-To: <CAMEGJJ3i_hEAnO4rDQ+emqB=OYXetLyKh1kMRwAbUnYZ1e48VA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 2735 bytes --]
On Tue, 2021-02-09 at 13:19 +0000, Phil Elwell wrote:
> Hi Nicolas,
>
> On Tue, 9 Feb 2021 at 13:00, Nicolas Saenz Julienne
> <nsaenzjulienne@suse.de> wrote:
> >
> > In BCM2711 the new ARGON ASB took over V3D. The old ASB is still present
> > with the ISP and H264 bits, and V3D is in the same place in the new ASB
> > as the old one.
> >
> > Use the fact that 'pm->argon_asb' is populated as a hint that we're on
> > BCM2711. On top of that introduce the macro ASB_BASE() which will select
> > the correct ASB register base, based on whether we're trying to access
> > V3D and which platform we're on.
>
> Please don't refer to this block as ARGON - it is the IP of Raspberry
> Pi Trading and it's name is RPiVid.
OK, sorry for that. I, again, mixed both ASB names. I'll rename the Argon ASB
to RPiVid. How should I call the one present in older RPis?
> > Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> >
> > ---
> >
> > Changes since v1:
> > - Correct names
> >
> > drivers/soc/bcm/bcm2835-power.c | 68 ++++++++++++++++++++-------------
> > 1 file changed, 42 insertions(+), 26 deletions(-)
> >
> > diff --git a/drivers/soc/bcm/bcm2835-power.c b/drivers/soc/bcm/bcm2835-power.c
> > index 59b8abfc5617..42e105758b47 100644
> > --- a/drivers/soc/bcm/bcm2835-power.c
[...]
> > case BCM2835_POWER_DOMAIN_USB:
> > PM_WRITE(PM_USB, 0);
> > @@ -626,13 +633,22 @@ static int bcm2835_power_probe(struct platform_device *pdev)
> > power->dev = dev;
> > power->base = pm->base;
> > power->rpivid_asb = pm->rpivid_asb;
> > + power->argon_asb = pm->argon_asb;
> >
> > - id = ASB_READ(ASB_AXI_BRDG_ID);
> > + id = ASB_READ(ASB_AXI_BRDG_ID, false);
> > if (id != 0x62726467 /* "BRDG" */) {
> > - dev_err(dev, "ASB register ID returned 0x%08x\n", id);
> > + dev_err(dev, "RPiVid ASB register ID returned 0x%08x\n", id);
> > return -ENODEV;
> > }
> >
> > + if (pm->argon_asb) {
> > + id = ASB_READ(ASB_AXI_BRDG_ID, true);
> > + if (id != 0x62726467 /* "BRDG" */) {
> > + dev_err(dev, "Argon ASB register ID returned 0x%08x\n", id);
> > + return -ENODEV;
> > + }
> > + }
> > +
>
> Surely these are the same register. Is this the result of a bad merge?
AFAIU There are two ASBs the old one at 0x7e00a000 and the new RPiVid one at
0x7ec11000. They both can be checked for valid IDs. Note the new argument in
ASB_READ().
Regards,
Nicolas
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2021-02-09 14:02 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-09 12:58 [RFC/PATCH v2 00/16] Raspberry PI 4 V3D enablement Nicolas Saenz Julienne
2021-02-09 12:58 ` [RFC/PATCH v2 01/16] dt-bindings: soc: bcm: bcm2835-pm: Convert bindings to DT schema Nicolas Saenz Julienne
2021-02-10 22:26 ` Rob Herring
2021-02-09 12:58 ` [RFC/PATCH v2 02/16] dt-bindings: soc: bcm: bcm2835-pm: Introduce reg-names Nicolas Saenz Julienne
2021-02-10 22:44 ` Rob Herring
2021-02-09 12:58 ` [RFC/PATCH v2 03/16] dt-bindings: soc: bcm: bcm2835-pm: Add support for bcm2711 Nicolas Saenz Julienne
2021-02-10 22:44 ` Rob Herring
2021-02-09 12:59 ` [RFC/PATCH v2 04/16] ARM: dts: bcm2835/bcm2711: Introduce reg-names in watchdog node Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 05/16] ARM: dts: bcm2711: Use proper compatible in PM/Watchdog node Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 06/16] mfd: bcm2835-pm: Rename asb to rpivid_asb Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 07/16] mfd: bcm2835-pm: Use 'reg-names' to get resources Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 08/16] mfd: bcm2835-pm: Add support for BCM2711 Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 09/16] soc: bcm: bcm2835-power: Add support for BCM2711's Argon ASB Nicolas Saenz Julienne
2021-02-09 13:19 ` Phil Elwell
2021-02-09 14:00 ` Nicolas Saenz Julienne [this message]
2021-02-09 16:38 ` Phil Elwell
2021-02-09 16:50 ` Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 10/16] soc: bcm: bcm2835-power: Bypass power_on/off() calls Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 11/16] dt-bindings: gpu: v3d: Add BCM2711's compatible Nicolas Saenz Julienne
2021-02-10 22:45 ` Rob Herring
2021-02-09 12:59 ` [RFC/PATCH v2 12/16] drm/v3d: Get rid of pm code Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 13/16] drm/v3d: Add support for bcm2711 Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 14/16] ARM: dts: bcm2711: Enable V3D Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 15/16] ARM: configs: Enable DRM_V3D Nicolas Saenz Julienne
2021-02-09 12:59 ` [RFC/PATCH v2 16/16] arm64: config: " Nicolas Saenz Julienne
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=56e237a8d0646c03d4ff44e439d1b0f81c800a9b.camel@suse.de \
--to=nsaenzjulienne@suse.de \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=eric@anholt.net \
--cc=f.fainelli@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rpi-kernel@lists.infradead.org \
--cc=mripard@kernel.org \
--cc=phil@raspberrypi.com \
--cc=rjui@broadcom.com \
--cc=sbranden@broadcom.com \
--cc=wahrenst@gmx.net \
/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
all inboxes | Powered by JetHome®