diff options
author | Martin Blumenstingl <martin.blumenstingl@googlemail.com> | 2019-07-27 21:21:37 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-07-29 10:57:10 -0700 |
commit | 195b2919ccd7ffcaf6b6bbcb39444a53ab8308c7 (patch) | |
tree | 1ad3861917d92255d2ff308d9431a791415f22b4 /drivers/ata/Kconfig | |
parent | 05bba1edaf9c11023901800bc4d2ce5b96e0836a (diff) | |
download | linux-195b2919ccd7ffcaf6b6bbcb39444a53ab8308c7.tar.bz2 |
net: stmmac: manage errors returned by of_get_mac_address()
Commit d01f449c008a ("of_net: add NVMEM support to of_get_mac_address")
added support for reading the MAC address from an nvmem-cell. This
required changing the logic to return an error pointer upon failure.
If stmmac is loaded before the nvmem provider driver then
of_get_mac_address() return an error pointer with -EPROBE_DEFER.
Propagate this error so the stmmac driver will be probed again after the
nvmem provider driver is loaded.
Default to a random generated MAC address in case of any other error,
instead of using the error pointer as MAC address.
Fixes: d01f449c008a ("of_net: add NVMEM support to of_get_mac_address")
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/ata/Kconfig')
0 files changed, 0 insertions, 0 deletions