From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH] of: reserved-mem: add debug print for reservations
Date: Wed, 22 Nov 2023 18:31:18 +0100 [thread overview]
Message-ID: <20231122173118.569620-1-a.fatoum@pengutronix.de> (raw)
reserve_sdram_region can now involve cache maintenance, so add a debug
print beforehand to aid debugging.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
drivers/of/reserved-mem.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/of/reserved-mem.c b/drivers/of/reserved-mem.c
index f50a0bd8374d..599a7c968afd 100644
--- a/drivers/of/reserved-mem.c
+++ b/drivers/of/reserved-mem.c
@@ -1,6 +1,8 @@
// SPDX-License-Identifier: GPL-2.0-only
// SPDX-FileCopyrightText: 2021 Rouven Czerwinski <r.czerwinski@pengutronix.de>, Pengutronix
+#define pr_fmt(fmt) "of-reserved-mem: " fmt
+
#include <stdio.h>
#include <of.h>
#include <of_address.h>
@@ -17,6 +19,8 @@ static void request_region(struct resource *r)
if (!resource_contains(bank->res, r))
continue;
+ pr_debug("reserving %s at %pad-%pad\n", r->name, &r->start, &r->end);
+
if (!reserve_sdram_region(r->name, r->start, resource_size(r)))
pr_warn("couldn't request reserved sdram region %pa-%pa\n",
&r->start, &r->end);
--
2.39.2
next reply other threads:[~2023-11-22 17:32 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-22 17:31 Ahmad Fatoum [this message]
2023-11-23 7:23 ` Sascha Hauer
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=20231122173118.569620-1-a.fatoum@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=barebox@lists.infradead.org \
/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