Patchwork [07/14] sysbus: add an id argument to sysbus_create_simple()

login
register
mail settings
Submitter Anthony Liguori
Date Sept. 16, 2011, 4 p.m.
Message ID <1316188834-13675-8-git-send-email-aliguori@us.ibm.com>
Download mbox | patch
Permalink /patch/114975/
State New
Headers show

Comments

Anthony Liguori - Sept. 16, 2011, 4 p.m.
This is mechanical.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
---
 hw/arm11mpcore.c              |    2 +-
 hw/axis_dev88.c               |    2 +-
 hw/collie.c                   |    2 +-
 hw/integratorcp.c             |   14 +++++++-------
 hw/kvmclock.c                 |    2 +-
 hw/lm32_boards.c              |   14 +++++++-------
 hw/mainstone.c                |    2 +-
 hw/musicpal.c                 |   14 +++++++-------
 hw/pc.c                       |    2 +-
 hw/petalogix_s3adsp1800_mmu.c |    2 +-
 hw/ppce500_mpc8544ds.c        |    2 +-
 hw/pxa2xx.c                   |   18 ++++++++++++------
 hw/realview.c                 |   32 ++++++++++++++++----------------
 hw/spitz.c                    |    6 +++---
 hw/stellaris.c                |   10 +++++-----
 hw/strongarm.c                |    3 ++-
 hw/sun4m.c                    |    2 +-
 hw/syborg.c                   |   18 +++++++++---------
 hw/sysbus.h                   |    6 ++++--
 hw/tosa.c                     |    4 ++--
 hw/versatilepb.c              |   24 ++++++++++++------------
 hw/vexpress.c                 |   22 +++++++++++-----------
 22 files changed, 106 insertions(+), 97 deletions(-)

Patch

diff --git a/hw/arm11mpcore.c b/hw/arm11mpcore.c
index 0e456a2..9bbd684 100644
--- a/hw/arm11mpcore.c
+++ b/hw/arm11mpcore.c
@@ -78,7 +78,7 @@  static int realview_mpcore_init(SysBusDevice *dev)
     /* ??? IRQ routing is hardcoded to "normal" mode.  */
     for (n = 0; n < 4; n++) {
         gic = sysbus_create_simple("realview_gic", 0x10040000 + n * 0x10000,
-                                   s->cpuic[10 + n]);
+                                   s->cpuic[10 + n], NULL);
         for (i = 0; i < 64; i++) {
             s->rvic[n][i] = qdev_get_gpio_in(gic, i);
         }
diff --git a/hw/axis_dev88.c b/hw/axis_dev88.c
index 752c573..6987387 100644
--- a/hw/axis_dev88.c
+++ b/hw/axis_dev88.c
@@ -335,7 +335,7 @@  void axisdev88_init (ram_addr_t ram_size,
 
     for (i = 0; i < 4; i++) {
         sysbus_create_simple("etraxfs,serial", 0x30026000 + i * 0x2000,
-                             irq[0x14 + i]);
+                             irq[0x14 + i], NULL);
     }
 
     if (!kernel_filename) {
diff --git a/hw/collie.c b/hw/collie.c
index a10cc1b..c123bf1 100644
--- a/hw/collie.c
+++ b/hw/collie.c
@@ -43,7 +43,7 @@  static void collie_init(ram_addr_t ram_size,
                     dinfo ? dinfo->bdrv : NULL, (64 * 1024),
                     512, 4, 0x00, 0x00, 0x00, 0x00, 0);
 
-    sysbus_create_simple("scoop", 0x40800000, NULL);
+    sysbus_create_simple("scoop", 0x40800000, NULL, NULL);
 
     collie_binfo.kernel_filename = kernel_filename;
     collie_binfo.kernel_cmdline = kernel_cmdline;
diff --git a/hw/integratorcp.c b/hw/integratorcp.c
index 34ead1b..a163cf1 100644
--- a/hw/integratorcp.c
+++ b/hw/integratorcp.c
@@ -507,20 +507,20 @@  static void integratorcp_init(ram_addr_t ram_size,
     for (i = 0; i < 32; i++) {
         pic[i] = qdev_get_gpio_in(dev, i);
     }
-    sysbus_create_simple("integrator_pic", 0xca000000, pic[26]);
+    sysbus_create_simple("integrator_pic", 0xca000000, pic[26], NULL);
     sysbus_create_varargs("integrator_pit", 0x13000000,
                           pic[5], pic[6], pic[7], NULL);
-    sysbus_create_simple("pl031", 0x15000000, pic[8]);
-    sysbus_create_simple("pl011", 0x16000000, pic[1]);
-    sysbus_create_simple("pl011", 0x17000000, pic[2]);
+    sysbus_create_simple("pl031", 0x15000000, pic[8], NULL);
+    sysbus_create_simple("pl011", 0x16000000, pic[1], NULL);
+    sysbus_create_simple("pl011", 0x17000000, pic[2], NULL);
     icp_control_init(0xcb000000);
-    sysbus_create_simple("pl050_keyboard", 0x18000000, pic[3]);
-    sysbus_create_simple("pl050_mouse", 0x19000000, pic[4]);
+    sysbus_create_simple("pl050_keyboard", 0x18000000, pic[3], NULL);
+    sysbus_create_simple("pl050_mouse", 0x19000000, pic[4], NULL);
     sysbus_create_varargs("pl181", 0x1c000000, pic[23], pic[24], NULL);
     if (nd_table[0].vlan)
         smc91c111_init(&nd_table[0], 0xc8000000, pic[27]);
 
-    sysbus_create_simple("pl110", 0xc0000000, pic[22]);
+    sysbus_create_simple("pl110", 0xc0000000, pic[22], NULL);
 
     integrator_binfo.ram_size = ram_size;
     integrator_binfo.kernel_filename = kernel_filename;
diff --git a/hw/kvmclock.c b/hw/kvmclock.c
index b73aec4..f920b10 100644
--- a/hw/kvmclock.c
+++ b/hw/kvmclock.c
@@ -103,7 +103,7 @@  void kvmclock_create(void)
     if (kvm_enabled() &&
         first_cpu->cpuid_kvm_features & ((1ULL << KVM_FEATURE_CLOCKSOURCE) |
                                          (1ULL << KVM_FEATURE_CLOCKSOURCE2))) {
-        sysbus_create_simple("kvmclock", -1, NULL);
+        sysbus_create_simple("kvmclock", -1, NULL, NULL);
     }
 }
 
diff --git a/hw/lm32_boards.c b/hw/lm32_boards.c
index 97e1c00..0ffb70d 100644
--- a/hw/lm32_boards.c
+++ b/hw/lm32_boards.c
@@ -123,9 +123,9 @@  static void lm32_evr_init(ram_addr_t ram_size_not_used,
         irq[i] = qdev_get_gpio_in(env->pic_state, i);
     }
 
-    sysbus_create_simple("lm32-uart", uart0_base, irq[uart0_irq]);
-    sysbus_create_simple("lm32-timer", timer0_base, irq[timer0_irq]);
-    sysbus_create_simple("lm32-timer", timer1_base, irq[timer1_irq]);
+    sysbus_create_simple("lm32-uart", uart0_base, irq[uart0_irq], NULL);
+    sysbus_create_simple("lm32-timer", timer0_base, irq[timer0_irq], NULL);
+    sysbus_create_simple("lm32-timer", timer1_base, irq[timer1_irq], NULL);
 
     /* make sure juart isn't the first chardev */
     env->juart_state = lm32_juart_init();
@@ -217,10 +217,10 @@  static void lm32_uclinux_init(ram_addr_t ram_size_not_used,
         irq[i] = qdev_get_gpio_in(env->pic_state, i);
     }
 
-    sysbus_create_simple("lm32-uart", uart0_base, irq[uart0_irq]);
-    sysbus_create_simple("lm32-timer", timer0_base, irq[timer0_irq]);
-    sysbus_create_simple("lm32-timer", timer1_base, irq[timer1_irq]);
-    sysbus_create_simple("lm32-timer", timer2_base, irq[timer2_irq]);
+    sysbus_create_simple("lm32-uart", uart0_base, irq[uart0_irq], NULL);
+    sysbus_create_simple("lm32-timer", timer0_base, irq[timer0_irq], NULL);
+    sysbus_create_simple("lm32-timer", timer1_base, irq[timer1_irq], NULL);
+    sysbus_create_simple("lm32-timer", timer2_base, irq[timer2_irq], NULL);
 
     /* make sure juart isn't the first chardev */
     env->juart_state = lm32_juart_init();
diff --git a/hw/mainstone.c b/hw/mainstone.c
index 336f31e..ba4941c 100644
--- a/hw/mainstone.c
+++ b/hw/mainstone.c
@@ -141,7 +141,7 @@  static void mainstone_common_init(MemoryRegion *address_space_mem,
     }
 
     mst_irq = sysbus_create_simple("mainstone-fpga", MST_FPGA_PHYS,
-                    qdev_get_gpio_in(cpu->gpio, 0));
+                                   qdev_get_gpio_in(cpu->gpio, 0), NULL);
 
     /* setup keypad */
     printf("map addr %p\n", &map);
