Skip to content
Commit 73a87602 authored by Colin Foster's avatar Colin Foster Committed by David S. Miller
Browse files

net: phy: fix null dereference in phy_attach_direct

Commit bc66fa87 ("net: phy: Add link between phy dev and mac dev")
introduced a link between net devices and phy devices. It fails to check
whether dev is NULL, leading to a NULL dereference error.

Fixes: bc66fa87

 ("net: phy: Add link between phy dev and mac dev")
Signed-off-by: default avatarColin Foster <colin.foster@in-advantage.com>
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 61179292
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