qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Re: [PATCH 2/5] Fix booke registers init


From: Jan Kiszka
Subject: [Qemu-devel] Re: [PATCH 2/5] Fix booke registers init
Date: Sat, 25 Jul 2009 12:04:31 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); de; rv:1.8.1.12) Gecko/20080226 SUSE/2.0.0.12-1.1 Thunderbird/2.0.0.12 Mnenhy/0.7.5.666

Liu Yu wrote:
> Commit 8d2ba1fb9c8e7006e10d71fa51a020977f14c8b0
> introduces a new new reset order.
> 
> So that we have to synchronize registers explicitly.
> 
> Signed-off-by: Liu Yu <address@hidden>
> ---
>  hw/ppc440_bamboo.c     |    4 +++-
>  hw/ppce500_mpc8544ds.c |    4 +++-
>  2 files changed, 6 insertions(+), 2 deletions(-)
> 
> diff --git a/hw/ppc440_bamboo.c b/hw/ppc440_bamboo.c
> index d9ef3ec..f1ba130 100644
> --- a/hw/ppc440_bamboo.c
> +++ b/hw/ppc440_bamboo.c
> @@ -182,8 +182,10 @@ static void bamboo_init(ram_addr_t ram_size,
>          /* XXX we currently depend on KVM to create some initial TLB 
> entries. */
>      }
>  
> -    if (kvm_enabled())
> +    if (kvm_enabled()) {
> +        kvm_arch_put_registers(env);
>          kvmppc_init();
> +    }
>  }
>  
>  static QEMUMachine bamboo_machine = {
> diff --git a/hw/ppce500_mpc8544ds.c b/hw/ppce500_mpc8544ds.c
> index c0e367d..f1b3c1a 100644
> --- a/hw/ppce500_mpc8544ds.c
> +++ b/hw/ppce500_mpc8544ds.c
> @@ -276,8 +276,10 @@ static void mpc8544ds_init(ram_addr_t ram_size,
>          /* XXX we currently depend on KVM to create some initial TLB 
> entries. */
>      }
>  
> -    if (kvm_enabled())
> +    if (kvm_enabled()) {
> +        kvm_arch_put_registers(env);
>          kvmppc_init();
> +    }
>  
>      return;
>  }

These are required when loading a device tree and, thus, changing some
registers after cpu_init, right? Then please add
cpu_synchronize_state(env, 1) to the corresponding code blocks instead
of this explicit, kvm-specific loading.

Jan

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]