mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] regulator: max20411: show failure on register
@ 2026-03-05 18:46 Ben Dooks
  2026-03-06 11:57 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Ben Dooks @ 2026-03-05 18:46 UTC (permalink / raw)
  To: lgirdwood, broonie, linux-kernel; +Cc: Ben Dooks

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>
---
 drivers/regulator/max20411-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/max20411-regulator.c b/drivers/regulator/max20411-regulator.c
index 02d7009ea0e61..6c0ebb970e902 100644
--- a/drivers/regulator/max20411-regulator.c
+++ b/drivers/regulator/max20411-regulator.c
@@ -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);
 }
-- 
2.37.2.352.g3c44437643


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] regulator: max20411: show failure on register
  2026-03-05 18:46 [PATCH] regulator: max20411: show failure on register Ben Dooks
@ 2026-03-06 11:57 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2026-03-06 11:57 UTC (permalink / raw)
  To: lgirdwood, linux-kernel, Ben Dooks

On Thu, 05 Mar 2026 18:46:23 +0000, Ben Dooks wrote:
> It is easy to use %pe to print a error-pointer so add this
> to the dev_err() if the devm_regulator_register() fails.

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next

Thanks!

[1/1] regulator: max20411: show failure on register
      commit: aa3d0c93a333182e887426366a4f3e5f06ee0d83

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-03-06 11:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-03-05 18:46 [PATCH] regulator: max20411: show failure on register Ben Dooks
2026-03-06 11:57 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®