diff --git a/hw/musicpal.c b/hw/musicpal.c
index f204bff..1a4f865 100644
--- a/hw/musicpal.c
+++ b/hw/musicpal.c
@@ -1522,7 +1522,7 @@  static void musicpal_init(ram_addr_t ram_size,
     cpu_register_physical_memory(MP_SRAM_BASE, MP_SRAM_SIZE, sram_off);
 
     dev = sysbus_create_simple("mv88w8618_pic", MP_PIC_BASE,
-                               cpu_pic[ARM_PIC_CPU_IRQ]);
+                               cpu_pic[ARM_PIC_CPU_IRQ], NULL);
     for (i = 0; i < 32; i++) {
         pic[i] = qdev_get_gpio_in(dev, i);
     }
@@ -1583,7 +1583,7 @@  static void musicpal_init(ram_addr_t ram_size,
 #endif
 
     }
-    sysbus_create_simple("mv88w8618_flashcfg", MP_FLASHCFG_BASE, NULL);
+    sysbus_create_simple("mv88w8618_flashcfg", MP_FLASHCFG_BASE, NULL, NULL);
 
     qemu_check_nic_model(&nd_table[0], "mv88w8618");
     dev = qdev_create(NULL, "mv88w8618_eth", NULL);
@@ -1592,16 +1592,16 @@  static void musicpal_init(ram_addr_t ram_size,
     sysbus_mmio_map(sysbus_from_qdev(dev), 0, MP_ETH_BASE);
     sysbus_connect_irq(sysbus_from_qdev(dev), 0, pic[MP_ETH_IRQ]);
 
-    sysbus_create_simple("mv88w8618_wlan", MP_WLAN_BASE, NULL);
+    sysbus_create_simple("mv88w8618_wlan", MP_WLAN_BASE, NULL, NULL);
 
     musicpal_misc_init();
 
-    dev = sysbus_create_simple("musicpal_gpio", MP_GPIO_BASE, pic[MP_GPIO_IRQ]);
-    i2c_dev = sysbus_create_simple("gpio_i2c", -1, NULL);
+    dev = sysbus_create_simple("musicpal_gpio", MP_GPIO_BASE, pic[MP_GPIO_IRQ], NULL);
+    i2c_dev = sysbus_create_simple("gpio_i2c", -1, NULL, NULL);
     i2c = (i2c_bus *)qdev_get_child_bus(i2c_dev, "i2c");
 
-    lcd_dev = sysbus_create_simple("musicpal_lcd", MP_LCD_BASE, NULL);
-    key_dev = sysbus_create_simple("musicpal_key", -1, NULL);
+    lcd_dev = sysbus_create_simple("musicpal_lcd", MP_LCD_BASE, NULL, NULL);
+    key_dev = sysbus_create_simple("musicpal_key", -1, NULL, NULL);
 
     /* I2C read data */
     qdev_connect_gpio_out(i2c_dev, 0,
diff --git a/hw/pc.c b/hw/pc.c
index 236f742..a6d0f47 100644
--- a/hw/pc.c
+++ b/hw/pc.c
@@ -875,7 +875,7 @@  static DeviceState *apic_init(void *env, uint8_t apic_id)
     SysBusDevice *d;
     static int apic_mapped;
 
-    dev = qdev_create(NULL, "apic", NULL);
+    dev = qdev_create(NULL, "apic", "::apic[%d]", apic_id);
     qdev_prop_set_uint8(dev, "index", apic_id);
     qdev_prop_set_ptr(dev, "cpu_env", env);
     qdev_init_nofail(dev);
diff --git a/hw/petalogix_s3adsp1800_mmu.c b/hw/petalogix_s3adsp1800_mmu.c
index 66fb96d..cc81ba7 100644
--- a/hw/petalogix_s3adsp1800_mmu.c
+++ b/hw/petalogix_s3adsp1800_mmu.c
@@ -160,7 +160,7 @@  petalogix_s3adsp1800_init(ram_addr_t ram_size,
         irq[i] = qdev_get_gpio_in(dev, i);
     }
 
-    sysbus_create_simple("xilinx,uartlite", 0x84000000, irq[3]);
+    sysbus_create_simple("xilinx,uartlite", 0x84000000, irq[3], NULL);
     /* 2 timers at irq 2 @ 62 Mhz.  */
     xilinx_timer_create(0x83c00000, irq[0], 2, 62 * 1000000);
     xilinx_ethlite_create(&nd_table[0], 0x81000000, irq[1], 0, 0);
diff --git a/hw/ppce500_mpc8544ds.c b/hw/ppce500_mpc8544ds.c
index 1274a3e..f2989a8 100644
--- a/hw/ppce500_mpc8544ds.c
+++ b/hw/ppce500_mpc8544ds.c
@@ -286,7 +286,7 @@  static void mpc8544ds_init(ram_addr_t ram_size,
     }
 
     /* General Utility device */
-    sysbus_create_simple("mpc8544-guts", MPC8544_UTIL_BASE, NULL);
+    sysbus_create_simple("mpc8544-guts", MPC8544_UTIL_BASE, NULL, NULL);
 
     /* PCI */
     dev = sysbus_create_varargs("e500-pcihost", MPC8544_PCI_REGS_BASE,
diff --git a/hw/pxa2xx.c b/hw/pxa2xx.c
index 82538dd..089d54d 100644
--- a/hw/pxa2xx.c
+++ b/hw/pxa2xx.c
@@ -2166,20 +2166,23 @@  PXA2xxState *pxa270_init(unsigned int sdram_size, const char *revision)
     for (i = 0; pxa27x_ssp[i].io_base; i ++) {
         DeviceState *dev;
         dev = sysbus_create_simple("pxa2xx-ssp", pxa27x_ssp[i].io_base,
-                        qdev_get_gpio_in(s->pic, pxa27x_ssp[i].irqn));
+                                   qdev_get_gpio_in(s->pic, pxa27x_ssp[i].irqn),
+                                   NULL);
         s->ssp[i] = (SSIBus *)qdev_get_child_bus(dev, "ssi");
     }
 
     if (usb_enabled) {
         sysbus_create_simple("sysbus-ohci", 0x4c000000,
-                        qdev_get_gpio_in(s->pic, PXA2XX_PIC_USBH1));
+                             qdev_get_gpio_in(s->pic, PXA2XX_PIC_USBH1),
+                             NULL);
     }
 
     s->pcmcia[0] = pxa2xx_pcmcia_init(0x20000000);
     s->pcmcia[1] = pxa2xx_pcmcia_init(0x30000000);
 
     sysbus_create_simple("pxa2xx_rtc", 0x40900000,
-                    qdev_get_gpio_in(s->pic, PXA2XX_PIC_RTCALARM));
+                         qdev_get_gpio_in(s->pic, PXA2XX_PIC_RTCALARM),
+                         NULL);
 
     s->i2c[0] = pxa2xx_i2c_init(0x40301600,
                     qdev_get_gpio_in(s->pic, PXA2XX_PIC_I2C), 0xffff);
