From: Peter Delevoryas <peter@pjd.dev>
Cc: "Peter Delevoryas" <peter@pjd.dev>,
"Cédric Le Goater" <clg@kaod.org>,
"Peter Maydell" <peter.maydell@linaro.org>,
"Andrew Jeffery" <andrew@aj.id.au>,
"Joel Stanley" <joel@jms.id.au>,
qemu-arm@nongnu.org, qemu-devel@nongnu.org
Subject: [PATCH 2/2] aspeed: Add fby35-bmc slot GPIO's
Date: Thu, 7 Jul 2022 00:17:31 -0700 [thread overview]
Message-ID: <20220707071731.34047-3-peter@pjd.dev> (raw)
In-Reply-To: <20220707071731.34047-1-peter@pjd.dev>
Signed-off-by: Peter Delevoryas <peter@pjd.dev>
---
hw/arm/aspeed.c | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/hw/arm/aspeed.c b/hw/arm/aspeed.c
index 6fe9b13548..0ce9a42c2b 100644
--- a/hw/arm/aspeed.c
+++ b/hw/arm/aspeed.c
@@ -1343,11 +1343,23 @@ static void fby35_reset(MachineState *state)
qemu_devices_reset();
- /* Board ID */
+ /* Board ID: 7 (Class-1, 4 slots) */
object_property_set_bool(OBJECT(gpio), "gpioV4", true, &error_fatal);
object_property_set_bool(OBJECT(gpio), "gpioV5", true, &error_fatal);
object_property_set_bool(OBJECT(gpio), "gpioV6", true, &error_fatal);
object_property_set_bool(OBJECT(gpio), "gpioV7", false, &error_fatal);
+
+ /* Slot presence pins, inverse polarity. (False means present) */
+ object_property_set_bool(OBJECT(gpio), "gpioH4", false, &error_fatal);
+ object_property_set_bool(OBJECT(gpio), "gpioH5", true, &error_fatal);
+ object_property_set_bool(OBJECT(gpio), "gpioH6", true, &error_fatal);
+ object_property_set_bool(OBJECT(gpio), "gpioH7", true, &error_fatal);
+
+ /* Slot 12v power pins, normal polarity. (True means powered-on) */
+ object_property_set_bool(OBJECT(gpio), "gpioB2", true, &error_fatal);
+ object_property_set_bool(OBJECT(gpio), "gpioB3", false, &error_fatal);
+ object_property_set_bool(OBJECT(gpio), "gpioB4", false, &error_fatal);
+ object_property_set_bool(OBJECT(gpio), "gpioB5", false, &error_fatal);
}
static void aspeed_machine_fby35_class_init(ObjectClass *oc, void *data)
--
2.36.1
next prev parent reply other threads:[~2022-07-07 7:22 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20220707071731.34047-1-peter@pjd.dev>
2022-07-07 7:17 ` [PATCH 1/2] hw/gpio/aspeed: Don't let guests modify input pins Peter Delevoryas
2022-07-07 8:20 ` Joel Stanley
2022-07-07 17:50 ` Peter Delevoryas
2022-07-11 12:25 ` Andrew Jeffery
2022-07-07 8:56 ` Cédric Le Goater
2022-07-07 17:53 ` Peter Delevoryas
2022-07-07 19:04 ` Peter Delevoryas
2022-07-11 8:13 ` Cédric Le Goater
2022-07-11 13:26 ` Andrew Jeffery
2022-07-12 1:57 ` Peter Delevoryas
2022-07-18 1:07 ` Andrew Jeffery
2022-07-07 7:17 ` Peter Delevoryas [this message]
2022-07-07 7:26 ` [PATCH 0/2] " Peter Delevoryas
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=20220707071731.34047-3-peter@pjd.dev \
--to=peter@pjd.dev \
--cc=andrew@aj.id.au \
--cc=clg@kaod.org \
--cc=joel@jms.id.au \
--cc=peter.maydell@linaro.org \
--cc=qemu-arm@nongnu.org \
--cc=qemu-devel@nongnu.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).