From: Helge Deller <deller@kernel.org>
To: qemu-devel@nongnu.org
Cc: "Richard Henderson" <richard.henderson@linaro.org>,
deller@gmx.de, "Philippe Mathieu-Daudé" <philmd@linaro.org>
Subject: [PULL 1/2] hw/pci-host/astro: Encode Astro version numbers
Date: Tue, 19 May 2026 17:18:22 +0200 [thread overview]
Message-ID: <20260519151823.13878-2-deller@kernel.org> (raw)
In-Reply-To: <20260519151823.13878-1-deller@kernel.org>
From: Helge Deller <deller@gmx.de>
Add enum which encodes the Astro version numbers.
Signed-off-by: Helge Deller <deller@gmx.de>
Suggested-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
---
hw/pci-host/astro.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/hw/pci-host/astro.c b/hw/pci-host/astro.c
index 8c61c696bd..fc07608da7 100644
--- a/hw/pci-host/astro.c
+++ b/hw/pci-host/astro.c
@@ -41,6 +41,9 @@ static const int elroy_hpa_offsets[ELROY_NUM] = {
static const char elroy_rope_nr[ELROY_NUM] = {
0, 1, 4, 6 }; /* busnum path, e.g. [10:6] */
+/* Astro version numbers */
+enum { ID_ASTRO_1_0 = 0, ID_ASTRO_2_1 = 9, ID_ASTRO_3_0 = 2 };
+
/*
* Helper functions
*/
@@ -738,7 +741,7 @@ static MemTxResult astro_chip_read_with_attrs(void *opaque, hwaddr addr,
switch ((addr >> 3) << 3) {
/* R2I registers */
case 0x0000: /* ID */
- val = (0x01 << 3) | 0x01ULL;
+ val = ID_ASTRO_2_1;
break;
case 0x0008: /* IOC_CTRL */
val = s->ioc_ctrl;
--
2.54.0
next prev parent reply other threads:[~2026-05-19 15:19 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-19 15:18 [PULL 0/2] Hppa post v11 patches patches Helge Deller
2026-05-19 15:18 ` Helge Deller [this message]
2026-05-19 15:18 ` [PULL 2/2] hw/hppa: Move static variable lasi_dev into MachineState Helge Deller
2026-05-19 20:51 ` [PULL 0/2] Hppa post v11 patches patches Stefan Hajnoczi
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=20260519151823.13878-2-deller@kernel.org \
--to=deller@kernel.org \
--cc=deller@gmx.de \
--cc=philmd@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=richard.henderson@linaro.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 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.