@@ -2302,20 +2305,23 @@  PXA2xxState *pxa255_init(unsigned int sdram_size)
     for (i = 0; pxa255_ssp[i].io_base; i ++) {
         DeviceState *dev;
         dev = sysbus_create_simple("pxa2xx-ssp", pxa255_ssp[i].io_base,
-                        qdev_get_gpio_in(s->pic, pxa255_ssp[i].irqn));
+                                   qdev_get_gpio_in(s->pic, pxa255_ssp[i].irqn),
+                                   NULL);
         s->ssp[i] = (SSIBus *)qdev_get_child_bus(dev, "ssi");
     }
 
     if (usb_enabled) {
         sysbus_create_simple("sysbus-ohci", 0x4c000000,
-                        qdev_get_gpio_in(s->pic, PXA2XX_PIC_USBH1));
+                             qdev_get_gpio_in(s->pic, PXA2XX_PIC_USBH1),
+                             NULL);
     }
 
     s->pcmcia[0] = pxa2xx_pcmcia_init(0x20000000);
     s->pcmcia[1] = pxa2xx_pcmcia_init(0x30000000);
 
     sysbus_create_simple("pxa2xx_rtc", 0x40900000,
-                    qdev_get_gpio_in(s->pic, PXA2XX_PIC_RTCALARM));
+                         qdev_get_gpio_in(s->pic, PXA2XX_PIC_RTCALARM),
+                         NULL);
 
     s->i2c[0] = pxa2xx_i2c_init(0x40301600,
                     qdev_get_gpio_in(s->pic, PXA2XX_PIC_I2C), 0xffff);
diff --git a/hw/realview.c b/hw/realview.c
index 301739a..0f532d9 100644
--- a/hw/realview.c
+++ b/hw/realview.c
@@ -227,31 +227,31 @@  static void realview_init(ram_addr_t ram_size,
     } else {
         uint32_t gic_addr = is_pb ? 0x1e000000 : 0x10040000;
         /* For now just create the nIRQ GIC, and ignore the others.  */
-        dev = sysbus_create_simple("realview_gic", gic_addr, cpu_irq[0]);
+        dev = sysbus_create_simple("realview_gic", gic_addr, cpu_irq[0], NULL);
     }
     for (n = 0; n < 64; n++) {
         pic[n] = qdev_get_gpio_in(dev, n);
     }
 
-    sysbus_create_simple("pl050_keyboard", 0x10006000, pic[20]);
-    sysbus_create_simple("pl050_mouse", 0x10007000, pic[21]);
+    sysbus_create_simple("pl050_keyboard", 0x10006000, pic[20], NULL);
+    sysbus_create_simple("pl050_mouse", 0x10007000, pic[21], NULL);
 
