[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20250821093253.559809-1-zhao.xichao@vivo.com>
Date: Thu, 21 Aug 2025 17:32:53 +0800
From: Xichao Zhao <zhao.xichao@...o.com>
To: sudeep.holla@....com,
cristian.marussi@....com,
jassisinghbrar@...il.com
Cc: linux-kernel@...r.kernel.org,
Xichao Zhao <zhao.xichao@...o.com>
Subject: [PATCH] mailbox: arm_mhuv3: Remove dev_err_probe() if error is -ENOMEM
The dev_err_probe() doesn't do anything when error is '-ENOMEM'.
Therefore, remove the useless call to dev_err_probe(), and just
return the value instead.
Signed-off-by: Xichao Zhao <zhao.xichao@...o.com>
---
drivers/mailbox/arm_mhuv3.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/mailbox/arm_mhuv3.c b/drivers/mailbox/arm_mhuv3.c
index b97e79a5870f..cae1f9bea050 100644
--- a/drivers/mailbox/arm_mhuv3.c
+++ b/drivers/mailbox/arm_mhuv3.c
@@ -775,8 +775,7 @@ static int mhuv3_initialize_channels(struct device *dev, struct mhuv3 *mhu)
mbox->chans = devm_kcalloc(dev, mhu->num_chans,
sizeof(*mbox->chans), GFP_KERNEL);
if (!mbox->chans)
- return dev_err_probe(dev, -ENOMEM,
- "Failed to initialize channels\n");
+ return -ENOMEM;
for (i = 0; i < NUM_EXT && !ret; i++)
if (mhu->ext[i])
--
2.34.1
Powered by blists - more mailing lists