]> git.baikalelectronics.ru Git - kernel.git/commit
brcmfmac: Call brcmf_dmi_probe before brcmf_of_probe
authorHans de Goede <hdegoede@redhat.com>
Fri, 23 Nov 2018 09:11:48 +0000 (10:11 +0100)
committerKalle Valo <kvalo@codeaurora.org>
Thu, 29 Nov 2018 15:32:25 +0000 (17:32 +0200)
commit3c2170631969ac9897bf828837aac02b4c40b5f7
treed36251ebfcb2ae4c0026ac069af233c02849c427
parent8b179e1c280d6ed85e67b01dfdd898ef99757d28
brcmfmac: Call brcmf_dmi_probe before brcmf_of_probe

ARM systems with UEFI may have both devicetree (of) and DMI data in this
case we end up setting brcmf_mp_device.board_type twice.

In this case we should prefer the devicetree data, because:
1) The devicerree data is more reliable
2) Some ARM systems (e.g. the Raspberry Pi 3 models) support both UEFI and
   classic uboot booting, the devicetree data is always there, so using it
   makes sure we ask for the same nvram file independent of how we booted.

This commit moves the brcmf_dmi_probe call to before the brcmf_of_probe
call, so that the latter can override the value of the first if both are
set.

Fixes: 0406536534df ("brcmfmac: Set board_type from DMI on x86 based ...")
Cc: Peter Robinson <pbrobinson@gmail.com>
Tested-and-reported-by: Peter Robinson <pbrobinson@gmail.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c