linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Jack Miller <jack@codezen.org>
To: linuxppc-dev@lists.ozlabs.org
Cc: jk@ozlabs.org
Subject: [PATCH] powernv: Search for new flash DT node location
Date: Mon,  1 Aug 2016 15:50:35 -0500	[thread overview]
Message-ID: <20160801205035.18514-1-jack@codezen.org> (raw)

Skiboot will place the flash device tree node at ibm,opal/flash/flash@0
on P9 and later systems, so Linux needs to search for it there as well
as ibm,opal/flash@0 for backwards compatibility.

Signed-off-by: Jack Miller <jack@codezen.org>
---
 arch/powerpc/platforms/powernv/opal.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/arch/powerpc/platforms/powernv/opal.c b/arch/powerpc/platforms/powernv/opal.c
index ae29eaf..2847cb0 100644
--- a/arch/powerpc/platforms/powernv/opal.c
+++ b/arch/powerpc/platforms/powernv/opal.c
@@ -755,9 +755,14 @@ static int __init opal_init(void)
 
 	/* Initialize platform devices: IPMI backend, PRD & flash interface */
 	opal_pdev_init(opal_node, "ibm,opal-ipmi");
-	opal_pdev_init(opal_node, "ibm,opal-flash");
+	opal_pdev_init(opal_node, "ibm,opal-flash"); // old <= P8 flash location
 	opal_pdev_init(opal_node, "ibm,opal-prd");
 
+	/* New >= P9 flash location */
+	np = of_get_child_by_name(opal_node, "flash");
+	if (np)
+		opal_pdev_init(np, "ibm,opal-flash");
+
 	/* Initialise OPAL kmsg dumper for flushing console on panic */
 	opal_kmsg_init();
 
-- 
2.9.2

             reply	other threads:[~2016-08-01 20:50 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-01 20:50 Jack Miller [this message]
2016-08-01 21:04 ` [PATCH] powernv: Search for new flash DT node location Jack Miller
2016-08-03  7:16 ` Michael Ellerman
2016-08-03 16:44   ` Jack Miller
2016-08-03 16:44     ` [PATCH] powernv: Simplify searching for compatible device nodes Jack Miller
2016-08-03 17:18     ` [PATCH v2] " Jack Miller
2016-08-04  7:27       ` Cyril Bur
2016-08-04  8:39         ` Michael Ellerman
2016-08-04 16:03           ` Jack Miller
2016-08-04  3:28     ` [PATCH] powernv: Search for new flash DT node location Michael Ellerman
2016-09-27  4:44       ` Stewart Smith

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=20160801205035.18514-1-jack@codezen.org \
    --to=jack@codezen.org \
    --cc=jk@ozlabs.org \
    --cc=linuxppc-dev@lists.ozlabs.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;
as well as URLs for NNTP newsgroup(s).