mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-26 12:34:41 +08:00
net: dpaa: Fix dtsec check for PCS availability
We want to fail if the PCS is not available, not if it is available. Fix
this condition.
Fixes: 5d93cfcf73
("net: dpaa: Convert to phylink")
Reported-by: Christian Zigotzky <info@xenosoft.de>
Signed-off-by: Sean Anderson <seanga2@gmail.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
4af1b64f80
commit
7dc6183854
@ -1430,7 +1430,7 @@ int dtsec_initialization(struct mac_device *mac_dev,
|
||||
dtsec->dtsec_drv_param->tx_pad_crc = true;
|
||||
|
||||
phy_node = of_parse_phandle(mac_node, "tbi-handle", 0);
|
||||
if (!phy_node || of_device_is_available(phy_node)) {
|
||||
if (!phy_node || !of_device_is_available(phy_node)) {
|
||||
of_node_put(phy_node);
|
||||
err = -EINVAL;
|
||||
dev_err_probe(mac_dev->dev, err,
|
||||
|
Loading…
Reference in New Issue
Block a user