Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp5487916imm; Tue, 18 Sep 2018 10:16:34 -0700 (PDT) X-Google-Smtp-Source: ANB0Vdb8YbI6YY+bQeQCAlij7x6UjCpdoktIWLikmxEmqBbo7eVOYTbYW/Ydhju5BPIwRk2qmPaE X-Received: by 2002:a63:cc4f:: with SMTP id q15-v6mr28641591pgi.217.1537290994237; Tue, 18 Sep 2018 10:16:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537290994; cv=none; d=google.com; s=arc-20160816; b=HJvri5/sbN20B/cZu/5XtACrRlri+9rdTSC1QFgCIYmIBbzf6c/hjl2hksn3gqfF+C du41/C9VOussUVBpeZzF7yjENZ1qJh1u9G+JKnPbENiQjPzBlRFjs7n1TM+2JLCYcTRP /eWvHlhbZ/T7zGkbi7Qs2qpnRH7WPU/WGGkMti1dli7WyKWic8ZcY2OXbBfzaben4cxl ZtW3osezeSbVVB/dx0ymiVteNhBzAnQkIE6MR9pslVP/PBsY7PGPzAAkUtxIF56a8KjY F5PnqpM80hnY056QxN1PJ5lJLhRgTJSBuiBUg+6AxBB4XFtCgn3ETIaXJVpxux0rvJ0H 9NKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=hjxlgMBJh3aKKpp4QEs4VlxRsTmFJTsvBWoYUI9XvS0=; b=IMUtPO7FU4tutt3K1E7GAueqXUqhcZj6y5NBqInZGm9uuAzZHJ6pKAXPAD/0rbOnu9 NNunWlxlhuU2nfhr0FiVDDeiWZAXfxifxm3u63Lc8sJkDFC+1ObsDH4d+R0f2WkExbNg b0NP/3aej9NB1fcAwOYw/0OWe/MtNYfRQLAboloqXTyCUZBQhcY8WlaEjeal1LCEAZax 9tS7c7Dj5XFty+wdt99gRfZXktBQ+l2TE8vBVzNsatSCaHOWFlaJB24BMiaWe0aAaaaK smgvZktHE420kv/vDCTVAo3YyEnuX8nVZtFFAKD+Qu38hN/ywWOT0oMhqsBWuOVkDmjv 97KA== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x7-v6si18631715pgi.465.2018.09.18.10.16.19; Tue, 18 Sep 2018 10:16:34 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730461AbeIRWtF (ORCPT + 99 others); Tue, 18 Sep 2018 18:49:05 -0400 Received: from foss.arm.com ([217.140.101.70]:48418 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729037AbeIRWtF (ORCPT ); Tue, 18 Sep 2018 18:49:05 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id B877A7A9; Tue, 18 Sep 2018 10:15:32 -0700 (PDT) Received: from edgewater-inn.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.72.51.249]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 897A13F703; Tue, 18 Sep 2018 10:15:32 -0700 (PDT) Received: by edgewater-inn.cambridge.arm.com (Postfix, from userid 1000) id 758CA1AE1396; Tue, 18 Sep 2018 18:15:51 +0100 (BST) Date: Tue, 18 Sep 2018 18:15:51 +0100 From: Will Deacon To: Robert Richter Cc: Mian Yousaf Kaukab , marc.zyngier@arm.com, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, cwu@amperecomputing.com Subject: Re: [PATCH RESEND 3/6] arm64: add sysfs vulnerability show for spectre v1 Message-ID: <20180918171550.GN16498@arm.com> References: <20180827143310.641-1-ykaukab@suse.de> <20180827143310.641-4-ykaukab@suse.de> <20180917172206.GA3795@rric.localdomain> <20180918083805.GB14404@arm.com> <20180918095226.GJ3795@rric.localdomain> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180918095226.GJ3795@rric.localdomain> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Sep 18, 2018 at 11:52:27AM +0200, Robert Richter wrote: > On 18.09.18 09:38:05, Will Deacon wrote: > > On Mon, Sep 17, 2018 at 07:22:07PM +0200, Robert Richter wrote: > > > On 27.08.18 16:33:07, Mian Yousaf Kaukab wrote: > > > > Hard-coded since patches are merged and there are no configuration > > > > options. > > > > > > Could you add a list of upstream patches to the description that are > > > required to solve this? This would be a strict definition for the > > > mitigation being enabled and makes it easier to check if backports are > > > affected or not. A build-time check would be ideal (e.g. checking for > > > certain macros). > > > > Hmm, I don't grok what you're proposing here. Why do we need a build-time > > check (and to check what?) > > My concern is, that for kernel backports (esp. distro kernels) there > could be various interpretations of what "Mitigation: __user pointer > sanitization" means. So a list of upstream patches that need to be > backported in addition to this patch as a requirement would be good to > agree on. That should be documented in the patch description. > > If these mitigations are available in a kernel backport, that could be > even checked at build time. E.g. we could have a sanity check if the > macro array_index_nospec() is defined. But such a check does not > replace a code review of a kernel backport. > > I hope that makes sense? Ok, I see what you mean now, thanks. However, it doesn't sound much different than backporting a patch with dependencies, so I'd rather avoid adding additional code to treat this case specially. Will