All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paul Kocialkowski <contact@paulk.fr>
To: Maxime Ripard <maxime@cerno.tech>
Cc: devicetree@vger.kernel.org,
	Matteo Scordino <matteo.scordino@gmail.com>,
	linux-kernel@vger.kernel.org, Chen-Yu Tsai <wens@csie.org>,
	Rob Herring <robh+dt@kernel.org>,
	linux-arm-kernel@lists.infradead.org,
	Icenowy Zheng <icenowy@aosc.io>
Subject: Re: [PATCH 6/9] ARM: dts: sun8i-v3s: Add the V3s NMI IRQ controller
Date: Mon, 2 Nov 2020 17:59:22 +0100	[thread overview]
Message-ID: <20201102165922.GB2037@collins> (raw)
In-Reply-To: <20201102134418.vn7i3e4gpwomxcnj@gilmour.lan>


[-- Attachment #1.1: Type: text/plain, Size: 1852 bytes --]

On Mon 02 Nov 20, 14:44, Maxime Ripard wrote:
> On Mon, Nov 02, 2020 at 11:25:22AM +0100, Paul Kocialkowski wrote:
> > Hi,
> > 
> > On Mon 02 Nov 20, 11:12, Maxime Ripard wrote:
> > > On Sat, Oct 31, 2020 at 07:21:34PM +0100, Paul Kocialkowski wrote:
> > > > The V3s/V3 has a NMI interrupt controller, mainly used for the AXP209.
> > > > Its address follows the sytsem controller block, which was previously
> > > > incorrectly described as spanning over 0x1000 address bytes.
> > > 
> > > Is it after, or right in the middle of it?
> > 
> > That's up for interpretation actually:
> > - The V3 datasheet mentions that System Control is 0x01C00000 --- 0x01C00FFF;
> > - In practice, sunxi_sram.c uses a regmap with max_reg set to 0x30 for the
> >   V3s/H3 so this gives us some room.
> > 
> > Looking at other SoCs with the same setup (take sun8i-r40 for instance),
> > system-control is limited to 0x30 and the NMI controller follows it.
> > In the case of R40, the SRAM controlled is also said to be 4K-long in the
> > Allwinner docs.
> > 
> > So all in all, this leads me to believe that the system-controller instance
> > stops well before 0x1c000d0 on the V3s as well. Otherwise, we should also
> > make the R40 consistent.
> 
> That's a bit unfortunate, but yeah, I guess we want to remain consistent here.

Honestly I think the Allwinner docs are plain wrong on this one.
IIRC they used to describe the NMI as a separate controller in the memory
map. I think they just overlook it now and copy/paste 4K size for each
controller regardless of the actual hardware, so I'm not very worried.

Cheers,

Pauls

-- 
Developer of free digital technology and hardware support.

Website: https://www.paulk.fr/
Coding blog: https://code.paulk.fr/
Git repositories: https://git.paulk.fr/ https://git.code.paulk.fr/

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 176 bytes --]

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

WARNING: multiple messages have this Message-ID (diff)
From: Paul Kocialkowski <contact@paulk.fr>
To: Maxime Ripard <maxime@cerno.tech>
Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, Rob Herring <robh+dt@kernel.org>,
	Chen-Yu Tsai <wens@csie.org>,
	Matteo Scordino <matteo.scordino@gmail.com>,
	Icenowy Zheng <icenowy@aosc.io>
Subject: Re: [PATCH 6/9] ARM: dts: sun8i-v3s: Add the V3s NMI IRQ controller
Date: Mon, 2 Nov 2020 17:59:22 +0100	[thread overview]
Message-ID: <20201102165922.GB2037@collins> (raw)
In-Reply-To: <20201102134418.vn7i3e4gpwomxcnj@gilmour.lan>

