From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 21754C433DF for ; Wed, 24 Jun 2020 11:57:22 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E03E320857 for ; Wed, 24 Jun 2020 11:57:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="IWaRiW5C" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E03E320857 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Type: Content-Transfer-Encoding:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=9WTLbdCYSfG+UhqSc8rW5vWOmx1eXixlV01s6+T/G+k=; b=IWaRiW5C55S+hRMK8bw40wLqw /9FeaHPKkm7xaJwJJZUvcQscbp7Oqmo1j7FY1pwu9v1tg83tzhH4R6+nEARfXq6VrcYNbjhNGguRc NjfaWtfBWIyFrNzRMZ/Yjv2VyKGJ13Tn1JE4JRZE2RJZn+jHa9KRm+pWxfKLbLzQVT8AN3n7PXMDU nFyq/agB6OyvVDVLhPiE4d00YCHUwgKlUGODnjhe3nTgANmkTxKR4QQcl4faIqYkEztUo1mMZ75rx Alb7NmQ6xnxlUCGZL9zVG3y8V7XEupxNYWNC9D9zyruoBdKwY2vy1Ukg7rXThi3beUuJsaaQZt7cF VUkfBzXig==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jo40D-0004Gy-Ad; Wed, 24 Jun 2020 11:55:41 +0000 Received: from foss.arm.com ([217.140.110.172]) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jo406-0004FO-Cb for linux-arm-kernel@lists.infradead.org; Wed, 24 Jun 2020 11:55:36 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id EAFA91F1; Wed, 24 Jun 2020 04:55:33 -0700 (PDT) Received: from [10.57.20.252] (unknown [10.57.20.252]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 07D263F6CF; Wed, 24 Jun 2020 04:55:30 -0700 (PDT) Subject: Re: [PATCH v3 2/3] arm64: cpufeature: Modify address authentication cpufeature to exact To: Will Deacon References: <1592457029-18547-1-git-send-email-amit.kachhap@arm.com> <1592457029-18547-3-git-send-email-amit.kachhap@arm.com> <20200622143503.GT25945@arm.com> <20200623144749.GZ25945@arm.com> <20200624074923.GA5853@willie-the-truck> From: Amit Daniel Kachhap Message-ID: <63b5d96e-67b8-229f-b89a-36e997c9b8db@arm.com> Date: Wed, 24 Jun 2020 17:25:28 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 MIME-Version: 1.0 In-Reply-To: <20200624074923.GA5853@willie-the-truck> Content-Language: en-US X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , Kees Cook , Suzuki K Poulose , Catalin Marinas , Kristina Martsenko , Mark Brown , James Morse , Vincenzo Frascino , Dave Martin , linux-arm-kernel@lists.infradead.org Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi, On 6/24/20 1:19 PM, Will Deacon wrote: > On Wed, Jun 24, 2020 at 12:43:20PM +0530, Amit Daniel Kachhap wrote: >> On 6/23/20 8:17 PM, Dave Martin wrote: >>> On Tue, Jun 23, 2020 at 06:47:02PM +0530, Amit Daniel Kachhap wrote: >>>> On 6/22/20 8:05 PM, Dave Martin wrote: >>>>> On Thu, Jun 18, 2020 at 10:40:28AM +0530, Amit Daniel Kachhap wrote: >>>>>> This patch modifies the address authentication cpufeature type to EXACT >>>>> >from earlier LOWER_SAFE as the different configurations added for Armv8.6 >>>>>> enhanced PAC have different behaviour and there is no tunable to enable the >>>>>> lower safe versions. > > $ git grep 'This patch' Documentation/process/submitting-patches.rst ok sure. I will update. > >>>>> Does a corresponding patch need to go to stable? As things stand, I >>>>> think older kernels that support pointer auth will go wrong on v8.7+ >>>>> hardware that has these features. >> >> Yes It makes to add this patch to the stable version. >> >> @Catalin, @Will - Shall I send this one with a fix subject line? Please let >> me know your suggestion. > > What exactly goes wrong? As far as I can tell, we will taint and probably > (?) crash shortly afterwards if you run an old kernel on hardware with > mismatched pointer auth. Yes you are right that 8.6+ hardware will crash with older kernel if ptrauth cpu variation occurs. Basically EnhancedPAC2(with extra xor) and old pac algorithm may not be compatible and may crash when thread migration happens in between paciasp and autiasp [1]. [1]: https://community.arm.com/developer/ip-products/processors/b/processors-ip-blog/posts/arm-architecture-developments-armv8-6-a > If that's the case, I don't think this warrants > stable (especially since this file has seen enough churn that the backports > are likely risky). ok. I was seeking mere opinion :). > > Can you confirm that things only go wrong if we have a mismatched system, > and ideally provide an example of what the crash looks like (you should > be able to get a fast model to emulate this setup)? It is difficult to emulate this as fast model only provides cluster level pac config option and not at cpu level. I will check on it further. Thanks, Amit Daniel > > Cheers, > > Will > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel