From 7267c0947d7e8ae5dff7bafd932c3bc285f43e5c Mon Sep 17 00:00:00 2001 From: Anthony Liguori Date: Sat, 20 Aug 2011 22:09:37 -0500 Subject: Use glib memory allocation and free functions qemu_malloc/qemu_free no longer exist after this commit. Signed-off-by: Anthony Liguori --- hw/omap_gpio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'hw/omap_gpio.c') diff --git a/hw/omap_gpio.c b/hw/omap_gpio.c index c23964c..42e59c3 100644 --- a/hw/omap_gpio.c +++ b/hw/omap_gpio.c @@ -696,8 +696,8 @@ static int omap2_gpio_init(SysBusDevice *dev) } else { s->modulecount = 6; } - s->modules = qemu_mallocz(s->modulecount * sizeof(struct omap2_gpio_s)); - s->handler = qemu_mallocz(s->modulecount * 32 * sizeof(qemu_irq)); + s->modules = g_malloc0(s->modulecount * sizeof(struct omap2_gpio_s)); + s->handler = g_malloc0(s->modulecount * 32 * sizeof(qemu_irq)); qdev_init_gpio_in(&dev->qdev, omap2_gpio_set, s->modulecount * 32); qdev_init_gpio_out(&dev->qdev, s->handler, s->modulecount * 32); for (i = 0; i < s->modulecount; i++) { -- cgit v1.1