All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andres Salomon <dilinger@queued.net>
To: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <rob.herring@calxeda.com>,
	devicetree-discuss@lists.ozlabs.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH] of: add some debugging statements if initrd isn't found
Date: Fri, 3 Feb 2012 14:15:20 -0800	[thread overview]
Message-ID: <20120203141520.4900a23b@debxo> (raw)


While debugging initrd problems in a FDT blob, it's nice to both terminate
the "Looking for initrd properties... " with a newline, as well as letting us
know which property wasn't found.

Signed-off-by: Andres Salomon <dilinger@queued.net>
---
 drivers/of/fdt.c |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
index ea2bd1b..92234f7 100644
--- a/drivers/of/fdt.c
+++ b/drivers/of/fdt.c
@@ -561,13 +561,17 @@ void __init early_init_dt_check_for_initrd(unsigned long node)
 	pr_debug("Looking for initrd properties... ");
 
 	prop = of_get_flat_dt_prop(node, "linux,initrd-start", &len);
-	if (!prop)
+	if (!prop) {
+		pr_debug("couldn't find linux,initrd-start\n");
 		return;
+	}
 	start = of_read_ulong(prop, len/4);
 
 	prop = of_get_flat_dt_prop(node, "linux,initrd-end", &len);
-	if (!prop)
+	if (!prop) {
+		pr_debug("couldn't find linux,initrd-end\n");
 		return;
+	}
 	end = of_read_ulong(prop, len/4);
 
 	early_init_dt_setup_initrd_arch(start, end);
-- 
1.7.2.5

                 reply	other threads:[~2012-02-03 22:15 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=20120203141520.4900a23b@debxo \
    --to=dilinger@queued.net \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=grant.likely@secretlab.ca \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rob.herring@calxeda.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.