[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230817074000.355564-1-ruanjinjie@huawei.com>
Date: Thu, 17 Aug 2023 15:39:57 +0800
From: Ruan Jinjie <ruanjinjie@...wei.com>
To: <Shyam-sundar.S-k@....com>, <davem@...emloft.net>, <edumazet@...gle.com>,
<kuba@...nel.org>, <pabeni@...hat.com>, <yisen.zhuang@...wei.com>,
<salil.mehta@...wei.com>, <iyappan@...amperecomputing.com>,
<keyur@...amperecomputing.com>, <quan@...amperecomputing.com>,
<andrew@...n.ch>, <hkallweit1@...il.com>, <linux@...linux.org.uk>,
<yankejian@...wei.com>, <netdev@...r.kernel.org>
CC: <ruanjinjie@...wei.com>
Subject: [PATCH net-next 0/3] net: Fix return value check for get_phy_device()
The get_phy_device() function returns error pointers and never
returns NULL. Update the checks accordingly.
And get_phy_device() returns -EIO on bus access error and -ENOMEM
on kzalloc failure in addition to -ENODEV, return PTR_ERR is more
sensible.
Ruan Jinjie (3):
net: mdio: Fix return value check for get_phy_device()
amd-xgbe: Return proper error code for get_phy_device()
net: hisilicon: hns: Fix return value check for get_phy_device()
drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c | 2 +-
drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 4 ++--
drivers/net/mdio/mdio-xgene.c | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
--
2.34.1
Powered by blists - more mailing lists