mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Baran Tuna <barant@fastmail.com>
To: Matthias Brugger <matthias.bgg@gmail.com>,
	AngeloGioacchino Del Regno
	<angelogioacchino.delregno@collabora.com>
Cc: linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-mediatek@lists.infradead.org
Subject: [PATCH] soc: mediatek: mtk-svs: Use %pe to print PTR_ERR()
Date: Tue, 24 Nov 2026 22:05:42 +0300	[thread overview]
Message-ID: <9448408e0bd0f37a05d458f0c8ae69ec848cdf71.1795546605.git.barant@fastmail.com> (raw)

Use the %pe format specifier to print error pointers symbolically
instead of printing PTR_ERR() as a number.

Found by scripts/coccinelle/misc/ptr_err_to_pe.cocci.

Signed-off-by: Baran Tuna <barant@fastmail.com>
---
 Compile-tested only.

 drivers/soc/mediatek/mtk-svs.c | 17 ++++++++---------
 1 file changed, 8 insertions(+), 9 deletions(-)

diff --git a/drivers/soc/mediatek/mtk-svs.c b/drivers/soc/mediatek/mtk-svs.c
index 0f37b3aadaa2..385c4aef9e91 100644
--- a/drivers/soc/mediatek/mtk-svs.c
+++ b/drivers/soc/mediatek/mtk-svs.c
@@ -594,8 +594,8 @@ static int svs_sync_bank_volts_from_opp(struct svs_bank *svsb)
 						 svsb->opp_dfreq[i],
 						 true);
 		if (IS_ERR(opp)) {
-			dev_err(svsb->dev, "cannot find freq = %u (%ld)\n",
-				svsb->opp_dfreq[i], PTR_ERR(opp));
+			dev_err(svsb->dev, "cannot find freq = %u (%pe)\n",
+				svsb->opp_dfreq[i], opp);
 			return PTR_ERR(opp);
 		}
 
@@ -833,9 +833,8 @@ static int svs_status_debug_show(struct seq_file *m, void *v)
 		opp = dev_pm_opp_find_freq_exact(svsb->opp_dev,
 						 svsb->opp_dfreq[i], true);
 		if (IS_ERR(opp)) {
-			seq_printf(m, "%s: cannot find freq = %u (%ld)\n",
-				   svsb->name, svsb->opp_dfreq[i],
-				   PTR_ERR(opp));
+			seq_printf(m, "%s: cannot find freq = %u (%pe)\n",
+				   svsb->name, svsb->opp_dfreq[i], opp);
 			return PTR_ERR(opp);
 		}
 
@@ -1840,8 +1839,8 @@ static int svs_bank_resource_setup(struct svs_platform *svsp)
 		for (i = 0, freq = ULONG_MAX; i < bdata->opp_count; i++, freq--) {
 			opp = dev_pm_opp_find_freq_floor(svsb->opp_dev, &freq);
 			if (IS_ERR(opp)) {
-				dev_err(svsb->dev, "cannot find freq = %ld\n",
-					PTR_ERR(opp));
+				dev_err(svsb->dev, "cannot find freq = %pe\n",
+					opp);
 				return PTR_ERR(opp);
 			}
 
@@ -1864,8 +1863,8 @@ static int svs_get_efuse_data(struct svs_platform *svsp,
 
 	cell = nvmem_cell_get(svsp->dev, nvmem_cell_name);
 	if (IS_ERR(cell)) {
-		dev_err(svsp->dev, "no \"%s\"? %ld\n",
-			nvmem_cell_name, PTR_ERR(cell));
+		dev_err(svsp->dev, "no \"%s\"? %pe\n",
+			nvmem_cell_name, cell);
 		return PTR_ERR(cell);
 	}
 

base-commit: 8d7fe9885c62fc9a95bf55d9db244d9672a8aadc
-- 
2.53.0


                 reply	other threads:[~2026-11-24 19:05 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9448408e0bd0f37a05d458f0c8ae69ec848cdf71.1795546605.git.barant@fastmail.com \
    --to=barant@fastmail.com \
    --cc=angelogioacchino.delregno@collabora.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=matthias.bgg@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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®