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: Stafford Horne <shorne@gmail.com>,
	Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH master] openrisc: dts: describe all 4 UARTs
Date: Thu, 22 Aug 2024 18:56:34 +0200	[thread overview]
Message-ID: <20240822165633.3726922-1-a.fatoum@pengutronix.de> (raw)

Starting with QEMU v7.1.0, the openrisc_sim machine features 4 serial
ports. This was introduced with QEMU commit 777784bda468 ("hw/openrisc:
support 4 serial ports in or1ksim"), which also made the last console
(serial@90000300) the default.

This is still the case as of v9.1.0-rc3, but I submitted a patch to
restore serial@90000000 as default. Until that's merged, let's just
activate all consoles after describing them in the device tree.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
Optimally, we would start consuming the device tree supplied by QEMU,
but this should be good enough to fix the test suite breakage.
---
 arch/openrisc/configs/generic_defconfig |  1 +
 arch/openrisc/dts/or1ksim.dts           | 21 +++++++++++++++++++++
 2 files changed, 22 insertions(+)

diff --git a/arch/openrisc/configs/generic_defconfig b/arch/openrisc/configs/generic_defconfig
index 1f2d40eae9f7..417ae4db3650 100644
--- a/arch/openrisc/configs/generic_defconfig
+++ b/arch/openrisc/configs/generic_defconfig
@@ -3,6 +3,7 @@ CONFIG_BUILTIN_DTB_NAME="or1ksim"
 CONFIG_HUSH_FANCY_PROMPT=y
 CONFIG_CMDLINE_EDITING=y
 CONFIG_AUTO_COMPLETE=y
+CONFIG_CONSOLE_ACTIVATE_ALL=y
 CONFIG_PARTITION=y
 CONFIG_DEFAULT_ENVIRONMENT_GENERIC_NEW=y
 CONFIG_LONGHELP=y
diff --git a/arch/openrisc/dts/or1ksim.dts b/arch/openrisc/dts/or1ksim.dts
index 7316cc677046..ac938be9ee31 100644
--- a/arch/openrisc/dts/or1ksim.dts
+++ b/arch/openrisc/dts/or1ksim.dts
@@ -43,6 +43,27 @@ serial0: serial@90000000 {
 		clock-frequency = <50000000>;
 	};
 
+	serial1: serial@90000100 {
+		compatible = "ns16550a";
+		reg = <0x90000100 0x100>;
+		interrupts = <2>;
+		clock-frequency = <50000000>;
+	};
+
+	serial2: serial@90000200 {
+		compatible = "ns16550a";
+		reg = <0x90000200 0x100>;
+		interrupts = <2>;
+		clock-frequency = <50000000>;
+	};
+
+	serial3: serial@90000300 {
+		compatible = "ns16550a";
+		reg = <0x90000300 0x100>;
+		interrupts = <2>;
+		clock-frequency = <50000000>;
+	};
+
 	enet0: ethoc@92000000 {
 		compatible = "opencores,ethoc";
 		reg = <0x92000000 0x100>;
-- 
2.39.2




             reply	other threads:[~2024-08-22 16:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-22 16:56 Ahmad Fatoum [this message]
2024-08-23  7:57 ` 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=20240822165633.3726922-1-a.fatoum@pengutronix.de \
    --to=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=shorne@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox