* [PATCH] staging: fbtft: use %pe for backlight errors
@ 2026-06-14 20:08 Keefe Reeves
2026-06-15 7:10 ` Andy Shevchenko
0 siblings, 1 reply; 2+ messages in thread
From: Keefe Reeves @ 2026-06-14 20:08 UTC (permalink / raw)
To: andy, gregkh
Cc: abdun.nihaal, error27, chintanlike, namcao, niejianglei2021,
dri-devel, linux-fbdev, linux-staging, linux-kernel, Keefe Reeves
From: Keefe Reeves <229415268+reeveskeefe@users.noreply.github.com>
Coccinelle found two places where backlight registration errors are
printed by passing PTR_ERR() to dev_err().
Use %pe instead so the error pointer can be printed directly. This keeps
the behavior the same and just makes the error printing cleaner.
Signed-off-by: Keefe Reeves <229415268+reeveskeefe@users.noreply.github.com>
---
drivers/staging/fbtft/fb_ssd1351.c | 4 ++--
drivers/staging/fbtft/fbtft-core.c | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/fbtft/fb_ssd1351.c b/drivers/staging/fbtft/fb_ssd1351.c
index 6736b09b2f45..b6cb60f20b11 100644
--- a/drivers/staging/fbtft/fb_ssd1351.c
+++ b/drivers/staging/fbtft/fb_ssd1351.c
@@ -218,8 +218,8 @@ static void register_onboard_backlight(struct fbtft_par *par)
&bl_props);
if (IS_ERR(bd)) {
dev_err(par->info->device,
- "cannot register backlight device (%ld)\n",
- PTR_ERR(bd));
+ "cannot register backlight device (%pe)\n",
+ bd);
return;
}
par->info->bl_dev = bd;
diff --git a/drivers/staging/fbtft/fbtft-core.c b/drivers/staging/fbtft/fbtft-core.c
index 3da42c8ca6e3..b6a846ada3e0 100644
--- a/drivers/staging/fbtft/fbtft-core.c
+++ b/drivers/staging/fbtft/fbtft-core.c
@@ -187,8 +187,8 @@ void fbtft_register_backlight(struct fbtft_par *par)
&fbtft_bl_ops, &bl_props);
if (IS_ERR(bd)) {
dev_err(par->info->device,
- "cannot register backlight device (%ld)\n",
- PTR_ERR(bd));
+ "cannot register backlight device (%pe)\n",
+ bd);
return;
}
par->info->bl_dev = bd;
--
2.54.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] staging: fbtft: use %pe for backlight errors
2026-06-14 20:08 [PATCH] staging: fbtft: use %pe for backlight errors Keefe Reeves
@ 2026-06-15 7:10 ` Andy Shevchenko
0 siblings, 0 replies; 2+ messages in thread
From: Andy Shevchenko @ 2026-06-15 7:10 UTC (permalink / raw)
To: Keefe Reeves
Cc: andy, gregkh, abdun.nihaal, error27, chintanlike, namcao,
niejianglei2021, dri-devel, linux-fbdev, linux-staging,
linux-kernel, Keefe Reeves
On Sun, Jun 14, 2026 at 11:08 PM Keefe Reeves <reeveskeefe@gmail.com> wrote:
>
> From: Keefe Reeves <229415268+reeveskeefe@users.noreply.github.com>
>
> Coccinelle found two places where backlight registration errors are
> printed by passing PTR_ERR() to dev_err().
>
> Use %pe instead so the error pointer can be printed directly. This keeps
> the behavior the same and just makes the error printing cleaner.
>
> Signed-off-by: Keefe Reeves <229415268+reeveskeefe@users.noreply.github.com>
I see a subtle problem with this email address. In case something
happened with your contribution (exempli gratia a regression found)
there will be no possibility to contact you without digging into
mailing list archives to get your Gmail address. I would prefer to see
the From: and SoB to acce-pt responses.
For the change itself, I have no objections. If one considers this
useful (probably to stop flood of the similar patches in the future)
Reviewed-by: Andy Shevchenko <andy@kernel.org>
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-06-15 7:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-14 20:08 [PATCH] staging: fbtft: use %pe for backlight errors Keefe Reeves
2026-06-15 7:10 ` Andy Shevchenko
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox