From patchwork Tue Sep 1 15:10:11 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 248944 Delivered-To: patch@linaro.org Received: by 2002:a17:906:6447:0:0:0:0 with SMTP id l7csp3762472ejn; Tue, 1 Sep 2020 10:03:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxP/byDtSXuaZozNET9YPS7qtvxuy6v2yyYjh6uQJc0DcS9gEgbpAAQ/BSTy1wEvxkO//Lo X-Received: by 2002:a17:906:90d3:: with SMTP id v19mr2346414ejw.23.1598979796215; Tue, 01 Sep 2020 10:03:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598979796; cv=none; d=google.com; s=arc-20160816; b=SRH4Zk5X4jp+ECs64gRUi5ZPJKIg7nqQHXhCqMcYR2r8EDZ5q867GLR7xjEDx8ewHS fxDCOfvg/aZ5JVgjv7oRe9tGdtk28wuc3muPByhYQCbIH/TsgUKu4YWbfCbdLjM3TzVf FyxEfWJY8Vnwe/akSensgAyn5RFTFQcUgcuU9QjGSmzr/nt6yNOg4RBlKd1Yhj2uW9PF HqTDjliVpBsyvSrvqtdzTDjB6V48zCd7eI3PvpksYGEXhFsVPd57Uvl4h7VTFdHwUi8O ojEz/EH43J2fFv5OohKnzwDC1mNwCO3vgqQ0q5frlQxquKosYWq+LvRXLQzm0vKSOgtT 1bLg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=3K0iVBlXSI7FpYnF0FBGoim1U1cDegL+xncMx4WtlVs=; b=FN+LPyrnzlRKmSA8ZTlAvXcjQuSX6e2GRXQnmK/nS7cSp+25t90DT6xTdUBBZho7/g +lNhSwKs5au7Aj4uFwiJF4GHh7/jBEO9aV/y+rJNGSjnrUVLaM8fTuU1SnQweyMuB/vn stwbFkMRmh5RXO94mCqrLGkQD65wO4GlE7FDrjP/iAV32/lT51jAVkVxIPlFSNiguELp 0lwniP22SPl1p2SBSZauUZvqnl5MRHXsAPOgcyQDMcwON8xIDuuW8ZmgnNVsbR7Nu5h3 +I/RDIwmU2NQCh46H8/+eHSPe/H67szopiLlta7MhTWPFWnjRGipMGE47MF8SPLxJlO1 oVoQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=uMI3AyIQ; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y22si976205ejc.453.2020.09.01.10.03.15; Tue, 01 Sep 2020 10:03:16 -0700 (PDT) Received-SPF: pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=uMI3AyIQ; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729594AbgIARDN (ORCPT + 15 others); Tue, 1 Sep 2020 13:03:13 -0400 Received: from mail.kernel.org ([198.145.29.99]:39860 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729590AbgIAPUK (ORCPT ); Tue, 1 Sep 2020 11:20:10 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 09C0120767; Tue, 1 Sep 2020 15:20:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1598973609; bh=jSanhpfmu+54nj95N++yGFgD3ULnJXuEynxR2aByFL0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=uMI3AyIQXQo9JbT9FiJSztCnSr1JFpITETQCa/PjeFBPGD5m3kUpodD/hAjVzpo3n y2wBf8YbZIFw3ChE2KUqhcMviccP6edCnvLWLHCQjhSLdrwfYf3oyI8miBbWV6456j IAiADRG2ZpW9Z/j0lVqacMm9J0rWHHSnD+8QvlPU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, David Brazdil , Marc Zyngier , Sasha Levin Subject: [PATCH 4.14 37/91] KVM: arm64: Fix symbol dependency in __hyp_call_panic_nvhe Date: Tue, 1 Sep 2020 17:10:11 +0200 Message-Id: <20200901150929.981171314@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200901150928.096174795@linuxfoundation.org> References: <20200901150928.096174795@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: David Brazdil [ Upstream commit b38b298aa4397e2dc74a89b4dd3eac9e59b64c96 ] __hyp_call_panic_nvhe contains inline assembly which did not declare its dependency on the __hyp_panic_string symbol. The static-declared string has previously been kept alive because of a use in __hyp_call_panic_vhe. Fix this in preparation for separating the source files between VHE and nVHE when the two users land in two different compilation units. The static variable otherwise gets dropped when compiling the nVHE source file, causing an undefined symbol linker error later. Signed-off-by: David Brazdil Signed-off-by: Marc Zyngier Link: https://lore.kernel.org/r/20200625131420.71444-2-dbrazdil@google.com Signed-off-by: Sasha Levin --- arch/arm64/kvm/hyp/switch.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.25.1 diff --git a/arch/arm64/kvm/hyp/switch.c b/arch/arm64/kvm/hyp/switch.c index 4a8fdbb292863..0ad952e074457 100644 --- a/arch/arm64/kvm/hyp/switch.c +++ b/arch/arm64/kvm/hyp/switch.c @@ -444,7 +444,7 @@ static void __hyp_text __hyp_call_panic_nvhe(u64 spsr, u64 elr, u64 par, * making sure it is a kernel address and not a PC-relative * reference. */ - asm volatile("ldr %0, =__hyp_panic_string" : "=r" (str_va)); + asm volatile("ldr %0, =%1" : "=r" (str_va) : "S" (__hyp_panic_string)); __hyp_do_panic(str_va, spsr, elr,