mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-25 21:54:06 +08:00
phy: ralink: phy-mt7621-pci: fix return value check in mt7621_pci_phy_probe()
Fix the return value check which testing the wrong variable
in mt7621_pci_phy_probe().
Fixes: d87da32372
("phy: ralink: Add PHY driver for MT7621 PCIe PHY")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Reviewed-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Link: https://lore.kernel.org/r/20210305034931.3237558-1-weiyongjun1@huawei.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
This commit is contained in:
parent
6cb17707aa
commit
b976c98751
@ -319,9 +319,9 @@ static int mt7621_pci_phy_probe(struct platform_device *pdev)
|
|||||||
return PTR_ERR(phy->regmap);
|
return PTR_ERR(phy->regmap);
|
||||||
|
|
||||||
phy->phy = devm_phy_create(dev, dev->of_node, &mt7621_pci_phy_ops);
|
phy->phy = devm_phy_create(dev, dev->of_node, &mt7621_pci_phy_ops);
|
||||||
if (IS_ERR(phy)) {
|
if (IS_ERR(phy->phy)) {
|
||||||
dev_err(dev, "failed to create phy\n");
|
dev_err(dev, "failed to create phy\n");
|
||||||
return PTR_ERR(phy);
|
return PTR_ERR(phy->phy);
|
||||||
}
|
}
|
||||||
|
|
||||||
phy_set_drvdata(phy->phy, phy);
|
phy_set_drvdata(phy->phy, phy);
|
||||||
|
Loading…
Reference in New Issue
Block a user