Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp3044426imm; Fri, 19 Oct 2018 04:16:26 -0700 (PDT) X-Google-Smtp-Source: ACcGV63fnYBf38/W1U6xM3L+CFTdUcQuO72zIGD3+w+SJuPMcs/o1Acs3+SIQ6/wb+Ozcw9kSA++ X-Received: by 2002:a62:460c:: with SMTP id t12-v6mr27351510pfa.206.1539947786805; Fri, 19 Oct 2018 04:16:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539947786; cv=none; d=google.com; s=arc-20160816; b=j4DdhLyjC7LpTnWqPWc6qaR7BFHDpEEjTmMYAUKRwYXOFBkMnyRhmgPU0OSheRph6x E38LfLbFLWckgpFtRZPhCtd+mup6Gt9QSzWMFtADXc+e4InrVfNGJ2NegaSiLMSsoWlQ fwvF4dEDj/mxzDDeqyNlkJyqMAFZ1sg8bKsSb0threTzey7GTWvgJZt1cD53KEX9GkcG gqCcLOGryQ8RY6Vbjfb5x7rYNi5irSPBtEi7AsWZwKdyC3wCBOu6T2znMZHniiKVcwj2 319XxQGYLDoMUBlqELl41X5TUBVByi5ylu/rzc9DrwFsuJJ/0RUzcJ02zpljUiFt9Lfe LvsQ== 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=Fq6iCWjndBw/MwrLyqjLsYxOB3Q/wN08St0kDxWjXyQ=; b=Zxu7xyn0bhMxgzC5j/Z3mEeP+ORjBrbfI2ZtJPKrj9nLI9PMnKuk6jQ3npTGTzQzyL 0DP7/4crtU4JpcYQm8Bl6AVlWpDfm6ipn3vryMVK1RA+2pubaVSL+zMwlIB5nZeMe1yX kFmIflkSefdBr8ltNHL5U7WNoymaWEEsv+TYLHI6+N1V4HUUVjdLiqHppYgTAURuQGO2 c9m1ynSa7GXSXrJX1qJvzRK1trj36zPfEulCdMzqYMjnkR99Uc3n2T7FraXc3q4NWQoH RnZR6s6ejznltEI4m09yzkiOKiICIbRozC9XDHUubt+r4TL4Hyz/uhzSGQzTcx6tMpZd SG0g== 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 bg12-v6si23398694plb.319.2018.10.19.04.16.11; Fri, 19 Oct 2018 04:16:26 -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 S1727197AbeJSTV0 (ORCPT + 99 others); Fri, 19 Oct 2018 15:21:26 -0400 Received: from foss.arm.com ([217.140.101.70]:50590 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726784AbeJSTV0 (ORCPT ); Fri, 19 Oct 2018 15:21:26 -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 0AAE780D; Fri, 19 Oct 2018 04:15:49 -0700 (PDT) Received: from mbp (usa-sjc-mx-foss1.foss.arm.com [217.140.101.70]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id D89063F71D; Fri, 19 Oct 2018 04:15:45 -0700 (PDT) Date: Fri, 19 Oct 2018 12:15:43 +0100 From: Catalin Marinas To: Kristina Martsenko Cc: linux-arm-kernel@lists.infradead.org, Mark Rutland , linux-arch@vger.kernel.org, Andrew Jones , Jacob Bramley , Arnd Bergmann , Ard Biesheuvel , Marc Zyngier , Adam Wallis , "Suzuki K . Poulose" , Will Deacon , Christoffer Dall , kvmarm@lists.cs.columbia.edu, Ramana Radhakrishnan , Amit Kachhap , Dave P Martin , linux-kernel@vger.kernel.org, Kees Cook Subject: Re: [PATCH v5 07/17] arm64: add basic pointer authentication support Message-ID: <20181019111542.6wrvjguirglzg7vg@mbp> References: <20181005084754.20950-1-kristina.martsenko@arm.com> <20181005084754.20950-8-kristina.martsenko@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181005084754.20950-8-kristina.martsenko@arm.com> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Oct 05, 2018 at 09:47:44AM +0100, Kristina Martsenko wrote: > diff --git a/arch/arm64/include/asm/pointer_auth.h b/arch/arm64/include/asm/pointer_auth.h > new file mode 100644 > index 000000000000..2aefedc31d9e > --- /dev/null > +++ b/arch/arm64/include/asm/pointer_auth.h > @@ -0,0 +1,63 @@ > +// SPDX-License-Identifier: GPL-2.0 > +#ifndef __ASM_POINTER_AUTH_H > +#define __ASM_POINTER_AUTH_H > + > +#include > + > +#include > +#include > + > +#ifdef CONFIG_ARM64_PTR_AUTH > +/* > + * Each key is a 128-bit quantity which is split across a pair of 64-bit > + * registers (Lo and Hi). > + */ > +struct ptrauth_key { > + unsigned long lo, hi; > +}; > + > +/* > + * We give each process its own instruction A key (APIAKey), which is shared by > + * all threads. This is inherited upon fork(), and reinitialised upon exec*(). > + * All other keys are currently unused, with APIBKey, APDAKey, and APBAKey > + * instructions behaving as NOPs. > + */ I don't remember the past discussions but I assume the tools guys are ok with a single key shared by multiple threads. Ramana, could you ack this part, FTR? (and it would help if someone from the Android and Chrome camps can confirm) Thanks. -- Catalin