mirror of
https://github.com/edk2-porting/linux-next.git
synced 2025-01-07 21:24:00 +08:00
regulator: Remove redundant NULL assignment
NULL assignment corrupts the error pointer and is not necessary. Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Mark Brown <broonie@linaro.org>
This commit is contained in:
parent
42141f22e3
commit
cab87f062d
@ -483,7 +483,6 @@ static int max77686_pmic_probe(struct platform_device *pdev)
|
|||||||
if (IS_ERR(max77686->rdev[i])) {
|
if (IS_ERR(max77686->rdev[i])) {
|
||||||
dev_err(&pdev->dev,
|
dev_err(&pdev->dev,
|
||||||
"regulator init failed for %d\n", i);
|
"regulator init failed for %d\n", i);
|
||||||
max77686->rdev[i] = NULL;
|
|
||||||
return PTR_ERR(max77686->rdev[i]);
|
return PTR_ERR(max77686->rdev[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -271,7 +271,6 @@ static int max77693_pmic_probe(struct platform_device *pdev)
|
|||||||
if (IS_ERR(max77693_pmic->rdev[i])) {
|
if (IS_ERR(max77693_pmic->rdev[i])) {
|
||||||
dev_err(max77693_pmic->dev,
|
dev_err(max77693_pmic->dev,
|
||||||
"Failed to initialize regulator-%d\n", id);
|
"Failed to initialize regulator-%d\n", id);
|
||||||
max77693_pmic->rdev[i] = NULL;
|
|
||||||
return PTR_ERR(max77693_pmic->rdev[i]);
|
return PTR_ERR(max77693_pmic->rdev[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1209,7 +1209,6 @@ static int max8997_pmic_probe(struct platform_device *pdev)
|
|||||||
if (IS_ERR(rdev[i])) {
|
if (IS_ERR(rdev[i])) {
|
||||||
dev_err(max8997->dev, "regulator init failed for %d\n",
|
dev_err(max8997->dev, "regulator init failed for %d\n",
|
||||||
id);
|
id);
|
||||||
rdev[i] = NULL;
|
|
||||||
return PTR_ERR(rdev[i]);
|
return PTR_ERR(rdev[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user