qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Peter Maydell <peter.maydell@linaro.org>
To: qemu-devel@nongnu.org
Cc: "Paul Brook" <paul@codesourcery.com>,
	"Anthony Liguori" <anthony@codemonkey.ws>,
	"Andreas Färber" <afaerber@suse.de>
Subject: [Qemu-devel] [PATCH 12/14] target-arm: Drop cpu_reset_model_id()
Date: Fri, 30 Mar 2012 13:51:48 +0100	[thread overview]
Message-ID: <1333111910-3641-13-git-send-email-peter.maydell@linaro.org> (raw)
In-Reply-To: <1333111910-3641-1-git-send-email-peter.maydell@linaro.org>

cpu_reset_model_id() is now empty and we can remove it.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
 target-arm/helper.c |   59 +--------------------------------------------------
 1 files changed, 1 insertions(+), 58 deletions(-)

diff --git a/target-arm/helper.c b/target-arm/helper.c
index 5c4cfee..f48108e 100644
--- a/target-arm/helper.c
+++ b/target-arm/helper.c
@@ -8,66 +8,12 @@
 #include "sysemu.h"
 #include "cpu-qom.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,
  *      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);
 
@@ -76,11 +22,8 @@ void cpu_state_reset(CPUARMState *env)
         log_cpu_state(env, 0);
     }
 
-    id = env->cp15.c0_cpuid;
     tmp = env->cp15.c15_config_base_address;
     memset(env, 0, offsetof(CPUARMState, breakpoints));
-    if (id)
-        cpu_reset_model_id(env, id);
     env->cp15.c15_config_base_address = tmp;
     env->cp15.c0_cpuid = cpu->midr;
     env->vfp.xregs[ARM_VFP_FPSID] = cpu->reset_fpsid;
@@ -145,7 +88,7 @@ void cpu_state_reset(CPUARMState *env)
     /* v7 performance monitor control register: same implementor
      * field as main ID register, and we implement no event counters.
      */
-    env->cp15.c9_pmcr = (id & 0xff000000);
+    env->cp15.c9_pmcr = (cpu->midr & 0xff000000);
 #endif
     set_flush_to_zero(1, &env->vfp.standard_fp_status);
     set_flush_inputs_to_zero(1, &env->vfp.standard_fp_status);
-- 
1.7.1

  parent reply	other threads:[~2012-03-30 12:52 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-30 12:51 [Qemu-devel] [PATCH 00/14] target-arm: Create QOM subclass per CPU implementation Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 01/14] target-arm: Add QOM subclasses for each ARM cpu implementation Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 02/14] target-arm: Move feature bit settings to CPU init fns Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 03/14] target-arm: Move FPSID config to cpu " Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 04/14] target-arm: Move MVFR* setup to per " Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 05/14] target-arm: Move CTR " Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 06/14] target-arm: Move SCTLR reset value " Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 07/14] target-arm: Drop JTAG_ID documentation Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 08/14] target-arm: Move iWMMXT wCID reset to cpu_state_reset Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 09/14] target-arm: Move feature register setup to per-CPU init fns Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 10/14] target-arm: Move OMAP cp15_i_{max, min} reset to cpu_state_reset Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 11/14] target-arm: Move cache ID register setup to cpu specific init fns Peter Maydell
2012-03-30 12:51 ` Peter Maydell [this message]
2012-03-30 12:51 ` [Qemu-devel] [PATCH 13/14] target-arm: Move reset handling to arm_cpu_reset Peter Maydell
2012-03-30 12:51 ` [Qemu-devel] [PATCH 14/14] target-arm: Move A9 config_base_address reset value to ARMCPU Peter Maydell
2012-03-30 17:01   ` Mark Langsdorf
2012-03-30 17:04     ` Peter Maydell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1333111910-3641-13-git-send-email-peter.maydell@linaro.org \
    --to=peter.maydell@linaro.org \
    --cc=afaerber@suse.de \
    --cc=anthony@codemonkey.ws \
    --cc=paul@codesourcery.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).