brcmfmac: pcie: Provide a buffer of random bytes to the device
authorHector Martin <marcan@marcan.st>
Thu, 23 Dec 2021 10:30:17 +0000 (19:30 +0900)
committerHector Martin <marcan@marcan.st>
Sat, 19 Feb 2022 08:17:03 +0000 (17:17 +0900)
commit983bf3094ce4c64a6992273a7280410ba5f77942
tree9bf151251324ed2b5ec7c2cab5f9e9380d393758
parent59f6642598851fea0632233127b127a3eb5c5b68
brcmfmac: pcie: Provide a buffer of random bytes to the device

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.

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Hector Martin <marcan@marcan.st>
drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c