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=-3.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham 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 9507CC31E5B for ; Mon, 17 Jun 2019 16:57:03 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 6DEC720652 for ; Mon, 17 Jun 2019 16:57:03 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="io9k1XdC"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=armh.onmicrosoft.com header.i=@armh.onmicrosoft.com header.b="mTC4ddt/" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6DEC720652 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+infradead-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=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Content-ID:In-Reply-To: References:Message-ID:Date:Subject:To:From:Reply-To:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=cdPjOD1zLSiC1YcCG3oJV7Z6Ye/9kpV4gy8rMn8BnhA=; b=io9k1XdC/AMQ15 tkleR0cy1yqOmtJoOvilpdTYp1Q0j94AjGCarFjqM6s9FwwDpS3SmWy1SIeHc1ki+bXSI7Qmq9hkl xj/ojaHm+CRHTvmtj9u3rAiCjphOxatC34ww/OwNdgPSnhMtFLSctqsMiqvhbiohKTc4CcPotoEa5 cHlzGoVDqhL46noO/+0F86BHrYrSbDs6bmeX5cC0WW4mC/MCvrkdPYxvZOO8uV7Cstxa2Qc/+KxTi JwoA9Pxbb6STIEW7+F4Hzi3uutl77jcZaZpEDgeP/fgvDxanzgXPCzXQGPIsMmnCha5KpqPRQBBHP YP2rnMCIzMAby3V1aIDg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hcuw6-0007rw-OG; Mon, 17 Jun 2019 16:56:50 +0000 Received: from mail-ve1eur01on0624.outbound.protection.outlook.com ([2a01:111:f400:fe1f::624] helo=EUR01-VE1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hcuw2-0007q0-VA for linux-arm-kernel@lists.infradead.org; Mon, 17 Jun 2019 16:56:48 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/NluDOww/9QtED5RypDgBZ8QjDmwGLivZAqJWjCsam0=; b=mTC4ddt/iuoTJOn9P7MI1uGLYpakoEe+cfGYzfVX2kaRn80xUBtMsWUS49GjE4YWG7n5GWxqX7lZ47Akttx2hI1kJSCYe3XopCJA/NpArAkJtzv3wRERFkqNWWpgTe2kFHV7E7lFfpn22YEpvOO0jitq9eKfD35/FS4xqtPxGOE= Received: from AM5PR0801MB1763.eurprd08.prod.outlook.com (10.169.247.17) by AM5PR0801MB1699.eurprd08.prod.outlook.com (10.169.247.11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1987.11; Mon, 17 Jun 2019 16:56:39 +0000 Received: from AM5PR0801MB1763.eurprd08.prod.outlook.com ([fe80::9987:96a6:6dd9:f4a2]) by AM5PR0801MB1763.eurprd08.prod.outlook.com ([fe80::9987:96a6:6dd9:f4a2%4]) with mapi id 15.20.1987.014; Mon, 17 Jun 2019 16:56:39 +0000 From: Szabolcs Nagy To: Catalin Marinas , Andrey Konovalov Subject: Re: [PATCH v17 03/15] arm64: Introduce prctl() options to control the tagged user addresses ABI Thread-Topic: [PATCH v17 03/15] arm64: Introduce prctl() options to control the tagged user addresses ABI Thread-Index: AQHVIRQaew9kvIS1Ckaj+pLQDxCqx6af5s2AgAAyS4A= Date: Mon, 17 Jun 2019 16:56:38 +0000 Message-ID: References: <20190617135636.GC1367@arrakis.emea.arm.com> In-Reply-To: <20190617135636.GC1367@arrakis.emea.arm.com> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: user-agent: Mozilla/5.0 (X11; Linux aarch64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 x-originating-ip: [217.140.106.49] x-clientproxiedby: LO2P265CA0333.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:a4::33) To AM5PR0801MB1763.eurprd08.prod.outlook.com (2603:10a6:203:3b::17) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Szabolcs.Nagy@arm.com; x-ms-exchange-messagesentrepresentingtype: 1 x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 815c0a5d-ca3a-4da2-0285-08d6f344c3b1 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(5600148)(711020)(4605104)(1401327)(4618075)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7193020); SRVR:AM5PR0801MB1699; x-ms-traffictypediagnostic: AM5PR0801MB1699: nodisclaimer: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:9508; x-forefront-prvs: 0071BFA85B x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(39860400002)(366004)(136003)(376002)(396003)(346002)(199004)(189003)(14454004)(8936002)(305945005)(7736002)(6512007)(54906003)(36756003)(110136005)(3846002)(2906002)(64126003)(65826007)(6436002)(81166006)(7416002)(6486002)(8676002)(476003)(229853002)(486006)(446003)(71190400001)(71200400001)(11346002)(2616005)(6116002)(68736007)(44832011)(31686004)(25786009)(4326008)(81156014)(66556008)(66476007)(6246003)(66446008)(64756008)(256004)(66946007)(316002)(58126008)(31696002)(72206003)(478600001)(99286004)(102836004)(53546011)(6506007)(386003)(186003)(26005)(5660300002)(76176011)(52116002)(73956011)(86362001)(66066001)(65956001)(65806001)(53936002); DIR:OUT; SFP:1101; SCL:1; SRVR:AM5PR0801MB1699; H:AM5PR0801MB1763.eurprd08.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: arm.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: m1NHKP05ubT3GY4iHJWeLbp6cbl4CcWI0TTV1gGwSxDxMxdWYegH9gGiumLcaEXSoGIjNK67JSY4bNtoglFctVNIg6O2TyNBMqDA+0rehgsICCbSytwvDcn2g5/ql0+Sn0u6q3GwJrqtx1L0be2KFdVe1nRwglzLdlubEdZ5SIAGwHSdheTrRVEpOZLqabc8QUrJ77fhsGeW8wb6tDwdPZXrdE5J8BLZO2KYmI/DnOzU4JA/1NILAnERVbAt6HO6whub6o97OC/261TFA7+pb4EdJtvdvT6lkFZeE9ThtsDGxbx3E08YiPHxErosfDOSfs8IxTqCKPkVMZZM1kyqu3qbl+pvRvYiT88C8Jt+bIYmIrv0GA5dHasKmdpoIeo4MNrT1BqZQdaP+m3F86V+LbzQBShcAa/1bXD5fTGmyPc= Content-ID: <6EB5105BE008A9488F6CD71841425FF5@eurprd08.prod.outlook.com> MIME-Version: 1.0 X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-Network-Message-Id: 815c0a5d-ca3a-4da2-0285-08d6f344c3b1 X-MS-Exchange-CrossTenant-originalarrivaltime: 17 Jun 2019 16:56:38.9960 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: Szabolcs.Nagy@arm.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM5PR0801MB1699 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190617_095647_009561_CB028D55 X-CRM114-Status: GOOD ( 15.18 ) 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 , "kvm@vger.kernel.org" , Will Deacon , "dri-devel@lists.freedesktop.org" , "linux-mm@kvack.org" , Khalid Aziz , "linux-kselftest@vger.kernel.org" , Felix Kuehling , Vincenzo Frascino , nd , Jacob Bramley , Leon Romanovsky , "linux-rdma@vger.kernel.org" , "amd-gfx@lists.freedesktop.org" , Christoph Hellwig , Jason Gunthorpe , Dmitry Vyukov , Dave P Martin , Evgeniy Stepanov , "linux-media@vger.kernel.org" , Kevin Brodsky , Kees Cook , Ruben Ayrapetyan , Ramana Radhakrishnan , Alex Williamson , Mauro Carvalho Chehab , "linux-arm-kernel@lists.infradead.org" , Kostya Serebryany , Greg Kroah-Hartman , Yishai Hadas , "linux-kernel@vger.kernel.org" , Jens Wiklander , Lee Smith , Alexander Deucher , Andrew Morton , enh , Robin Murphy , Christian Koenig , Luc Van Oostenryck Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 17/06/2019 14:56, Catalin Marinas wrote: > On Wed, Jun 12, 2019 at 01:43:20PM +0200, Andrey Konovalov wrote: >> From: Catalin Marinas >> >> It is not desirable to relax the ABI to allow tagged user addresses into >> the kernel indiscriminately. This patch introduces a prctl() interface >> for enabling or disabling the tagged ABI with a global sysctl control >> for preventing applications from enabling the relaxed ABI (meant for >> testing user-space prctl() return error checking without reconfiguring >> the kernel). The ABI properties are inherited by threads of the same >> application and fork()'ed children but cleared on execve(). >> >> The PR_SET_TAGGED_ADDR_CTRL will be expanded in the future to handle >> MTE-specific settings like imprecise vs precise exceptions. >> >> Signed-off-by: Catalin Marinas > > A question for the user-space folk: if an application opts in to this > ABI, would you want the sigcontext.fault_address and/or siginfo.si_addr > to contain the tag? We currently clear it early in the arm64 entry.S but > we could find a way to pass it down if needed. to me it makes sense to keep the tag in si_addr / fault_address. but i don't know in detail how those fields are used currently. keeping the tag is certainly useful for MTE to debug wrong tag failures unless there is a separate mechanism for that. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel