regulator: max20411: show failure on register

It is easy to use %pe to print a error-pointer so add this
to the dev_err() if the devm_regulator_register() fails.

Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
Link: https://patch.msgid.link/20260305184623.2603269-1-ben.dooks@codethink.co.uk
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Ben Dooks
2026-03-05 18:46:23 +00:00
committed by Mark Brown
parent 4d4becffe4
commit aa3d0c93a3

View File

@@ -133,7 +133,7 @@ static int max20411_probe(struct i2c_client *client)
max20411->rdev = devm_regulator_register(max20411->dev, &max20411->desc, &cfg);
if (IS_ERR(max20411->rdev))
dev_err(max20411->dev, "Failed to register regulator\n");
dev_err(max20411->dev, "Failed to register regulator: %pe\n", max20411->rdev);
return PTR_ERR_OR_ZERO(max20411->rdev);
}