phy: samsung-ufs: Fix inconsistent IS_ERR and PTR_ERR
PATCH 1/1 phy: samsung-ufs: Fix inconsistent IS_ERR and PTR_ERR
Fix inconsistent IS_ERR and PTR_ERR in samsung_ufs_phy_symbol_clk_init(). The proper pointer to be passed as argument to PTR_ERR() is rx1_symbol_clk.
This bug was detected with the help of Coccinelle.
Fixes bca21e930451 ("phy: samsung-ufs: add UFS PHY driver for samsung SoC")
Signed-off-by Gustavo A. R. Silva <[email protected]>
--- drivers/phy/samsung/phy-samsung-ufs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/phy/samsung/phy-samsung-ufs.c +1 -1
@@ -147,7 +147,7 @@ static int samsung_ufs_phy_symbol_clk_init(struct samsung_ufs_phy *phy) } phy->rx1_symbol_clk =devm_clk_get (phy->dev,"rx1_symbol_clk" ); -if (IS_ERR (phy->rx0_symbol_clk)) { +if (IS_ERR (phy->rx1_symbol_clk)) {dev_err (phy->dev,"failed to get rx1_symbol_clk clock\n" );return PTR_ERR (phy->rx1_symbol_clk); }
Signature · 1 line
2.27.0