-    sysbus_create_simple("pl011", 0x10009000, pic[12]);
-    sysbus_create_simple("pl011", 0x1000a000, pic[13]);
-    sysbus_create_simple("pl011", 0x1000b000, pic[14]);
-    sysbus_create_simple("pl011", 0x1000c000, pic[15]);
+    sysbus_create_simple("pl011", 0x10009000, pic[12], NULL);
+    sysbus_create_simple("pl011", 0x1000a000, pic[13], NULL);
+    sysbus_create_simple("pl011", 0x1000b000, pic[14], NULL);
+    sysbus_create_simple("pl011", 0x1000c000, pic[15], NULL);
 
     /* DMA controller is optional, apparently.  */
-    sysbus_create_simple("pl081", 0x10030000, pic[24]);
+    sysbus_create_simple("pl081", 0x10030000, pic[24], NULL);
 
-    sysbus_create_simple("sp804", 0x10011000, pic[4]);
-    sysbus_create_simple("sp804", 0x10012000, pic[5]);
+    sysbus_create_simple("sp804", 0x10011000, pic[4], NULL);
+    sysbus_create_simple("sp804", 0x10012000, pic[5], NULL);
 
-    sysbus_create_simple("pl061", 0x10013000, pic[6]);
-    sysbus_create_simple("pl061", 0x10014000, pic[7]);
-    gpio2 = sysbus_create_simple("pl061", 0x10015000, pic[8]);
+    sysbus_create_simple("pl061", 0x10013000, pic[6], NULL);
+    sysbus_create_simple("pl061", 0x10014000, pic[7], NULL);
+    gpio2 = sysbus_create_simple("pl061", 0x10015000, pic[8], NULL);
 
-    sysbus_create_simple("pl111", 0x10020000, pic[23]);
+    sysbus_create_simple("pl111", 0x10020000, pic[23], NULL);
 
     dev = sysbus_create_varargs("pl181", 0x10005000, pic[17], pic[18], NULL);
     /* Wire up MMC card detect and read-only signals. These have
@@ -269,7 +269,7 @@  static void realview_init(ram_addr_t ram_size,
     qdev_connect_gpio_out(dev, 0, mmc_irq[0]);
     qdev_connect_gpio_out(dev, 1, mmc_irq[1]);
 
-    sysbus_create_simple("pl031", 0x10017000, pic[10]);
+    sysbus_create_simple("pl031", 0x10017000, pic[10], NULL);
 
     if (!is_pb) {
         dev = sysbus_create_varargs("realview_pci", 0x60000000,
@@ -300,7 +300,7 @@  static void realview_init(ram_addr_t ram_size,
         }
     }
 
-    dev = sysbus_create_simple("realview_i2c", 0x10002000, NULL);
+    dev = sysbus_create_simple("realview_i2c", 0x10002000, NULL, NULL);
     i2c = (i2c_bus *)qdev_get_child_bus(dev, "i2c");
     i2c_create_slave(i2c, "ds1338", 0x68);
 
diff --git a/hw/spitz.c b/hw/spitz.c
index 90183d4..ea49cdf 100644
--- a/hw/spitz.c
+++ b/hw/spitz.c
@@ -468,7 +468,7 @@  static void spitz_keyboard_register(PXA2xxState *cpu)
     DeviceState *dev;
     SpitzKeyboardState *s;
 
-    dev = sysbus_create_simple("spitz-keyboard", -1, NULL);
+    dev = sysbus_create_simple("spitz-keyboard", -1, NULL, NULL);
     s = FROM_SYSBUS(SpitzKeyboardState, sysbus_from_qdev(dev));
 
     for (i = 0; i < SPITZ_KEY_SENSE_NUM; i ++)
@@ -913,9 +913,9 @@  static void spitz_common_init(ram_addr_t ram_size,
 
     spitz_ssp_attach(cpu);
 
-    scp0 = sysbus_create_simple("scoop", 0x10800000, NULL);
+    scp0 = sysbus_create_simple("scoop", 0x10800000, NULL, NULL);
     if (model != akita) {
-        scp1 = sysbus_create_simple("scoop", 0x08800040, NULL);
+        scp1 = sysbus_create_simple("scoop", 0x08800040, NULL, NULL);
     }
 
     spitz_scoop_gpio_setup(cpu, scp0, scp1);
diff --git a/hw/stellaris.c b/hw/stellaris.c
index 2345692..8d344c8 100644
--- a/hw/stellaris.c
+++ b/hw/stellaris.c
@@ -1290,7 +1290,7 @@  static void stellaris_init(const char *kernel_filename, const char *cpu_model,
         if (board->dc2 & (0x10000 << i)) {
             dev = sysbus_create_simple("stellaris-gptm",
                                        0x40030000 + i * 0x1000,
-                                       pic[timer_irq[i]]);
+                                       pic[timer_irq[i]], NULL);
             /* TODO: This is incorrect, but we get away with it because
                the ADC output is only ever pulsed.  */
             qdev_connect_gpio_out(dev, 0, adc);
