Patchwork [v6,10/16] petalogix_ml605_mmu: Attach ethernet to machine

login
register
mail settings
Submitter Peter Crosthwaite
Date April 16, 2013, 12:24 a.m.
Message ID <0273b4520d944559c91dca6c4ef0e2034efb444a.1366069170.git.peter.crosthwaite@xilinx.com>
Download mbox | patch
Permalink /patch/236785/
State New
Headers show

Comments

Peter Crosthwaite - April 16, 2013, 12:24 a.m.
From: Peter Crosthwaite <peter.crosthwaite@xilinx.com>

Explicitly make the ethernet a child of the machine. This is needed to set
and use links pre-realize. Also makes the ethernet initialization consistent
with its peer DMA.

Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
Reviewed-by: Andreas Färber <afaerber@suse.de>
Acked-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
---

 hw/microblaze/petalogix_ml605_mmu.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

Patch

diff --git a/hw/microblaze/petalogix_ml605_mmu.c b/hw/microblaze/petalogix_ml605_mmu.c
index d7391e7..ea1e772 100644
--- a/hw/microblaze/petalogix_ml605_mmu.c
+++ b/hw/microblaze/petalogix_ml605_mmu.c
@@ -134,6 +134,8 @@  petalogix_ml605_init(QEMUMachineInitArgs *args)
     dma = qdev_create(NULL, "xlnx.axi-dma");
 
     /* FIXME: attach to the sysbus instead */
+    object_property_add_child(qdev_get_machine(), "xilinx-eth", OBJECT(eth0),
+                              NULL);
     object_property_add_child(qdev_get_machine(), "xilinx-dma", OBJECT(dma),
                               NULL);