[-- Attachment #1: Type: text/plain, Size: 1852 bytes --]

On Mon 02 Nov 20, 14:44, Maxime Ripard wrote:
> On Mon, Nov 02, 2020 at 11:25:22AM +0100, Paul Kocialkowski wrote:
> > Hi,
> > 
> > On Mon 02 Nov 20, 11:12, Maxime Ripard wrote:
> > > On Sat, Oct 31, 2020 at 07:21:34PM +0100, Paul Kocialkowski wrote:
> > > > The V3s/V3 has a NMI interrupt controller, mainly used for the AXP209.
> > > > Its address follows the sytsem controller block, which was previously
> > > > incorrectly described as spanning over 0x1000 address bytes.
> > > 
> > > Is it after, or right in the middle of it?
> > 
> > That's up for interpretation actually:
> > - The V3 datasheet mentions that System Control is 0x01C00000 --- 0x01C00FFF;
> > - In practice, sunxi_sram.c uses a regmap with max_reg set to 0x30 for the
> >   V3s/H3 so this gives us some room.
> > 
> > Looking at other SoCs with the same setup (take sun8i-r40 for instance),
> > system-control is limited to 0x30 and the NMI controller follows it.
> > In the case of R40, the SRAM controlled is also said to be 4K-long in the
> > Allwinner docs.
> > 
> > So all in all, this leads me to believe that the system-controller instance
> > stops well before 0x1c000d0 on the V3s as well. Otherwise, we should also
> > make the R40 consistent.
> 
> That's a bit unfortunate, but yeah, I guess we want to remain consistent here.

Honestly I think the Allwinner docs are plain wrong on this one.
IIRC they used to describe the NMI as a separate controller in the memory
map. I think they just overlook it now and copy/paste 4K size for each
controller regardless of the actual hardware, so I'm not very worried.

Cheers,

Pauls

-- 
Developer of free digital technology and hardware support.

Website: https://www.paulk.fr/
Coding blog: https://code.paulk.fr/
Git repositories: https://git.paulk.fr/ https://git.code.paulk.fr/

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2020-11-02 17:01 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-31 18:21 [PATCH 0/9] Allwinner V3 SL631 Action Camera Support and Related Fixes Paul Kocialkowski
2020-10-31 18:21 ` Paul Kocialkowski
2020-10-31 18:21 ` [PATCH 1/9] ARM: sunxi: Add machine match for the Allwinner V3 SoC Paul Kocialkowski
2020-10-31 18:21   ` Paul Kocialkowski
2020-11-02  9:28   ` Maxime Ripard
2020-11-02  9:28     ` Maxime Ripard
2020-10-31 18:21 ` [PATCH 2/9] ARM: dts: sun8i-v3: Add UART1 PG pins description Paul Kocialkowski
2020-10-31 18:21   ` Paul Kocialkowski
2020-10-31 18:21 ` [PATCH 3/9] ARM: dts: sun8i-v3s: Add I2C1 PB " Paul Kocialkowski
2020-10-31 18:21   ` Paul Kocialkowski
2020-11-02 10:08   ` Maxime Ripard
2020-11-02 10:08     ` Maxime Ripard
2020-10-31 18:21 ` [PATCH 4/9] dt-bindings: irq: sun7i-nmi: Add binding for the V3s NMI Paul Kocialkowski
2020-10-31 18:21   ` Paul Kocialkowski
2020-11-02 10:09   ` Maxime Ripard
2020-11-02 10:09     ` Maxime Ripard
2020-11-02 10:16     ` Paul Kocialkowski
2020-11-02 10:16       ` Paul Kocialkowski
2020-10-31 18:21 ` [PATCH 5/9] irqchip/sunxi-nmi: Add support " Paul Kocialkowski
2020-10-31 18:21   ` Paul Kocialkowski
2020-11-02 10:09   ` Maxime Ripard
2020-11-02 10:09     ` Maxime Ripard
2020-10-31 18:21 ` [PATCH 6/9] ARM: dts: sun8i-v3s: Add the V3s NMI IRQ controller Paul Kocialkowski
2020-10-31 18:21   ` Paul Kocialkowski
2020-11-02 10:12   ` Maxime Ripard
2020-11-02 10:12     ` Maxime Ripard
2020-11-02 10:25     ` Paul Kocialkowski
2020-11-02 10:25       ` Paul Kocialkowski
2020-11-02 13:44       ` Maxime Ripard
2020-11-02 13:44         ` Maxime Ripard
2020-11-02 16:59         ` Paul Kocialkowski [this message]
2020-11-02 16:59           ` Paul Kocialkowski
2020-10-31 18:21 ` [PATCH 7/9] ARM: dts: sun8i: Cleanup the Pinecube AXP209 node Paul Kocialkowski
2020-10-31 18:21   ` Paul Kocialkowski
2020-10-31 18:21 ` [PATCH 8/9] dt-bindings: arm: sunxi: Add SL631 with IMX179 bindings Paul Kocialkowski
2020-10-31 18:21   ` Paul Kocialkowski
2020-11-02 10:13   ` Maxime Ripard
2020-11-02 10:13     ` Maxime Ripard
2020-11-02 10:33     ` Paul Kocialkowski
2020-11-02 10:33       ` Paul Kocialkowski
2020-11-02 14:27       ` Maxime Ripard
2020-11-02 14:27         ` Maxime Ripard
2020-11-02 17:00         ` Paul Kocialkowski
2020-11-02 17:00           ` Paul Kocialkowski
2020-10-31 18:21 ` [PATCH 9/9] ARM: dts: sun8i-v3: Add support for the SL631 Action Camera with IMX179 Paul Kocialkowski
2020-10-31 18:21   ` Paul Kocialkowski
2020-11-02 10:16   ` Maxime Ripard
2020-11-02 10:16     ` Maxime Ripard
2020-11-02 10:30     ` Paul Kocialkowski
2020-11-02 10:30       ` Paul Kocialkowski

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=20201102165922.GB2037@collins \
    --to=contact@paulk.fr \
    --cc=devicetree@vger.kernel.org \
    --cc=icenowy@aosc.io \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matteo.scordino@gmail.com \
    --cc=maxime@cerno.tech \
    --cc=robh+dt@kernel.org \
    --cc=wens@csie.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.