[PATCH v3 09/10] arch: arm: boot: dts: Introduce HPE GXP Device tree
Arnd Bergmann
arnd at arndb.de
Wed Apr 6 00:24:40 PDT 2022
On Tue, Apr 5, 2022 at 11:21 PM Hawkins, Nick <nick.hawkins at hpe.com> wrote:
>
> > Right, it is possible to make this work, but it's not recommended, and you have to work around the sanity checks in the code that try to keep you from doing it wrong, as well as any tooling that tries to check for these in the DT.
>
> I found an example in the kernel where the timer creates a child watchdog device and passes it the base address when creating it. I used this to model the gxp-timer and gxp-wdt. The following files were what I have referenced:
> drivers/watchdog/ixp4xx_wdt.c
> drivers/clocksource/timer-ixp4xx.c
Yes, I think that is a good example.
> This seems very similar to what you suggested previously except I do not see a private interface in there between the parent and the child device. Is it mandatory to have the private interface between the two? If it is, what would you recommend that interface be? So far without the private interface I am not seeing any issues accessing the registers.
I would count passing a register address to the child device as a
private interface.
It's a minimalistic one, but that is not a bad thing here.
Arnd
More information about the linux-arm-kernel
mailing list