public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] PM / clk: Remove error message on out-of-memory condition
@ 2019-05-27 12:27 Geert Uytterhoeven
  2019-05-31  9:29 ` Rafael J. Wysocki
  0 siblings, 1 reply; 2+ messages in thread
From: Geert Uytterhoeven @ 2019-05-27 12:27 UTC (permalink / raw)
  To: Rafael J . Wysocki, Pavel Machek, Len Brown, Greg Kroah-Hartman
  Cc: linux-pm, linux-kernel, Geert Uytterhoeven

There is no need to print an error message if kstrdup() fails, as the
memory allocation core already takes care of that.

Note that commit 59d84ca8c46a93ad ("PM / OPP / clk: Remove unnecessary
OOM message") already removed similar error messages, but this one was
forgotten.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 drivers/base/power/clock_ops.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/base/power/clock_ops.c b/drivers/base/power/clock_ops.c
index 59d19dd649289287..1cf86fcaeff8faac 100644
--- a/drivers/base/power/clock_ops.c
+++ b/drivers/base/power/clock_ops.c
@@ -92,8 +92,6 @@ static int __pm_clk_add(struct device *dev, const char *con_id,
 	if (con_id) {
 		ce->con_id = kstrdup(con_id, GFP_KERNEL);
 		if (!ce->con_id) {
-			dev_err(dev,
-				"Not enough memory for clock connection ID.\n");
 			kfree(ce);
 			return -ENOMEM;
 		}
-- 
2.17.1


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

end of thread, other threads:[~2019-05-31  9:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-05-27 12:27 [PATCH] PM / clk: Remove error message on out-of-memory condition Geert Uytterhoeven
2019-05-31  9:29 ` Rafael J. Wysocki

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