]> git.baikalelectronics.ru Git - kernel.git/commit
net: phy: fixed_phy: Fix NULL vs IS_ERR() checking in __fixed_phy_register
authorMiaoqian Lin <linmq006@gmail.com>
Fri, 24 Dec 2021 02:14:59 +0000 (02:14 +0000)
committerJakub Kicinski <kuba@kernel.org>
Fri, 24 Dec 2021 22:52:10 +0000 (14:52 -0800)
commit4db0840f4da43b00ada162022deb163b711ce421
tree846d86c6730cf938e1dc5aaaed8d6a4756d61f9a
parentcfd5ce5203198948879dba0dd8028a17b80c2ab6
net: phy: fixed_phy: Fix NULL vs IS_ERR() checking in __fixed_phy_register

The fixed_phy_get_gpiod function() returns NULL, it doesn't return error
pointers, using NULL checking to fix this.i

Fixes: 4e287bfd91ad ("net: phy: fixed-phy: Drop GPIO from fixed_phy_add()")
Signed-off-by: Miaoqian Lin <linmq006@gmail.com>
Link: https://lore.kernel.org/r/20211224021500.10362-1-linmq006@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/phy/fixed_phy.c