Skip to content
Commit da48be33 authored by Petr Štetiar's avatar Petr Štetiar Committed by David S. Miller
Browse files

staging: octeon-ethernet: Fix of_get_mac_address ERR_PTR check



Commit 284eb160 ("staging: octeon-ethernet: support
of_get_mac_address new ERR_PTR error") has introduced checking for
ERR_PTR encoded error value from of_get_mac_address with IS_ERR macro,
which is not sufficient in this case, as the mac variable is set to NULL
initialy and if the kernel is compiled without DT support this NULL
would get passed to IS_ERR, which would lead to the wrong decision and
would pass that NULL pointer and invalid MAC address further.

Fixes: 284eb160 ("staging: octeon-ethernet: support of_get_mac_address new ERR_PTR error")
Signed-off-by: default avatarPetr Štetiar <ynezz@true.cz>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 4974f9b7
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment