Re: [PATCH v11 3/6] arm64: dts: allwinner: Add Allwinner H616 .dtsi file

From: Andre Przywara
Date: Fri Jul 08 2022 - 05:47:59 EST


On Thu, 7 Jul 2022 01:30:32 -0500
Samuel Holland <samuel@xxxxxxxxxxxx> wrote:

Hi Samuel,

> Hi Andre, Jernej,
>
> On 7/6/22 8:16 AM, Andre Przywara wrote:
> > so after seemingly having finished writing this email, I realised that
> > this won't really help, as I think this diverts the discussion. And the
> > problem has been around for a while, and won't probably be solved easily
> > or quickly. I think we agree to disagree here, or we should admit that
> > there are different approaches ("bundled firmware" vs. "UEFI"), so in the
> > interest of not blocking the H616 series:
> >
> > Shall I just keep the firmware node? This would work both ways, whereas
> > dropping the node would impede the "bundled firmware" approach?
>
> Let me try to sum up the relevant portion of my thoughts (and save the rest for
> elsewhere):
>
> The only reason to add the reserved-memory node is to support externally-loaded
> DTBs. By adding the node, we are committing to support externally-loaded DTBs on
> this SoC.
>
> Upgrading the kernel is not allowed to break boot. If we support
> externally-loaded DTBs, that rule extends to DTBs shipped with the kernel.
>
> If we remove the reserved-memory node, the combination of old U-Boot + new
> externally-loaded DTB will stop booting (the kernel version is irrelevant).
> Therefore, if we add the node, we can never remove it, full stop.

Well, this all depends on the initial commitment to support
externally-loaded DTBs. I don't think we need to make this promise, I'd
rather see this as a concession to people doing so *right now*, and for
the sheer practicality of using this DT until we merge it into U-Boot.

> I will (begrudgingly) accept that, as long as the node matches what TF-A
> actually generates today. That means, please:
> - Drop the label and update the node name

I will drop the label. For the node name: the binding does not enforce it,
but asks that "node names should reflect the purpose", so I went with
"secmon", as used by other platforms. I will send a patch to TF-A to fix
it there instead.
If you disagree, feel free to fix this up before committing.

> - Reduce the size to 256 KiB, matching (BL31_LIMIT - BL31_BASE)

Verified in TF-A and changed.
I also added a short comment explaining the situation. Feel free to amend
this if needed.


Many thanks for the discussion and for resolving this. I much appreciate
your flexibility and pragmatism in this matter!

Cheers,
Andre