upstream: PC board is updated
authorSeokYeon Hwang <syeon.hwang@samsung.com>
Tue, 25 Aug 2015 04:25:41 +0000 (13:25 +0900)
committerSeokYeon Hwang <syeon.hwang@samsung.com>
Tue, 25 Aug 2015 06:32:53 +0000 (15:32 +0900)
Change-Id: I46932542a3f57c80db52e3a89adc1e52093de6a4
Signed-off-by: SeokYeon Hwang <syeon.hwang@samsung.com>
hw/i386/pc_piix.c
tizen/src/hw/maru_board.c

index bd84766..61c4a24 100644 (file)
@@ -304,6 +304,15 @@ static void pc_init1(MachineState *machine)
     }
 }
 
+#ifdef CONFIG_MARU
+void maru_pc_init(MachineState *machine);
+
+void maru_pc_init(MachineState *machine)
+{
+    pc_init1(machine);
+}
+#endif
+
 static void pc_compat_2_3(MachineState *machine)
 {
     PCMachineState *pcms = PC_MACHINE(machine);
@@ -340,15 +349,6 @@ static void pc_compat_2_2(MachineState *machine)
     machine->suppress_vmdesc = true;
 }
 
-#ifdef CONFIG_MARU
-void maru_pc_init(MachineState *machine);
-
-void maru_pc_init(MachineState *machine)
-{
-    pc_init1(machine);
-}
-#endif
-
 static void pc_compat_2_1(MachineState *machine)
 {
     PCMachineState *pcms = PC_MACHINE(machine);
index a45d125..c00398b 100644 (file)
@@ -4,7 +4,6 @@
  * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
  *
  * Contact:
- * YeongKyoon Lee <yeongkyoon.lee@samsung.com>
  * SeokYeon Hwang <syeon.hwang@samsung.com>
  * SangJin Kim <sangjin3.kim@samsung.com>
  * KiTae Kim <kt920.kim@samsung.com>
@@ -50,32 +49,29 @@ static void maru_device_init(void)
     // do nothing for now...
 }
 
-extern void maru_pc_init_pci(MachineState *args);
-static void maru_x86_board_init(MachineState *args)
+extern void maru_pc_init(MachineState *args);
+static void maru_x86_board_init(MachineState *machine)
 {
-    maru_pc_init_pci(args);
+    maru_pc_init(machine);
 
     maru_device_init();
 }
 
-static QEMUMachine maru_x86_machine = {
-    PC_DEFAULT_MACHINE_OPTIONS,
-    .name = "maru-x86-machine",
-    .alias = "maru-x86-machine",
-    .desc = "Maru Board (x86)",
-    .init = maru_x86_board_init,
-    .hot_add_cpu = pc_hot_add_cpu,
-    .no_parallel = 1,
-    .no_floppy = 1,
-    .no_cdrom = 1,
-    .no_sdcard = 1,
-    .default_machine_opts = "firmware=bios-256k.bin",
-    .default_boot_order = "c",
-};
-
-static void maru_machine_init(void)
+static void maru_x86_machine_options(MachineClass *m)
 {
-    qemu_register_pc_machine(&maru_x86_machine);
+    pc_default_machine_options(m);
+    m->family = "pc_piix";
+    m->desc = "Maru Board (x86)";
+    m->hot_add_cpu = pc_hot_add_cpu;
+    m->default_machine_opts = "firmware=bios-256k.bin";
+    m->default_display = "std";
+    m->alias = "maru-x86-machine";
+    m->no_parallel = 1;
+    m->no_floppy = 1;
+    m->no_cdrom = 1;
+    m->no_sdcard = 1;
+    m->default_boot_order = "c";
 }
 
-machine_init(maru_machine_init);
+DEFINE_PC_MACHINE(maru, "maru-x86-machine", maru_x86_board_init,
+        maru_x86_machine_options);