From patchwork Thu Feb 20 11:17:14 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 25011 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ig0-f198.google.com (mail-ig0-f198.google.com [209.85.213.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 15B47203BE for ; Thu, 20 Feb 2014 11:21:02 +0000 (UTC) Received: by mail-ig0-f198.google.com with SMTP id h3sf1578208igd.1 for ; Thu, 20 Feb 2014 03:21:02 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:date :message-id:in-reply-to:references:cc:subject:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list; bh=oxwtC8w8A3buvyaRi0ONFsUmeguCdYX07bVQjX5rk/0=; b=l1tQhCepQMpU053ra/EJQdzI3gMwW19iMeYlqi8pVNl9AVUqRis4273E9pc9lkvkAj GVDQ1K609NH1844L4Q8AjIG/Ap0MT+vgiplHTh+ANw6AZDX+nDOWBIF7223FOhcAg4A6 9IdpySeOHhG7RbkFpyg/d9PF+jFVbqzZiirVmf7ybWd5uExc9/eMJFfT2z0rl1kIlsIH K0D0BCfSfGmbu+5C++ZJ0LNeCkzPMWgS3odLLw07t5DfekA5vem7lKXiPvzhG+hfyiA1 brAvNRd6zKdShO98XHldeblQ//w5z3iDk2mZ3nArCFJ9nF41r+lzc5jh2BexivWYYIRU iKKw== X-Gm-Message-State: ALoCoQmSagsTGRhIIxbC6+0SpNfkklrHclO5gdtFZcDLFkln8yfah7gWC8kY3Pj8sXNTo38GHkXE X-Received: by 10.43.158.9 with SMTP id ls9mr471256icc.18.1392895262219; Thu, 20 Feb 2014 03:21:02 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.88.203 with SMTP id t69ls497631qgd.87.gmail; Thu, 20 Feb 2014 03:21:02 -0800 (PST) X-Received: by 10.220.164.80 with SMTP id d16mr653500vcy.15.1392895262084; Thu, 20 Feb 2014 03:21:02 -0800 (PST) Received: from mail-vc0-f181.google.com (mail-vc0-f181.google.com [209.85.220.181]) by mx.google.com with ESMTPS id eo4si1331805vdb.43.2014.02.20.03.21.02 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 20 Feb 2014 03:21:02 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.181 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.181; Received: by mail-vc0-f181.google.com with SMTP id ie18so1670793vcb.40 for ; Thu, 20 Feb 2014 03:21:02 -0800 (PST) X-Received: by 10.220.192.71 with SMTP id dp7mr646049vcb.45.1392895262015; Thu, 20 Feb 2014 03:21:02 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.174.196 with SMTP id u4csp50263vcz; Thu, 20 Feb 2014 03:21:01 -0800 (PST) X-Received: by 10.236.83.66 with SMTP id p42mr2163637yhe.90.1392895261227; Thu, 20 Feb 2014 03:21:01 -0800 (PST) Received: from lists.gnu.org (lists.gnu.org. [208.118.235.17]) by mx.google.com with ESMTPS id t49si3905901yhd.9.2014.02.20.03.21.00 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Thu, 20 Feb 2014 03:21:01 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; Received: from localhost ([::1]:37551 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WGRga-0006St-Fg for patch@linaro.org; Thu, 20 Feb 2014 06:21:00 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58487) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WGRdR-0001zK-GS for qemu-devel@nongnu.org; Thu, 20 Feb 2014 06:17:46 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WGRdP-0004jJ-6E for qemu-devel@nongnu.org; Thu, 20 Feb 2014 06:17:45 -0500 Received: from mnementh.archaic.org.uk ([2001:8b0:1d0::1]:46019) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WGRdO-0004gz-Ua for qemu-devel@nongnu.org; Thu, 20 Feb 2014 06:17:43 -0500 Received: from pm215 by mnementh.archaic.org.uk with local (Exim 4.80) (envelope-from ) id 1WGRdH-0003SX-0p; Thu, 20 Feb 2014 11:17:35 +0000 From: Peter Maydell To: Anthony Liguori Date: Thu, 20 Feb 2014 11:17:14 +0000 Message-Id: <1392895054-13232-11-git-send-email-peter.maydell@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1392895054-13232-1-git-send-email-peter.maydell@linaro.org> References: <1392895054-13232-1-git-send-email-peter.maydell@linaro.org> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:8b0:1d0::1 Cc: Blue Swirl , qemu-devel@nongnu.org, Aurelien Jarno Subject: [Qemu-devel] [PULL 10/30] target-arm/kvm-consts.h: Define QEMU constants for known KVM CPUs 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: peter.maydell@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.181 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 Extend the set of CPUs for which we provide a QEMU_KVM_ARM_TARGET_* constant to include all the ones currently supported by the kernel headers we are using. Signed-off-by: Peter Maydell --- target-arm/kvm-consts.h | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/target-arm/kvm-consts.h b/target-arm/kvm-consts.h index 0e7f889..6009a33 100644 --- a/target-arm/kvm-consts.h +++ b/target-arm/kvm-consts.h @@ -50,15 +50,29 @@ MISMATCH_CHECK(PSCI_FN_CPU_OFF, KVM_PSCI_FN_CPU_OFF) MISMATCH_CHECK(PSCI_FN_CPU_ON, KVM_PSCI_FN_CPU_ON) MISMATCH_CHECK(PSCI_FN_MIGRATE, KVM_PSCI_FN_MIGRATE) +/* Note that KVM uses overlapping values for AArch32 and AArch64 + * target CPU numbers. AArch32 targets: + */ #define QEMU_KVM_ARM_TARGET_CORTEX_A15 0 +#define QEMU_KVM_ARM_TARGET_CORTEX_A7 1 + +/* AArch64 targets: */ +#define QEMU_KVM_ARM_TARGET_AEM_V8 0 +#define QEMU_KVM_ARM_TARGET_FOUNDATION_V8 1 +#define QEMU_KVM_ARM_TARGET_CORTEX_A57 2 /* There's no kernel define for this: sentinel value which * matches no KVM target value for either 64 or 32 bit */ #define QEMU_KVM_ARM_TARGET_NONE UINT_MAX -#ifndef TARGET_AARCH64 +#ifdef TARGET_AARCH64 +MISMATCH_CHECK(QEMU_KVM_ARM_TARGET_AEM_V8, KVM_ARM_TARGET_AEM_V8) +MISMATCH_CHECK(QEMU_KVM_ARM_TARGET_FOUNDATION_V8, KVM_ARM_TARGET_FOUNDATION_V8) +MISMATCH_CHECK(QEMU_KVM_ARM_TARGET_CORTEX_A57, KVM_ARM_TARGET_CORTEX_A57) +#else MISMATCH_CHECK(QEMU_KVM_ARM_TARGET_CORTEX_A15, KVM_ARM_TARGET_CORTEX_A15) +MISMATCH_CHECK(QEMU_KVM_ARM_TARGET_CORTEX_A7, KVM_ARM_TARGET_CORTEX_A7) #endif #define CP_REG_ARM64 0x6000000000000000ULL