Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp1184307imj; Thu, 14 Feb 2019 02:35:46 -0800 (PST) X-Google-Smtp-Source: AHgI3IanOKcJfyaBh0Opetu6CxwJCVoYSvRHu2tBNlnpZO3xj2EieHvXXy6N9Vzgi6sorCGjoN3s X-Received: by 2002:a65:484c:: with SMTP id i12mr3039400pgs.309.1550140546171; Thu, 14 Feb 2019 02:35:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550140546; cv=none; d=google.com; s=arc-20160816; b=qXP+LlJyR/CTwqUNMNYcDQ3Os8TiPXOosfJQEUUil3i26dw2C8S2fu3UVHcfjxSEuw H3ohkKGqs8ger+a7ujF6/dB0fBzdYu8raYcz1r0oRJnLPk25PvN6nCF0zOL5CQuSxVSH IERdzxAWJNAW7ZLL51dPIUqzsubJUlCPs7MTTwWYm/5c9yrLR1ccf3zouUBki3icn+GB IM90rszCARPwGhiZt9NWA0og5pUrIb+SqOlQd/nkoeIIp4SFDURvyBW/xnk11IRpp9wQ Fn2tO2xWVTOaZ3119BSQk5h1FUBCNdUm7OWdp22RCTvQZqrJxzgI+qRD9TT9DyexUaVv 70Pg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=xIzVBfVsJyFafmUW72TZLqDDrY1szfaf1MexYWgTKBk=; b=q5RTCvx+ziMGN+XjpJZ10XTMm4g/UlH6z/UGcfgbAzk86A1jD0qUC3eypQDSwPBzwb EeQRFlyxI3NnelaAU9BmQQgV7ytJPdeMGwAgtaL/UxrIXx22ZimiyloIXVuDQ14wLVGC MUa1g+0DkgsIOrsaGWzH3CNHwWeRx9zbIDJdE4hzO8z9+fViCDzx1DT568rzXPDYRDpQ Ki7LqIVhUjl0dWYZiG3pTH5x7Gq3i5VJKi3ttqp9ZpBVkZAUGXrW1nUZEbRgOUUMtTuU 6vEYR5q/ozareXkx0tmzjX5t/E8zUdGYDaBh/DHMJ6Wq5bCge6zeF2dmxVYU/Tb9g6Uj XcXQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=bSJWiF25; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d38si2137704pla.207.2019.02.14.02.35.29; Thu, 14 Feb 2019 02:35:46 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=bSJWiF25; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2394048AbfBNCL7 (ORCPT + 99 others); Wed, 13 Feb 2019 21:11:59 -0500 Received: from mail-qk1-f193.google.com ([209.85.222.193]:40335 "EHLO mail-qk1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2393882AbfBNCKc (ORCPT ); Wed, 13 Feb 2019 21:10:32 -0500 Received: by mail-qk1-f193.google.com with SMTP id y16so2708895qki.7 for ; Wed, 13 Feb 2019 18:10:32 -0800 (PST) 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=xIzVBfVsJyFafmUW72TZLqDDrY1szfaf1MexYWgTKBk=; b=bSJWiF25S/UclV7gkfOpR2SXzbsw/A4AR4+zqb6qpO1veqy64HDC/XScLrdw2icpDo 8MeRynHIaSNrIqFB0vfA6ZGHYZNkbKWzCbhK9J6kq6BZ8+glVioFlrXk2DDOFNNacJQm K2go/hcpMhSEu9jvcd6bGuaBqIYV8qC28c8ZuJUdy0TnBq08qIO8x4EWMT+3xP57x3oN egAFkNBRPOprcjoZo+wOGoqVT9JJ7kQUpHquKsi1QRij0QRawyMbLRLzNCAyrOkzF5iI W5GYCuAYRxuPYgAyg9OBraDCEXAkMPV3Ya1oVVwTU+g1WovCI5VzvAHvoqz5pZXHWMw+ 6BuA== 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=xIzVBfVsJyFafmUW72TZLqDDrY1szfaf1MexYWgTKBk=; b=kjPHfl8IAhqCak1woiF3AqFdT8/Syd2bM0r4EXkEqF73wNGZcvOhTbcfefQLMdR8Aw Rga25JY1wCn8z+DVlEm4Rt3hakPQi/6tLJ9gSGCWO6vgDNmB8ssuCj9wp/RrPwOQjKsx oWUNBsXZiYcWRfy3YxERzL+ipzSyXsCpeexuRtru3P39xgvaHVoqgo/dk3ZNmNRgDwbT hnl01GpDiSZcLN04uwtUX6Pll05rHEX6TWVMGnYRfxtYX2pHMMRZzxQtjbjYEpd+wiYY YV0Uj7pXVsg25tc5IgsAyUfv6U6CnZGHaFKuTt0PDUZ+sYy5x666VqEx6FGpGmpuf+xC 33/g== X-Gm-Message-State: AHQUAub9oE7H9Bcp1QngXDuBxa6lg5bqGPcsTGBbvwnCt5TrXludsWDe Ip0sonGwtsvaCegU0b+abvnmtA== X-Received: by 2002:a37:3641:: with SMTP id d62mr982296qka.14.1550110231737; Wed, 13 Feb 2019 18:10:31 -0800 (PST) Received: from localhost.localdomain (pool-72-71-243-63.cncdnh.fast00.myfairpoint.net. [72.71.243.63]) by smtp.googlemail.com with ESMTPSA id d63sm1091575qka.22.2019.02.13.18.10.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 13 Feb 2019 18:10:31 -0800 (PST) From: David Long To: stable@vger.kernel.org, Russell King - ARM Linux , Florian Fainelli , Julien Thierry , Tony Lindgren , Marc Zyngier , Greg KH , Mark Rutland Cc: Will Deacon , Mark Brown , linux-kernel@vger.kernel.org Subject: [PATCH 4.14 V2 05/17] ARM: 8793/1: signal: replace __put_user_error with __put_user Date: Wed, 13 Feb 2019 21:10:10 -0500 Message-Id: <20190214021022.5313-6-dave.long@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190214021022.5313-1-dave.long@linaro.org> References: <20190214021022.5313-1-dave.long@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Julien Thierry Commit 18ea66bd6e7a95bdc598223d72757190916af28b upstream. With Spectre-v1.1 mitigations, __put_user_error is pointless. In an attempt to remove it, replace its references in frame setups with __put_user. Signed-off-by: Julien Thierry Signed-off-by: Russell King Signed-off-by: David A. Long --- arch/arm/kernel/signal.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/arm/kernel/signal.c b/arch/arm/kernel/signal.c index 1eb83ee7e1cc..02e6b6dfffa7 100644 --- a/arch/arm/kernel/signal.c +++ b/arch/arm/kernel/signal.c @@ -344,7 +344,7 @@ setup_sigframe(struct sigframe __user *sf, struct pt_regs *regs, sigset_t *set) if (err == 0) err |= preserve_vfp_context(&aux->vfp); #endif - __put_user_error(0, &aux->end_magic, err); + err |= __put_user(0, &aux->end_magic); return err; } @@ -476,7 +476,7 @@ setup_frame(struct ksignal *ksig, sigset_t *set, struct pt_regs *regs) /* * Set uc.uc_flags to a value which sc.trap_no would never have. */ - __put_user_error(0x5ac3c35a, &frame->uc.uc_flags, err); + err = __put_user(0x5ac3c35a, &frame->uc.uc_flags); err |= setup_sigframe(frame, regs, set); if (err == 0) @@ -496,8 +496,8 @@ setup_rt_frame(struct ksignal *ksig, sigset_t *set, struct pt_regs *regs) err |= copy_siginfo_to_user(&frame->info, &ksig->info); - __put_user_error(0, &frame->sig.uc.uc_flags, err); - __put_user_error(NULL, &frame->sig.uc.uc_link, err); + err |= __put_user(0, &frame->sig.uc.uc_flags); + err |= __put_user(NULL, &frame->sig.uc.uc_link); err |= __save_altstack(&frame->sig.uc.uc_stack, regs->ARM_sp); err |= setup_sigframe(&frame->sig, regs, set); -- 2.17.1