Il 05/04/2013 06:28, liguang ha scritto:
> Signed-off-by: liguang <[email protected]>
> ---
> vl.c | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/vl.c b/vl.c
> index aeed7f4..a14549e 100644
> --- a/vl.c
> +++ b/vl.c
> @@ -171,6 +171,8 @@ int main(int argc, char **argv)
> #include "ui/qemu-spice.h"
> #include "qapi/string-input-visitor.h"
>
> +#include "hw/power.h"
> +
> //#define DEBUG_NET
> //#define DEBUG_SLIRP
>
> @@ -4295,6 +4297,8 @@ int main(int argc, char **argv, char **envp)
>
> qdev_machine_init();
>
> + qdev_init_nofail(qdev_create(NULL, TYPE_POWER_CHIP));
> +
You cannot just add a random device to the machine.
Perhaps what you want to do is define a QOM interface that some device
in the machine will implement.
But right now this all seems very nebulous. Honestly, I read the
patches and I have no idea _why_ you are doing this.
Paolo
> QEMUMachineInitArgs args = { .ram_size = ram_size,
> .boot_device = (boot_devices[0] == '\0') ?
> machine->boot_order :
>