diff options
author | Steven Lee <steven_lee@aspeedtech.com> | 2025-05-23 17:31:38 +0800 |
---|---|---|
committer | Cédric Le Goater <clg@redhat.com> | 2025-05-25 23:39:11 +0200 |
commit | 453b928ab93415ebf5519d946a77e905a2f1ec12 (patch) | |
tree | a9750fa99f9c0ce30511e67e8cca5a76ef480784 | |
parent | e6941ac106190490d8b455eedc5b368e6d94d4cc (diff) | |
download | qemu-453b928ab93415ebf5519d946a77e905a2f1ec12.zip qemu-453b928ab93415ebf5519d946a77e905a2f1ec12.tar.gz qemu-453b928ab93415ebf5519d946a77e905a2f1ec12.tar.bz2 |
hw/arm/aspeed_ast2700-fc: Add network support
This patch adds network support to the ast2700fc machine by initializing
the NIC device in the ca35.
Signed-off-by: Steven Lee <steven_lee@aspeedtech.com>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
Link: https://lore.kernel.org/qemu-devel/20250523093144.991408-2-steven_lee@aspeedtech.com
Signed-off-by: Cédric Le Goater <clg@redhat.com>
-rw-r--r-- | hw/arm/aspeed_ast27x0-fc.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/hw/arm/aspeed_ast27x0-fc.c b/hw/arm/aspeed_ast27x0-fc.c index 125a3ad..7bf4f2a 100644 --- a/hw/arm/aspeed_ast27x0-fc.c +++ b/hw/arm/aspeed_ast27x0-fc.c @@ -86,6 +86,13 @@ static void ast2700fc_ca35_init(MachineState *machine) AST2700FC_BMC_RAM_SIZE, &error_abort)) { return; } + + for (int i = 0; i < sc->macs_num; i++) { + if (!qemu_configure_nic_device(DEVICE(&soc->ftgmac100[i]), + true, NULL)) { + break; + } + } if (!object_property_set_int(OBJECT(&s->ca35), "hw-strap1", AST2700FC_HW_STRAP1, &error_abort)) { return; |