mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: jbe@pengutronix.de, Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH master] power: reset: nvmem-reboot-mode: disable device tree fixup
Date: Wed, 22 Sep 2021 11:09:40 +0200	[thread overview]
Message-ID: <20210922090940.18002-1-a.fatoum@pengutronix.de> (raw)

Fixing up the nvmem reboot device tree node is problematic, because it
contains a phandle to another node. Take the easy way out for now and
expect user to provide matching reboot-mode nodes in both kernel and
barebox device tree manually.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 drivers/power/reset/nvmem-reboot-mode.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/power/reset/nvmem-reboot-mode.c b/drivers/power/reset/nvmem-reboot-mode.c
index b82b37d642e7..2086e96400bb 100644
--- a/drivers/power/reset/nvmem-reboot-mode.c
+++ b/drivers/power/reset/nvmem-reboot-mode.c
@@ -57,6 +57,14 @@ static int nvmem_reboot_mode_probe(struct device_d *dev)
 	nvmem_rbm->reboot.write = nvmem_reboot_mode_write;
 	nvmem_rbm->reboot.priority = 200;
 
+	/*
+	 * Fixing up the nvmem reboot device tree node is problematic, because it
+	 * contains a phandle to another node. Take the easy way out for now and
+	 * expect user to provide matching reboot-mode nodes in both kernel and
+	 * barebox device tree manually.
+	 */
+	nvmem_rbm->reboot.no_fixup = true;
+
 	magicbuf = nvmem_cell_read(nvmem_rbm->cell, &len);
 	if (IS_ERR(magicbuf) || len != 4) {
 		dev_err(dev, "error reading reboot mode: %pe\n", magicbuf);
-- 
2.30.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox


             reply	other threads:[~2021-09-22  9:12 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-22  9:09 Ahmad Fatoum [this message]
2021-10-01 13:27 ` 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=20210922090940.18002-1-a.fatoum@pengutronix.de \
    --to=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=jbe@pengutronix.de \
    /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