From patchwork Mon Jun 1 10:34:20 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shannon Zhao X-Patchwork-Id: 49287 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f71.google.com (mail-wg0-f71.google.com [74.125.82.71]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id CC67321580 for ; Mon, 1 Jun 2015 10:35:22 +0000 (UTC) Received: by wgez8 with SMTP id z8sf32261441wge.2 for ; Mon, 01 Jun 2015 03:35:22 -0700 (PDT) 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=3cgAPJ8KSS+QVsQCBsN9/4hPytkOFe6hzWQw8DAj+3M=; b=I7WcMo6EQKT+AuvtOLCX50LkZln+oxF5SXkaGyt4gVwGR4bSFc2ggR7dKdtVb2WYIy Z+SwFUBuBnMHDriZljSkXgSzY++iiZjzCZNMchQ8djy7WqcB7vXovJzMwNYim10yH+Df ht+SBmim8wTaHpXjmvAmsLaRMcI6qvv93y35d07vqd/imwpV0gguEMP0xyjaz2JpJk4y tjIZ+74Y6bdPxlrpG1viNykiskwWRaVKz5Xpj5tQkUDYYADAIvBANn2BKmLCFNstiTPL kXEzGsUlssaNvUf2RwSrkVgm6lWMXxp9hGKEnGZIvgDObYa9/0z6VKE8o5LQ9Lvm43+k 3hkg== X-Gm-Message-State: ALoCoQki6YmkvlLiXUT4buB51fn+/hAXZVYGDVKSMR32EA5Eh/k0LugTk31sV76t+yc6BeSaTc4C X-Received: by 10.112.144.4 with SMTP id si4mr13625916lbb.17.1433154922120; Mon, 01 Jun 2015 03:35:22 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.6.74 with SMTP id y10ls190493lay.41.gmail; Mon, 01 Jun 2015 03:35:21 -0700 (PDT) X-Received: by 10.152.45.98 with SMTP id l2mr20791614lam.77.1433154921965; Mon, 01 Jun 2015 03:35:21 -0700 (PDT) Received: from mail-lb0-f179.google.com (mail-lb0-f179.google.com. [209.85.217.179]) by mx.google.com with ESMTPS id ws3si4493249lbb.70.2015.06.01.03.35.21 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 01 Jun 2015 03:35:21 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.179 as permitted sender) client-ip=209.85.217.179; Received: by lbcue7 with SMTP id ue7so81443492lbc.0 for ; Mon, 01 Jun 2015 03:35:21 -0700 (PDT) X-Received: by 10.112.222.133 with SMTP id qm5mr20446488lbc.86.1433154921734; Mon, 01 Jun 2015 03:35:21 -0700 (PDT) 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.112.108.230 with SMTP id hn6csp2212804lbb; Mon, 1 Jun 2015 03:35:20 -0700 (PDT) X-Received: by 10.55.24.149 with SMTP id 21mr13181970qky.97.1433154920266; Mon, 01 Jun 2015 03:35:20 -0700 (PDT) Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id r7si12728500qcq.2.2015.06.01.03.35.19 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Mon, 01 Jun 2015 03:35:20 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Received: from localhost ([::1]:51194 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YzN3v-0003ZL-Dl for patch@linaro.org; Mon, 01 Jun 2015 06:35:19 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57923) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YzN3F-0002ps-G5 for qemu-devel@nongnu.org; Mon, 01 Jun 2015 06:34:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YzN3B-00087R-Ec for qemu-devel@nongnu.org; Mon, 01 Jun 2015 06:34:37 -0400 Received: from mail-pa0-f54.google.com ([209.85.220.54]:33178) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YzN3B-00087N-AF for qemu-devel@nongnu.org; Mon, 01 Jun 2015 06:34:33 -0400 Received: by padj3 with SMTP id j3so40661918pad.0 for ; Mon, 01 Jun 2015 03:34:32 -0700 (PDT) X-Received: by 10.66.222.72 with SMTP id qk8mr39248742pac.7.1433154872479; Mon, 01 Jun 2015 03:34:32 -0700 (PDT) Received: from localhost ([167.160.116.150]) by mx.google.com with ESMTPSA id as1sm13769782pbc.39.2015.06.01.03.34.30 (version=TLSv1 cipher=RC4-SHA bits=128/128); Mon, 01 Jun 2015 03:34:31 -0700 (PDT) From: shannon.zhao@linaro.org To: qemu-devel@nongnu.org, peter.maydell@linaro.org Date: Mon, 1 Jun 2015 18:34:20 +0800 Message-Id: <1433154861-4116-2-git-send-email-shannon.zhao@linaro.org> X-Mailer: git-send-email 1.9.5.msysgit.1 In-Reply-To: <1433154861-4116-1-git-send-email-shannon.zhao@linaro.org> References: <1433154861-4116-1-git-send-email-shannon.zhao@linaro.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.85.220.54 Cc: shannon.zhao@linaro.org, zhaoshenglong@huawei.com Subject: [Qemu-devel] [PATCH 1/2] target-arm/kvm64: Add cortex-a53 cpu support 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: shannon.zhao@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.179 as permitted sender) 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 From: Shannon Zhao Signed-off-by: Shannon Zhao Signed-off-by: Shannon Zhao --- target-arm/cpu64.c | 1 + target-arm/kvm-consts.h | 2 ++ target-arm/kvm64.c | 1 + 3 files changed, 4 insertions(+) diff --git a/target-arm/cpu64.c b/target-arm/cpu64.c index bf7dd68..dd6f9d8 100644 --- a/target-arm/cpu64.c +++ b/target-arm/cpu64.c @@ -159,6 +159,7 @@ static void aarch64_a53_initfn(Object *obj) set_feature(&cpu->env, ARM_FEATURE_V8_SHA256); set_feature(&cpu->env, ARM_FEATURE_V8_PMULL); set_feature(&cpu->env, ARM_FEATURE_CRC); + cpu->kvm_target = QEMU_KVM_ARM_TARGET_CORTEX_A53; cpu->midr = 0x410fd034; cpu->reset_fpsid = 0x41034070; cpu->mvfr0 = 0x10110222; diff --git a/target-arm/kvm-consts.h b/target-arm/kvm-consts.h index aea12f1..4c10476 100644 --- a/target-arm/kvm-consts.h +++ b/target-arm/kvm-consts.h @@ -127,6 +127,7 @@ MISMATCH_CHECK(QEMU_PSCI_RET_DISABLED, PSCI_RET_DISABLED) #define QEMU_KVM_ARM_TARGET_AEM_V8 0 #define QEMU_KVM_ARM_TARGET_FOUNDATION_V8 1 #define QEMU_KVM_ARM_TARGET_CORTEX_A57 2 +#define QEMU_KVM_ARM_TARGET_CORTEX_A53 4 /* There's no kernel define for this: sentinel value which * matches no KVM target value for either 64 or 32 bit @@ -137,6 +138,7 @@ MISMATCH_CHECK(QEMU_PSCI_RET_DISABLED, PSCI_RET_DISABLED) 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) +MISMATCH_CHECK(QEMU_KVM_ARM_TARGET_CORTEX_A53, KVM_ARM_TARGET_CORTEX_A53) #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) diff --git a/target-arm/kvm64.c b/target-arm/kvm64.c index 93c1ca8..0f1cd29 100644 --- a/target-arm/kvm64.c +++ b/target-arm/kvm64.c @@ -50,6 +50,7 @@ bool kvm_arm_get_host_cpu_features(ARMHostCPUClass *ahcc) KVM_ARM_TARGET_AEM_V8, KVM_ARM_TARGET_FOUNDATION_V8, KVM_ARM_TARGET_CORTEX_A57, + KVM_ARM_TARGET_CORTEX_A53 = 4, QEMU_KVM_ARM_TARGET_NONE }; struct kvm_vcpu_init init;