Re: [PATCH 2/2] brcmfmac: pcie: Provide a buffer of random bytes to the device

From: Julian Calaby
Date: Tue Feb 14 2023 - 04:01:13 EST


Hi Arend,

On Tue, Feb 14, 2023 at 7:04 PM Hector Martin <marcan@xxxxxxxxx> wrote:
>
> Newer Apple firmwares on chipsets without a hardware RNG require the
> host to provide a buffer of 256 random bytes to the device on
> initialization. This buffer is present immediately before NVRAM,
> suffixed by a footer containing a magic number and the buffer length.
>
> This won't affect chips/firmwares that do not use this feature, so do it
> unconditionally for all Apple platforms (those with an Apple OTP).

Following on from the conversation a year ago, is there a way to
detect chipsets that need these random bytes? While I'm sure Apple is
doing their own special thing for special Apple reasons, it seems
relatively sensible to omit a RNG on lower-cost chipsets, so would
other chipsets need it?

> Reviewed-by: Linus Walleij <linus.walleij@xxxxxxxxxx>
> Signed-off-by: Hector Martin <marcan@xxxxxxxxx>

Beyond that, it all seems pretty sensible.

Reviewed-by: Julian Calaby <julian.calaby@xxxxxxxxx>

> ---
> .../broadcom/brcm80211/brcmfmac/pcie.c | 32 +++++++++++++++++++
> 1 file changed, 32 insertions(+)

Thanks,

--
Julian Calaby

Email: julian.calaby@xxxxxxxxx
Profile: http://www.google.com/profiles/julian.calaby/