From: Peter Maydell <peter.maydell@linaro.org>
To: qemu-devel@nongnu.org
Cc: Avi Kivity <avi@redhat.com>, patches@linaro.org
Subject: [Qemu-devel] [PATCH 1/2] hw/arm11mpcore: Clean up to avoid using sysbus_mmio_init_cb2
Date: Thu, 1 Sep 2011 18:36:52 +0100 [thread overview]
Message-ID: <1314898613-2066-2-git-send-email-peter.maydell@linaro.org> (raw)
In-Reply-To: <1314898613-2066-1-git-send-email-peter.maydell@linaro.org>
Clean up the initialisation of the realview_mpcore device to avoid
using sysbus_init_mmio_cb2(): we can pass through the MemoryRegion
of the private arm11mpcore_priv device directly now.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
hw/arm11mpcore.c | 13 +------------
1 files changed, 1 insertions(+), 12 deletions(-)
diff --git a/hw/arm11mpcore.c b/hw/arm11mpcore.c
index 7d60ef6..974a0d8 100644
--- a/hw/arm11mpcore.c
+++ b/hw/arm11mpcore.c
@@ -48,17 +48,6 @@ static void mpcore_rirq_set_irq(void *opaque, int irq, int level)
}
}
-static void mpcore_rirq_map(SysBusDevice *dev, target_phys_addr_t base)
-{
- mpcore_rirq_state *s = FROM_SYSBUS(mpcore_rirq_state, dev);
- sysbus_mmio_map(s->priv, 0, base);
-}
-
-static void mpcore_rirq_unmap(SysBusDevice *dev, target_phys_addr_t base)
-{
- /* nothing to do */
-}
-
static int realview_mpcore_init(SysBusDevice *dev)
{
mpcore_rirq_state *s = FROM_SYSBUS(mpcore_rirq_state, dev);
@@ -84,7 +73,7 @@ static int realview_mpcore_init(SysBusDevice *dev)
}
}
qdev_init_gpio_in(&dev->qdev, mpcore_rirq_set_irq, 64);
- sysbus_init_mmio_cb2(dev, mpcore_rirq_map, mpcore_rirq_unmap);
+ sysbus_init_mmio_region(dev, sysbus_mmio_get_region(s->priv, 0));
return 0;
}
--
1.7.1
next prev parent reply other threads:[~2011-09-01 17:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-01 17:36 [Qemu-devel] [PATCH 0/2] versatile: cleanups to remove use of sysbus_mmio_init_cb2 Peter Maydell
2011-09-01 17:36 ` Peter Maydell [this message]
2011-09-01 17:36 ` [Qemu-devel] [PATCH 2/2] hw/versatile_pci: Expose multiple sysbus mmio regions Peter Maydell
2011-09-12 15:01 ` [Qemu-devel] [PATCH 0/2] versatile: cleanups to remove use of sysbus_mmio_init_cb2 Peter Maydell
2011-09-13 12:29 ` Avi Kivity
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=1314898613-2066-2-git-send-email-peter.maydell@linaro.org \
--to=peter.maydell@linaro.org \
--cc=avi@redhat.com \
--cc=patches@linaro.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).