From patchwork Sun Apr 23 17:09:06 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoffer Dall X-Patchwork-Id: 9695155 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id F1502601E9 for ; Sun, 23 Apr 2017 17:32:12 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EDBA1209D8 for ; Sun, 23 Apr 2017 17:32:12 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E1021262F2; Sun, 23 Apr 2017 17:32:12 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 86BC4209D8 for ; Sun, 23 Apr 2017 17:32:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=+Cl4PENhgxefVpNJP2iQFrVr5Hl8dL0TeRp7k0lfiJ0=; b=Evk3+FmMKfbVLHFctt//6nYz02 4HKHCKwv/Q+tJayycDwZ063neXVX6MwSHW88ED5awfUcics+vm5qvXbOQOLb/7MPhTzZJqBd3kPxk /eiZYLI2q+lNdGAvP5MnniwYiD5VfIcJzYU0E/uFSLilN4jSZj4bJseBEnBgVMhG84YB/oDsr1VYu y0ccGz453/1myosMOUsvD6qJ75b0sVSxDSolLUB0OFxL3F+t52ChLDEwj2AWLSUFfrSsXr9cffWDe 3ewn05bcsXxGkRvnHlJaPIWcxbds8tcl1aO8btr6CkC0cgpMAwFG7iTz+KLG5Ig+VdXozw0AflDgr HSrYoDKw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1d2LMp-0003ww-IQ; Sun, 23 Apr 2017 17:32:11 +0000 Received: from merlin.infradead.org ([2001:4978:20e::2]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1d2LLu-0002ZO-Kr for linux-arm-kernel@bombadil.infradead.org; Sun, 23 Apr 2017 17:31:14 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=M3METMFXZcq4Hcd4bFSaUwf9qopGkDRhezYrzAhISGE=; b=AtA4i9wYQoWxSf6JMfqkmqWTY q24tBfXLG9sPtinIFKjtPbQPuyMZm6tHGKzthhEK8vA6XkD32gzLAnOMNeDmg/2PWhGhWz54i92oK 7ZnDnJBNalFnPKsdGKul6qXMEtD5I90XORvhEUm8cOBYp8VriG31VrDYzHFVF2YxAZeCuGNopPZxZ I/+s3TLzoCax1wOpvfoOXfXfYWuV1rZNOXDat44pWLeBG+fZUMX9Tic2dUOg2CIyLIbeU1jF5M5k4 cirHZNXXsy/HoCK+Ec3nkbEqybICFK6Nv0/m7J2kQimaN5HY8oLUDRcam35vuU/yr3slPuGk7xT8g MBWoNat1Q==; Received: from mail-wr0-x236.google.com ([2a00:1450:400c:c0c::236]) by merlin.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1d2L48-0005QF-W1 for linux-arm-kernel@lists.infradead.org; Sun, 23 Apr 2017 17:12:53 +0000 Received: by mail-wr0-x236.google.com with SMTP id z109so79246167wrb.1 for ; Sun, 23 Apr 2017 10:12:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=M3METMFXZcq4Hcd4bFSaUwf9qopGkDRhezYrzAhISGE=; b=Jenuwx8+z4hrYZQr/v21g8zup/J3+OHW/g1EncDwQx3oeHsXJ06bSnKCE2uOG5USxQ aS4iEnLZvUV0W+RSBcRE8s8FGyEMIF7TJB5q70hr+sh8Y9WofDBzqzNI1kzuIsy+bkvL R7/+ojeEC7sN9Ah+Ra9jsWheBFNsLt5TwO3OA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=M3METMFXZcq4Hcd4bFSaUwf9qopGkDRhezYrzAhISGE=; b=d0llYGmf/SNe5K2DTGsuQ3KFfsLpm9BDosw4jScQsUf3athY4hP9u+ET6UuanDdL7/ 230n1U02xzYvomX9zVftRIxP5HDrGeHfhnmyO15JvNfwiq7W5BpIjqwtH2ziiQyMdlxF s/9fOfnMV2drwz5TL0AmUP5R9OHVbOJB8ZcS1307uESwhF8ygmyjCqDxfKCCQNeBttjZ atCZgjLsQHlJdcEsjUlsX8ll6/jmswQbF8TcYvZsrPU27NFe5z61XDl4h/spPjmP3Wke onOdpNjGVOPH3OFKlStPuQ9zTvjeluw8I94Sgedh7R+D0QRp6mpB7CEVArMM9TrmirFl m5zg== X-Gm-Message-State: AN3rC/7CZ5wXDal/w9LtUinE07tKpuEHkV1LK/HQ+unzyTNk/GgIQh/R Fai441Yz6jYS5Ny+ X-Received: by 10.223.129.229 with SMTP id 92mr2593576wra.17.1492967430947; Sun, 23 Apr 2017 10:10:30 -0700 (PDT) Received: from localhost.localdomain (xd93ddc2d.cust.hiper.dk. [217.61.220.45]) by smtp.gmail.com with ESMTPSA id 58sm2803521edz.2.2017.04.23.10.10.29 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 23 Apr 2017 10:10:30 -0700 (PDT) From: Christoffer Dall To: Paolo Bonzini , =?UTF-8?q?Radim=20Kr=C4=8Dm=C3=A1=C5=99?= Subject: [PULL 56/79] ARM: KVM: Implement HVC_GET_VECTORS in the init code Date: Sun, 23 Apr 2017 19:09:06 +0200 Message-Id: <20170423170929.27334-57-cdall@linaro.org> X-Mailer: git-send-email 2.9.0 In-Reply-To: <20170423170929.27334-1-cdall@linaro.org> References: <20170423170929.27334-1-cdall@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170423_131253_163078_B5B9584F X-CRM114-Status: UNSURE ( 9.60 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Marc Zyngier , Christoffer Dall , kvmarm@lists.cs.columbia.edu, kvm@vger.kernel.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Marc Zyngier Now that we have an infrastructure to handle hypercalls in the KVM init code, let's implement HVC_GET_VECTORS there. Tested-by: Keerthy Acked-by: Russell King Acked-by: Catalin Marinas Signed-off-by: Marc Zyngier Signed-off-by: Christoffer Dall --- arch/arm/kvm/init.S | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/arm/kvm/init.S b/arch/arm/kvm/init.S index 86a7008..d6b2f49 100644 --- a/arch/arm/kvm/init.S +++ b/arch/arm/kvm/init.S @@ -122,7 +122,12 @@ __do_hyp_init: eret ENTRY(__kvm_handle_stub_hvc) - cmp r0, #HVC_RESET_VECTORS + cmp r0, #HVC_GET_VECTORS + bne 1f + mrc p15, 4, r0, c12, c0, 0 @ get HVBAR + b exit + +1: cmp r0, #HVC_RESET_VECTORS bne 1f ENTRY(__kvm_hyp_reset) /* We're now in idmap, disable MMU */