* [PATCH] hw/arm: Add support for kudo-bmc board.
@ 2021-09-02 18:16 Chris Rauer
2021-09-02 20:20 ` Patrick Venture
2021-09-03 14:51 ` Peter Maydell
0 siblings, 2 replies; 3+ messages in thread
From: Chris Rauer @ 2021-09-02 18:16 UTC (permalink / raw)
To: peter.maydell; +Cc: qemu-arm, qemu-devel, hskinnemoen, kfting, Chris Rauer
kudo-bmc is a board supported by OpenBMC.
https://github.com/openbmc/openbmc/tree/master/meta-fii/meta-kudo
Tested: Booted kudo firmware.
Signed-off-by: Chris Rauer <crauer@google.com>
---
docs/system/arm/nuvoton.rst | 1 +
hw/arm/npcm7xx_boards.c | 34 ++++++++++++++++++++++++++++++++++
2 files changed, 35 insertions(+)
diff --git a/docs/system/arm/nuvoton.rst b/docs/system/arm/nuvoton.rst
index 69f57c2886..adf497e679 100644
--- a/docs/system/arm/nuvoton.rst
+++ b/docs/system/arm/nuvoton.rst
@@ -20,6 +20,7 @@ Hyperscale applications. The following machines are based on this chip :
- ``quanta-gbs-bmc`` Quanta GBS server BMC
- ``quanta-gsj`` Quanta GSJ server BMC
+- ``kudo-bmc`` Fii USA Kudo server BMC
There are also two more SoCs, NPCM710 and NPCM705, which are single-core
variants of NPCM750 and NPCM730, respectively. These are currently not
diff --git a/hw/arm/npcm7xx_boards.c b/hw/arm/npcm7xx_boards.c
index e5a3243995..c80f442adb 100644
--- a/hw/arm/npcm7xx_boards.c
+++ b/hw/arm/npcm7xx_boards.c
@@ -31,6 +31,7 @@
#define NPCM750_EVB_POWER_ON_STRAPS 0x00001ff7
#define QUANTA_GSJ_POWER_ON_STRAPS 0x00001fff
#define QUANTA_GBS_POWER_ON_STRAPS 0x000017ff
+#define KUDO_BMC_POWER_ON_STRAPS 0x00001fff
static const char npcm7xx_default_bootrom[] = "npcm7xx_bootrom.bin";
@@ -357,6 +358,23 @@ static void quanta_gbs_init(MachineState *machine)
npcm7xx_load_kernel(machine, soc);
}
+static void kudo_bmc_init(MachineState *machine)
+{
+ NPCM7xxState *soc;
+
+ soc = npcm7xx_create_soc(machine, KUDO_BMC_POWER_ON_STRAPS);
+ npcm7xx_connect_dram(soc, machine->ram);
+ qdev_realize(DEVICE(soc), NULL, &error_fatal);
+
+ npcm7xx_load_bootrom(machine, soc);
+ npcm7xx_connect_flash(&soc->fiu[0], 0, "mx66u51235f",
+ drive_get(IF_MTD, 0, 0));
+ npcm7xx_connect_flash(&soc->fiu[1], 0, "mx66u51235f",
+ drive_get(IF_MTD, 3, 0));
+
+ npcm7xx_load_kernel(machine, soc);
+}
+
static void npcm7xx_set_soc_type(NPCM7xxMachineClass *nmc, const char *type)
{
NPCM7xxClass *sc = NPCM7XX_CLASS(object_class_by_name(type));
@@ -417,6 +435,18 @@ static void gbs_bmc_machine_class_init(ObjectClass *oc, void *data)
mc->default_ram_size = 1 * GiB;
}
+static void kudo_bmc_machine_class_init(ObjectClass *oc, void *data)
+{
+ NPCM7xxMachineClass *nmc = NPCM7XX_MACHINE_CLASS(oc);
+ MachineClass *mc = MACHINE_CLASS(oc);
+
+ npcm7xx_set_soc_type(nmc, TYPE_NPCM730);
+
+ mc->desc = "Kudo BMC (Cortex A9)";
+ mc->init = kudo_bmc_init;
+ mc->default_ram_size = 1 * GiB;
+};
+
static const TypeInfo npcm7xx_machine_types[] = {
{
.name = TYPE_NPCM7XX_MACHINE,
@@ -437,6 +467,10 @@ static const TypeInfo npcm7xx_machine_types[] = {
.name = MACHINE_TYPE_NAME("quanta-gbs-bmc"),
.parent = TYPE_NPCM7XX_MACHINE,
.class_init = gbs_bmc_machine_class_init,
+ }, {
+ .name = MACHINE_TYPE_NAME("kudo-bmc"),
+ .parent = TYPE_NPCM7XX_MACHINE,
+ .class_init = kudo_bmc_machine_class_init,
},
};
--
2.33.0.153.gba50c8fa24-goog
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] hw/arm: Add support for kudo-bmc board.
2021-09-02 18:16 [PATCH] hw/arm: Add support for kudo-bmc board Chris Rauer
@ 2021-09-02 20:20 ` Patrick Venture
2021-09-03 14:51 ` Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Patrick Venture @ 2021-09-02 20:20 UTC (permalink / raw)
To: Chris Rauer
Cc: Peter Maydell, qemu-arm, QEMU Developers, Havard Skinnemoen, CS20 KFTing
[-- Attachment #1: Type: text/plain, Size: 3485 bytes --]
On Thu, Sep 2, 2021 at 12:01 PM Chris Rauer <crauer@google.com> wrote:
> kudo-bmc is a board supported by OpenBMC.
> https://github.com/openbmc/openbmc/tree/master/meta-fii/meta-kudo
>
> Tested: Booted kudo firmware.
> Signed-off-by: Chris Rauer <crauer@google.com>
>
Reviewed-by: Patrick Venture <venture@google.com>
> ---
> docs/system/arm/nuvoton.rst | 1 +
> hw/arm/npcm7xx_boards.c | 34 ++++++++++++++++++++++++++++++++++
> 2 files changed, 35 insertions(+)
>
> diff --git a/docs/system/arm/nuvoton.rst b/docs/system/arm/nuvoton.rst
> index 69f57c2886..adf497e679 100644
> --- a/docs/system/arm/nuvoton.rst
> +++ b/docs/system/arm/nuvoton.rst
> @@ -20,6 +20,7 @@ Hyperscale applications. The following machines are
> based on this chip :
>
> - ``quanta-gbs-bmc`` Quanta GBS server BMC
> - ``quanta-gsj`` Quanta GSJ server BMC
> +- ``kudo-bmc`` Fii USA Kudo server BMC
>
> There are also two more SoCs, NPCM710 and NPCM705, which are single-core
> variants of NPCM750 and NPCM730, respectively. These are currently not
> diff --git a/hw/arm/npcm7xx_boards.c b/hw/arm/npcm7xx_boards.c
> index e5a3243995..c80f442adb 100644
> --- a/hw/arm/npcm7xx_boards.c
> +++ b/hw/arm/npcm7xx_boards.c
> @@ -31,6 +31,7 @@
> #define NPCM750_EVB_POWER_ON_STRAPS 0x00001ff7
> #define QUANTA_GSJ_POWER_ON_STRAPS 0x00001fff
> #define QUANTA_GBS_POWER_ON_STRAPS 0x000017ff
> +#define KUDO_BMC_POWER_ON_STRAPS 0x00001fff
>
> static const char npcm7xx_default_bootrom[] = "npcm7xx_bootrom.bin";
>
> @@ -357,6 +358,23 @@ static void quanta_gbs_init(MachineState *machine)
> npcm7xx_load_kernel(machine, soc);
> }
>
> +static void kudo_bmc_init(MachineState *machine)
> +{
> + NPCM7xxState *soc;
> +
> + soc = npcm7xx_create_soc(machine, KUDO_BMC_POWER_ON_STRAPS);
> + npcm7xx_connect_dram(soc, machine->ram);
> + qdev_realize(DEVICE(soc), NULL, &error_fatal);
> +
> + npcm7xx_load_bootrom(machine, soc);
> + npcm7xx_connect_flash(&soc->fiu[0], 0, "mx66u51235f",
> + drive_get(IF_MTD, 0, 0));
> + npcm7xx_connect_flash(&soc->fiu[1], 0, "mx66u51235f",
> + drive_get(IF_MTD, 3, 0));
> +
> + npcm7xx_load_kernel(machine, soc);
> +}
> +
> static void npcm7xx_set_soc_type(NPCM7xxMachineClass *nmc, const char
> *type)
> {
> NPCM7xxClass *sc = NPCM7XX_CLASS(object_class_by_name(type));
> @@ -417,6 +435,18 @@ static void gbs_bmc_machine_class_init(ObjectClass
> *oc, void *data)
> mc->default_ram_size = 1 * GiB;
> }
>
> +static void kudo_bmc_machine_class_init(ObjectClass *oc, void *data)
> +{
> + NPCM7xxMachineClass *nmc = NPCM7XX_MACHINE_CLASS(oc);
> + MachineClass *mc = MACHINE_CLASS(oc);
> +
> + npcm7xx_set_soc_type(nmc, TYPE_NPCM730);
> +
> + mc->desc = "Kudo BMC (Cortex A9)";
> + mc->init = kudo_bmc_init;
> + mc->default_ram_size = 1 * GiB;
> +};
> +
> static const TypeInfo npcm7xx_machine_types[] = {
> {
> .name = TYPE_NPCM7XX_MACHINE,
> @@ -437,6 +467,10 @@ static const TypeInfo npcm7xx_machine_types[] = {
> .name = MACHINE_TYPE_NAME("quanta-gbs-bmc"),
> .parent = TYPE_NPCM7XX_MACHINE,
> .class_init = gbs_bmc_machine_class_init,
> + }, {
> + .name = MACHINE_TYPE_NAME("kudo-bmc"),
> + .parent = TYPE_NPCM7XX_MACHINE,
> + .class_init = kudo_bmc_machine_class_init,
> },
> };
>
> --
> 2.33.0.153.gba50c8fa24-goog
>
>
>
[-- Attachment #2: Type: text/html, Size: 4694 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] hw/arm: Add support for kudo-bmc board.
2021-09-02 18:16 [PATCH] hw/arm: Add support for kudo-bmc board Chris Rauer
2021-09-02 20:20 ` Patrick Venture
@ 2021-09-03 14:51 ` Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Peter Maydell @ 2021-09-03 14:51 UTC (permalink / raw)
To: Chris Rauer; +Cc: CS20 KFTing, qemu-arm, QEMU Developers, Havard Skinnemoen
On Thu, 2 Sept 2021 at 19:17, Chris Rauer <crauer@google.com> wrote:
>
> kudo-bmc is a board supported by OpenBMC.
> https://github.com/openbmc/openbmc/tree/master/meta-fii/meta-kudo
>
> Tested: Booted kudo firmware.
> Signed-off-by: Chris Rauer <crauer@google.com>
> +static void kudo_bmc_machine_class_init(ObjectClass *oc, void *data)
> +{
> + NPCM7xxMachineClass *nmc = NPCM7XX_MACHINE_CLASS(oc);
> + MachineClass *mc = MACHINE_CLASS(oc);
> +
> + npcm7xx_set_soc_type(nmc, TYPE_NPCM730);
> +
> + mc->desc = "Kudo BMC (Cortex A9)";
"Cortex-A9" should be hyphenated; see commit f548f20176c.
> + mc->init = kudo_bmc_init;
> + mc->default_ram_size = 1 * GiB;
> +};
-- PMM
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-09-03 14:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-02 18:16 [PATCH] hw/arm: Add support for kudo-bmc board Chris Rauer
2021-09-02 20:20 ` Patrick Venture
2021-09-03 14:51 ` Peter Maydell
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.