From 3110ce819278f1b6d2c4fdd3e15e773e8f226316 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Date: Thu, 17 Oct 2019 18:03:43 +0200 Subject: dp8393x: replace PROP_PTR with PROP_LINK MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Link property is the correct way to pass a MemoryRegion to a device for DMA purposes. Sidenote: as a sysbus device, this remains non-usercreatable even though we can drop the specific flag here. Signed-off-by: Marc-André Lureau Reviewed-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Laurent Vivier Tested-by: Laurent Vivier --- hw/m68k/q800.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'hw/m68k') diff --git a/hw/m68k/q800.c b/hw/m68k/q800.c index 4ca8678007..8f3eb6bfe7 100644 --- a/hw/m68k/q800.c +++ b/hw/m68k/q800.c @@ -239,7 +239,8 @@ static void q800_init(MachineState *machine) qdev_set_nic_properties(dev, &nd_table[0]); qdev_prop_set_uint8(dev, "it_shift", 2); qdev_prop_set_bit(dev, "big_endian", true); - qdev_prop_set_ptr(dev, "dma_mr", get_system_memory()); + object_property_set_link(OBJECT(dev), OBJECT(get_system_memory()), + "dma_mr", &error_abort); qdev_init_nofail(dev); sysbus = SYS_BUS_DEVICE(dev); sysbus_mmio_map(sysbus, 0, SONIC_BASE); -- cgit v1.2.3