qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v2 12/14] target-arm: Drop cpu_reset_model_id()


From: Andreas Färber
Subject: Re: [Qemu-devel] [PATCH v2 12/14] target-arm: Drop cpu_reset_model_id()
Date: Fri, 20 Apr 2012 18:14:27 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120312 Thunderbird/11.0

Am 14.04.2012 18:42, schrieb Peter Maydell:
> cpu_reset_model_id() is now empty and we can remove it.
> 
> Signed-off-by: Peter Maydell <address@hidden>

Acked-by: Andreas Färber <address@hidden>

However, ...

> diff --git a/target-arm/helper.c b/target-arm/helper.c
> index 5cbc7e0..653885a 100644
> --- a/target-arm/helper.c
> +++ b/target-arm/helper.c
> @@ -7,66 +7,12 @@
>  #endif
>  #include "sysemu.h"
>  
> -static void cpu_reset_model_id(CPUARMState *env, uint32_t id)
> -{
> -    switch (id) {
> -    case ARM_CPUID_ARM926:
> -        break;
> -    case ARM_CPUID_ARM946:
> -        break;
> -    case ARM_CPUID_ARM1026:
> -        break;
> -    case ARM_CPUID_ARM1136:
> -        /* This is the 1136 r1, which is a v6K core */
> -    case ARM_CPUID_ARM1136_R2:
> -        break;
> -    case ARM_CPUID_ARM1176:
> -        break;
> -    case ARM_CPUID_ARM11MPCORE:
> -        break;
> -    case ARM_CPUID_CORTEXA8:
> -        break;
> -    case ARM_CPUID_CORTEXA9:
> -        break;
> -    case ARM_CPUID_CORTEXA15:
> -        break;
> -    case ARM_CPUID_CORTEXM3:
> -        break;
> -    case ARM_CPUID_ANY: /* For userspace emulation.  */
> -        break;
> -    case ARM_CPUID_TI915T:
> -    case ARM_CPUID_TI925T:
> -        break;
> -    case ARM_CPUID_PXA250:
> -    case ARM_CPUID_PXA255:
> -    case ARM_CPUID_PXA260:
> -    case ARM_CPUID_PXA261:
> -    case ARM_CPUID_PXA262:
> -        break;
> -    case ARM_CPUID_PXA270_A0:
> -    case ARM_CPUID_PXA270_A1:
> -    case ARM_CPUID_PXA270_B0:
> -    case ARM_CPUID_PXA270_B1:
> -    case ARM_CPUID_PXA270_C0:
> -    case ARM_CPUID_PXA270_C5:
> -        break;
> -    case ARM_CPUID_SA1100:
> -    case ARM_CPUID_SA1110:
> -        break;
> -    default:
> -        cpu_abort(env, "Bad CPU ID: %x\n", id);
> -        break;
> -    }
> -
> -}
> -
>  /* TODO Move contents into arm_cpu_reset() in cpu.c,
>   *      once cpu_reset_model_id() is eliminated,

...if you were to drop this comment line it would be cleaner. There is
no cpu_reset_model_id() any more.

Also, can't some CPUID defines already be dropped in this patch, now
that the switch is gone?

Andreas

>   *      and then forward to cpu_reset() here.
>   */
>  void cpu_state_reset(CPUARMState *env)
>  {
> -    uint32_t id;
>      uint32_t tmp = 0;
>      ARMCPU *cpu = arm_env_get_cpu(env);
>  
[snip]

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg



reply via email to

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