@@ -1302,7 +1302,7 @@  static void stellaris_init(const char *kernel_filename, const char *cpu_model,
     for (i = 0; i < 7; i++) {
         if (board->dc4 & (1 << i)) {
             gpio_dev[i] = sysbus_create_simple("pl061_luminary", gpio_addr[i],
-                                               pic[gpio_irq[i]]);
+                                               pic[gpio_irq[i]], NULL);
             for (j = 0; j < 8; j++) {
                 gpio_in[i][j] = qdev_get_gpio_in(gpio_dev[i], j);
                 gpio_out[i][j] = NULL;
@@ -1311,7 +1311,7 @@  static void stellaris_init(const char *kernel_filename, const char *cpu_model,
     }
 
     if (board->dc2 & (1 << 12)) {
-        dev = sysbus_create_simple("stellaris-i2c", 0x40020000, pic[8]);
+        dev = sysbus_create_simple("stellaris-i2c", 0x40020000, pic[8], NULL);
         i2c = (i2c_bus *)qdev_get_child_bus(dev, "i2c");
         if (board->peripherals & BP_OLED_I2C) {
             i2c_create_slave(i2c, "ssd0303", 0x3d);
@@ -1321,11 +1321,11 @@  static void stellaris_init(const char *kernel_filename, const char *cpu_model,
     for (i = 0; i < 4; i++) {
         if (board->dc2 & (1 << i)) {
             sysbus_create_simple("pl011_luminary", 0x4000c000 + i * 0x1000,
-                                 pic[uart_irq[i]]);
+                                 pic[uart_irq[i]], NULL);
         }
     }
     if (board->dc2 & (1 << 4)) {
-        dev = sysbus_create_simple("pl022", 0x40008000, pic[7]);
+        dev = sysbus_create_simple("pl022", 0x40008000, pic[7], NULL);
         if (board->peripherals & BP_OLED_SSI) {
             DeviceState *mux;
             void *bus;
diff --git a/hw/strongarm.c b/hw/strongarm.c
index 2d98893..a532d52 100644
--- a/hw/strongarm.c
+++ b/hw/strongarm.c
@@ -1563,7 +1563,8 @@  StrongARMState *sa1110_init(unsigned int sdram_size, const char *rev)
                     NULL);
 
     sysbus_create_simple("strongarm-rtc", 0x90010000,
-                    qdev_get_gpio_in(s->pic, SA_PIC_RTC_ALARM));
+                         qdev_get_gpio_in(s->pic, SA_PIC_RTC_ALARM),
+                         NULL);
 
     s->gpio = strongarm_gpio_init(0x90040000, s->pic);
 
diff --git a/hw/sun4m.c b/hw/sun4m.c
index ebf1dde..4e33228 100644
--- a/hw/sun4m.c
+++ b/hw/sun4m.c
@@ -938,7 +938,7 @@  static void sun4m_hw_init(const struct sun4m_hwdef *hwdef, ram_addr_t RAM_size,
 
     if (hwdef->cs_base) {
         sysbus_create_simple("SUNW,CS4231", hwdef->cs_base,
-                             slavio_irq[5]);
+                             slavio_irq[5], NULL);
     }
 
     if (hwdef->dbri_base) {
diff --git a/hw/syborg.c b/hw/syborg.c
index 5725f8a..9057578 100644
--- a/hw/syborg.c
+++ b/hw/syborg.c
@@ -55,12 +55,12 @@  static void syborg_init(ram_addr_t ram_size,
 
     cpu_pic = arm_pic_init_cpu(env);
     dev = sysbus_create_simple("syborg,interrupt", 0xC0000000,
-                               cpu_pic[ARM_PIC_CPU_IRQ]);
+                               cpu_pic[ARM_PIC_CPU_IRQ], NULL);
     for (i = 0; i < 64; i++) {
         pic[i] = qdev_get_gpio_in(dev, i);
     }
 
-    sysbus_create_simple("syborg,rtc", 0xC0001000, NULL);
+    sysbus_create_simple("syborg,rtc", 0xC0001000, NULL, NULL);
 
     dev = qdev_create(NULL, "syborg,timer", NULL);
     qdev_prop_set_uint32(dev, "frequency", 1000000);
@@ -68,13 +68,13 @@  static void syborg_init(ram_addr_t ram_size,
     sysbus_mmio_map(sysbus_from_qdev(dev), 0, 0xC0002000);
     sysbus_connect_irq(sysbus_from_qdev(dev), 0, pic[1]);
 
-    sysbus_create_simple("syborg,keyboard", 0xC0003000, pic[2]);
-    sysbus_create_simple("syborg,pointer", 0xC0004000, pic[3]);
-    sysbus_create_simple("syborg,framebuffer", 0xC0005000, pic[4]);
-    sysbus_create_simple("syborg,serial", 0xC0006000, pic[5]);
-    sysbus_create_simple("syborg,serial", 0xC0007000, pic[6]);
-    sysbus_create_simple("syborg,serial", 0xC0008000, pic[7]);
-    sysbus_create_simple("syborg,serial", 0xC0009000, pic[8]);
+    sysbus_create_simple("syborg,keyboard", 0xC0003000, pic[2], NULL);
+    sysbus_create_simple("syborg,pointer", 0xC0004000, pic[3], NULL);
+    sysbus_create_simple("syborg,framebuffer", 0xC0005000, pic[4], NULL);
+    sysbus_create_simple("syborg,serial", 0xC0006000, pic[5], NULL);
+    sysbus_create_simple("syborg,serial", 0xC0007000, pic[6], NULL);
+    sysbus_create_simple("syborg,serial", 0xC0008000, pic[7], NULL);
+    sysbus_create_simple("syborg,serial", 0xC0009000, pic[8], NULL);
 
     if (nd_table[0].vlan || nd_table[0].netdev) {
         DeviceState *dev;
diff --git a/hw/sysbus.h b/hw/sysbus.h
index 6c36537..536e667 100644
--- a/hw/sysbus.h
+++ b/hw/sysbus.h
@@ -73,8 +73,10 @@  DeviceState *sysbus_create_varargs(const char *name,
 DeviceState *sysbus_try_create_varargs(const char *name,
                                        target_phys_addr_t addr, ...);
 static inline DeviceState *sysbus_create_simple(const char *name,
-                                              target_phys_addr_t addr,
-                                              qemu_irq irq)
+                                                target_phys_addr_t addr,
+                                                qemu_irq irq,
+                                                const char *id,
+                                                ...)
 {
     return sysbus_create_varargs(name, addr, irq, NULL);
 }
diff --git a/hw/tosa.c b/hw/tosa.c
index 7b407f4..35b10ee 100644
--- a/hw/tosa.c
+++ b/hw/tosa.c
@@ -221,8 +221,8 @@  static void tosa_init(ram_addr_t ram_size,
     tmio = tc6393xb_init(0x10000000,
             qdev_get_gpio_in(cpu->gpio, TOSA_GPIO_TC6393XB_INT));
 
-    scp0 = sysbus_create_simple("scoop", 0x08800000, NULL);
-    scp1 = sysbus_create_simple("scoop", 0x14800040, NULL);
+    scp0 = sysbus_create_simple("scoop", 0x08800000, NULL, NULL);
+    scp1 = sysbus_create_simple("scoop", 0x14800040, NULL, NULL);
 
     tosa_gpio_setup(cpu, scp0, scp1, tmio);
 
diff --git a/hw/versatilepb.c b/hw/versatilepb.c
index b713aac..8df18ec 100644
--- a/hw/versatilepb.c
+++ b/hw/versatilepb.c
@@ -210,14 +210,14 @@  static void versatile_init(ram_addr_t ram_size,
     for (n = 0; n < 32; n++) {
         pic[n] = qdev_get_gpio_in(dev, n);
     }
-    dev = sysbus_create_simple("versatilepb_sic", 0x10003000, NULL);
+    dev = sysbus_create_simple("versatilepb_sic", 0x10003000, NULL, NULL);
     for (n = 0; n < 32; n++) {
         sysbus_connect_irq(sysbus_from_qdev(dev), n, pic[n]);
         sic[n] = qdev_get_gpio_in(dev, n);
     }
 
-    sysbus_create_simple("pl050_keyboard", 0x10006000, sic[3]);
-    sysbus_create_simple("pl050_mouse", 0x10007000, sic[4]);
+    sysbus_create_simple("pl050_keyboard", 0x10006000, sic[3], NULL);
+    sysbus_create_simple("pl050_mouse", 0x10007000, sic[4], NULL);
 
     dev = sysbus_create_varargs("versatile_pci", 0x40000000,
                                 sic[27], sic[28], sic[29], sic[30], NULL);
@@ -244,18 +244,18 @@  static void versatile_init(ram_addr_t ram_size,
         n--;
     }
 
-    sysbus_create_simple("pl011", 0x101f1000, pic[12]);
-    sysbus_create_simple("pl011", 0x101f2000, pic[13]);
-    sysbus_create_simple("pl011", 0x101f3000, pic[14]);
-    sysbus_create_simple("pl011", 0x10009000, sic[6]);
+    sysbus_create_simple("pl011", 0x101f1000, pic[12], NULL);
+    sysbus_create_simple("pl011", 0x101f2000, pic[13], NULL);
+    sysbus_create_simple("pl011", 0x101f3000, pic[14], NULL);
+    sysbus_create_simple("pl011", 0x10009000, sic[6], NULL);
 
-    sysbus_create_simple("pl080", 0x10130000, pic[17]);
-    sysbus_create_simple("sp804", 0x101e2000, pic[4]);
-    sysbus_create_simple("sp804", 0x101e3000, pic[5]);
+    sysbus_create_simple("pl080", 0x10130000, pic[17], NULL);
+    sysbus_create_simple("sp804", 0x101e2000, pic[4], NULL);
+    sysbus_create_simple("sp804", 0x101e3000, pic[5], NULL);
 
     /* The versatile/PB actually has a modified Color LCD controller
        that includes hardware cursor support from the PL111.  */
-    dev = sysbus_create_simple("pl110_versatile", 0x10120000, pic[16]);
+    dev = sysbus_create_simple("pl110_versatile", 0x10120000, pic[16], NULL);
     /* Wire up the mux control signals from the SYS_CLCD register */
     qdev_connect_gpio_out(sysctl, 0, qdev_get_gpio_in(dev, 0));
 
@@ -263,7 +263,7 @@  static void versatile_init(ram_addr_t ram_size,
     sysbus_create_varargs("pl181", 0x1000b000, sic[23], sic[2], NULL);
 
     /* Add PL031 Real Time Clock. */
-    sysbus_create_simple("pl031", 0x101e8000, pic[10]);
+    sysbus_create_simple("pl031", 0x101e8000, pic[10], NULL);
 
     /* Memory map for Versatile/PB:  */
     /* 0x10000000 System registers.  */
diff --git a/hw/vexpress.c b/hw/vexpress.c
index 191a5a2..47265da 100644
--- a/hw/vexpress.c
+++ b/hw/vexpress.c
@@ -126,22 +126,22 @@  static void vexpress_a9_init(ram_addr_t ram_size,
     qdev_connect_gpio_out(dev, 1,
                           qdev_get_gpio_in(sysctl, ARM_SYSCTL_GPIO_MMC_CARDIN));
 
-    sysbus_create_simple("pl050_keyboard", 0x10006000, pic[12]);
-    sysbus_create_simple("pl050_mouse", 0x10007000, pic[13]);
+    sysbus_create_simple("pl050_keyboard", 0x10006000, pic[12], NULL);
+    sysbus_create_simple("pl050_mouse", 0x10007000, pic[13], NULL);
 
-    sysbus_create_simple("pl011", 0x10009000, pic[5]);
-    sysbus_create_simple("pl011", 0x1000a000, pic[6]);
-    sysbus_create_simple("pl011", 0x1000b000, pic[7]);
-    sysbus_create_simple("pl011", 0x1000c000, pic[8]);
+    sysbus_create_simple("pl011", 0x10009000, pic[5], NULL);
+    sysbus_create_simple("pl011", 0x1000a000, pic[6], NULL);
+    sysbus_create_simple("pl011", 0x1000b000, pic[7], NULL);
+    sysbus_create_simple("pl011", 0x1000c000, pic[8], NULL);
 
     /* 0x1000f000 SP805 WDT */
 
-    sysbus_create_simple("sp804", 0x10011000, pic[2]);
-    sysbus_create_simple("sp804", 0x10012000, pic[3]);
+    sysbus_create_simple("sp804", 0x10011000, pic[2], NULL);
+    sysbus_create_simple("sp804", 0x10012000, pic[3], NULL);
 
     /* 0x10016000 Serial Bus DVI */
 
-    sysbus_create_simple("pl031", 0x10017000, pic[4]); /* RTC */
+    sysbus_create_simple("pl031", 0x10017000, pic[4], NULL); /* RTC */
 
     /* 0x1001a000 Compact Flash */
 
@@ -150,14 +150,14 @@  static void vexpress_a9_init(ram_addr_t ram_size,
     /* Daughterboard peripherals : 0x10020000 .. 0x20000000 */
 
     /* 0x10020000 PL111 CLCD (daughterboard) */
-    sysbus_create_simple("pl111", 0x10020000, pic[44]);
+    sysbus_create_simple("pl111", 0x10020000, pic[44], NULL);
 
     /* 0x10060000 AXI RAM */
     /* 0x100e0000 PL341 Dynamic Memory Controller */
     /* 0x100e1000 PL354 Static Memory Controller */
     /* 0x100e2000 System Configuration Controller */
 
-    sysbus_create_simple("sp804", 0x100e4000, pic[48]);
+    sysbus_create_simple("sp804", 0x100e4000, pic[48], NULL);
     /* 0x100e5000 SP805 Watchdog module */
     /* 0x100e6000 BP147 TrustZone Protection Controller */
     /* 0x100e9000 PL301 'Fast' AXI matrix */