From patchwork Thu Nov 10 10:31:57 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Andreas_F=C3=A4rber?= X-Patchwork-Id: 124841 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [140.186.70.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 2A49CB6F69 for ; Thu, 10 Nov 2011 21:32:26 +1100 (EST) Received: from localhost ([::1]:50666 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RORvj-0005RV-Id for incoming@patchwork.ozlabs.org; Thu, 10 Nov 2011 05:32:23 -0500 Received: from eggs.gnu.org ([140.186.70.92]:33204) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RORva-0005RA-Ed for qemu-devel@nongnu.org; Thu, 10 Nov 2011 05:32:15 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RORvZ-0007kZ-0w for qemu-devel@nongnu.org; Thu, 10 Nov 2011 05:32:14 -0500 Received: from fmmailgate04.web.de ([217.72.192.242]:40452) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RORvY-0007kF-M6 for qemu-devel@nongnu.org; Thu, 10 Nov 2011 05:32:12 -0500 Received: from moweb002.kundenserver.de (moweb002.kundenserver.de [172.19.20.108]) by fmmailgate04.web.de (Postfix) with ESMTP id 8B22B6EEB499 for ; Thu, 10 Nov 2011 11:32:11 +0100 (CET) Received: from localhost.localdomain ([2.39.114.236]) by smtp.web.de (mrweb001) with ESMTPA (Nemesis) id 0LlWVj-1QpOgv3G1X-00bGaF; Thu, 10 Nov 2011 11:32:11 +0100 From: =?UTF-8?q?Andreas=20F=C3=A4rber?= To: qemu-devel@nongnu.org Date: Thu, 10 Nov 2011 11:31:57 +0100 Message-Id: <1320921120-11574-3-git-send-email-andreas.faerber@web.de> X-Mailer: git-send-email 1.7.7 In-Reply-To: <1320921120-11574-1-git-send-email-andreas.faerber@web.de> References: <1319281250-27114-1-git-send-email-andreas.faerber@web.de> <1320921120-11574-1-git-send-email-andreas.faerber@web.de> MIME-Version: 1.0 X-Provags-ID: V02:K0:iq1Xy1rSPg4vEOTEnXhHFtKo4sk8fvfsm18WCCg8NlT 5yJQMqzliRk1MqWpAUrrwp3vCz0mlmemVJZGqx+d4xGZSGlxiV Afpukvwg5ELe8MNfPniqqSrc8n22c8jbmdP6HH/e5V7XYnSOHI kXN5/S6JrHb0z+bUhiPe6mVhk/0TUuIrCDtMk0NdDeknPmb/Hz AjAOhEMewOXJI//gKoQEw== X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4-2.6 X-Received-From: 217.72.192.242 Cc: Peter Maydell , =?UTF-8?q?Andreas=20F=C3=A4rber?= Subject: [Qemu-devel] [RFC 2/5] target-arm: Infer ARMv5 feature X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org ARMv6 => ARMv5 Cc: Peter Maydell Signed-off-by: Andreas Färber --- target-arm/helper.c | 10 +++------- 1 files changed, 3 insertions(+), 7 deletions(-) diff --git a/target-arm/helper.c b/target-arm/helper.c index 0d7635b..bd6173d 100644 --- a/target-arm/helper.c +++ b/target-arm/helper.c @@ -81,7 +81,6 @@ static void cpu_reset_model_id(CPUARMState *env) * older core than plain "arm1136". In particular this does not * have the v6K features. */ - set_feature(env, ARM_FEATURE_V5); set_feature(env, ARM_FEATURE_V6); set_feature(env, ARM_FEATURE_VFP); set_feature(env, ARM_FEATURE_AUXCR); @@ -98,7 +97,6 @@ static void cpu_reset_model_id(CPUARMState *env) env->cp15.c1_sys = 0x00050078; break; case ARM_CPUID_ARM1176: - set_feature(env, ARM_FEATURE_V5); set_feature(env, ARM_FEATURE_V6); set_feature(env, ARM_FEATURE_V6K); set_feature(env, ARM_FEATURE_VFP); @@ -113,7 +111,6 @@ static void cpu_reset_model_id(CPUARMState *env) env->cp15.c1_sys = 0x00050078; break; case ARM_CPUID_ARM11MPCORE: - set_feature(env, ARM_FEATURE_V5); set_feature(env, ARM_FEATURE_V6); set_feature(env, ARM_FEATURE_V6K); set_feature(env, ARM_FEATURE_VFP); @@ -127,7 +124,6 @@ static void cpu_reset_model_id(CPUARMState *env) env->cp15.c0_cachetype = 0x1dd20d2; break; case ARM_CPUID_CORTEXA8: - set_feature(env, ARM_FEATURE_V5); set_feature(env, ARM_FEATURE_V6); set_feature(env, ARM_FEATURE_V6K); set_feature(env, ARM_FEATURE_V7); @@ -150,7 +146,6 @@ static void cpu_reset_model_id(CPUARMState *env) env->cp15.c1_sys = 0x00c50078; break; case ARM_CPUID_CORTEXA9: - set_feature(env, ARM_FEATURE_V5); set_feature(env, ARM_FEATURE_V6); set_feature(env, ARM_FEATURE_V6K); set_feature(env, ARM_FEATURE_V7); @@ -178,7 +173,6 @@ static void cpu_reset_model_id(CPUARMState *env) env->cp15.c1_sys = 0x00c50078; break; case ARM_CPUID_CORTEXM3: - set_feature(env, ARM_FEATURE_V5); set_feature(env, ARM_FEATURE_V6); set_feature(env, ARM_FEATURE_THUMB2); set_feature(env, ARM_FEATURE_V7); @@ -186,7 +180,6 @@ static void cpu_reset_model_id(CPUARMState *env) set_feature(env, ARM_FEATURE_THUMB_DIV); break; case ARM_CPUID_ANY: /* For userspace emulation. */ - set_feature(env, ARM_FEATURE_V5); set_feature(env, ARM_FEATURE_V6); set_feature(env, ARM_FEATURE_V6K); set_feature(env, ARM_FEATURE_V7); @@ -249,6 +242,9 @@ static void cpu_reset_model_id(CPUARMState *env) if (arm_feature(env, ARM_FEATURE_V7)) { set_feature(env, ARM_FEATURE_VAPA); } + if (arm_feature(env, ARM_FEATURE_V6)) { + set_feature(env, ARM_FEATURE_V5); + } if (arm_feature(env, ARM_FEATURE_V5)) { set_feature(env, ARM_FEATURE_V4T); }