From patchwork Thu May 18 09:47:11 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoffer Dall X-Patchwork-Id: 9733091 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 15335601A1 for ; Thu, 18 May 2017 09:48:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F3991285F7 for ; Thu, 18 May 2017 09:48:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E87302860A; Thu, 18 May 2017 09:48:32 +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 7EE41285F7 for ; Thu, 18 May 2017 09:48:32 +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=7zCDwy2/Jx5PmhAWpgecnYRYFKFy7ogHbOHS2AundN8=; b=Y7qSpkmRY2ZaopvUm79WpJUNTt frscHanaO3VkIkSq/+T3GZFUiGJmragWuWcz5eH9kqOpqRmOuVEP3BMKQnYUmQTGyr8mWWUQT3N8A o87mg4LwHY8+padsLif2Cnlk0Bs61YioA7v08kPm2TMnjrI/wZv4unYPXdghkn2mht32uxP9txB3T 5Syv0ebxhyrnTA09hsh1iF8EuO26WA8/nucWW34yBVVokW/lmeD+hrWlbZ3KpXXHWiHxU3gZ0nQ47 cOxsjsx9c2ePc/UfRf+QwALhvUFCXQ/9NGJTRr/uGKv6VXzxrQ229O9V9T2DtV0BRksQHLv6zsyhM ZGHkGpWg==; 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 1dBI2p-00060Q-1n; Thu, 18 May 2017 09:48:31 +0000 Received: from mail-wm0-x234.google.com ([2a00:1450:400c:c09::234]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dBI2K-0005KX-HG for linux-arm-kernel@lists.infradead.org; Thu, 18 May 2017 09:48:02 +0000 Received: by mail-wm0-x234.google.com with SMTP id d127so45807053wmf.0 for ; Thu, 18 May 2017 02:47:40 -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=xUJ0KNro7ANYTRNK6edAP2Tl+YVEY0vvxwAQ8eceEdo=; b=Dq/vKVll46Ega3C2UVVs2KB+maYwXEA67JmwuIlPaxo+A2jNOFv53DORvMwkkuRKy+ gxZhDKtEkh3QkXQjZ4N79p2qCyoXTh5kfDNtUM+S1R6brXMzuZG4oyB3EDUecHerPL9a dTz5HxV/BOObZI/YJI9vXFqlY1nzvUvWFva6Y= 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=xUJ0KNro7ANYTRNK6edAP2Tl+YVEY0vvxwAQ8eceEdo=; b=W6CkZne1Kz/mrE/zrmNek8kMiXUvSwwsP9D4U+mAV6i7Y6fkKb2uW+DMIUo0mzdxEK zLsrwOKztWKlnd/yMXz3+SUVjyWhVRC2vA5Fpa7ERM9eONauJnmYC7/21RfgzIpeeEha NCr3oEX1N7P2kQ4wwacXX6YAFqeIBuTyMkK4OfSUpBkJkXjITgTyNdA4d6ohUw7rmJ+z olPQg0Nzem+lrATIxNdpvQPyv6Q7kMg0l7C7LiQH9o4Yndj1cjbPpSX+i+bDK9+6uAs1 asBp6WwkehMnHIIQvOCNU3g5lRVoZ4a7+hLAOzaxW5l3JtbQtArAIVZJqpiH1S+ffmmV HRXg== X-Gm-Message-State: AODbwcDpsjEZL52sh9Cg5TbpjtozuQziEs4md3ogHwsOcUXmBHh9irWL 1OwCe953R78i3Ybr X-Received: by 10.80.174.131 with SMTP id e3mr2516887edd.166.1495100858840; Thu, 18 May 2017 02:47:38 -0700 (PDT) Received: from localhost.localdomain (xd93ddc2d.cust.hiper.dk. [217.61.220.45]) by smtp.gmail.com with ESMTPSA id w15sm2377437edw.27.2017.05.18.02.47.37 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 18 May 2017 02:47:38 -0700 (PDT) From: Christoffer Dall To: Paolo Bonzini , =?UTF-8?q?Radim=20Kr=C4=8Dm=C3=A1=C5=99?= Subject: [PULL 02/13] arm64: KVM: Do not use stack-protector to compile EL2 code Date: Thu, 18 May 2017 11:47:11 +0200 Message-Id: <20170518094722.9926-3-cdall@linaro.org> X-Mailer: git-send-email 2.9.0 In-Reply-To: <20170518094722.9926-1-cdall@linaro.org> References: <20170518094722.9926-1-cdall@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170518_024800_786428_8C4325C4 X-CRM114-Status: GOOD ( 10.35 ) 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: Christoffer Dall , kvm@vger.kernel.org, Marc Zyngier , stable@vger.kernel.org, kvmarm@lists.cs.columbia.edu, 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 We like living dangerously. Nothing explicitely forbids stack-protector to be used in the EL2 code, while distributions routinely compile their kernel with it. We're just lucky that no code actually triggers the instrumentation. Let's not try our luck for much longer, and disable stack-protector for code living at EL2. Cc: stable@vger.kernel.org Signed-off-by: Marc Zyngier Acked-by: Christoffer Dall Signed-off-by: Christoffer Dall --- arch/arm64/kvm/hyp/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm64/kvm/hyp/Makefile b/arch/arm64/kvm/hyp/Makefile index aaf42ae..14c4e3b 100644 --- a/arch/arm64/kvm/hyp/Makefile +++ b/arch/arm64/kvm/hyp/Makefile @@ -2,6 +2,8 @@ # Makefile for Kernel-based Virtual Machine module, HYP part # +ccflags-y += -fno-stack-protector + KVM=../../../../virt/kvm obj-$(CONFIG_KVM_ARM_HOST) += $(KVM)/arm/hyp/vgic-v2-sr.o