From mboxrd@z Thu Jan 1 00:00:00 1970 From: Szabolcs Nagy Subject: Re: [PATCH v6 26/26] arm64: mte: Add Memory Tagging Extension documentation Date: Thu, 9 Jul 2020 10:32:54 +0100 Message-ID: <20200709093253.GI32219@arm.com> References: <20200703153718.16973-1-catalin.marinas@arm.com> <20200703153718.16973-27-catalin.marinas@arm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Return-path: Received: from mail-eopbgr20044.outbound.protection.outlook.com ([40.107.2.44]:35201 "EHLO EUR02-VE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726211AbgGIJdH (ORCPT ); Thu, 9 Jul 2020 05:33:07 -0400 Content-Disposition: inline In-Reply-To: <20200703153718.16973-27-catalin.marinas@arm.com> Sender: linux-arch-owner@vger.kernel.org List-ID: To: Catalin Marinas Cc: linux-arm-kernel@lists.infradead.org, linux-mm@kvack.org, linux-arch@vger.kernel.org, Will Deacon , Dave P Martin , Vincenzo Frascino , Kevin Brodsky , Andrey Konovalov , Peter Collingbourne , Andrew Morton , libc-alpha@sourceware.org, nd@arm.com The 07/03/2020 16:37, Catalin Marinas wrote: > + /* > + * To be compiled with -march=armv8.5-a+memtag > + */ > + #include > + #include > + #include > + #include > + #include > + #include > + #include the example should now include stdint.h > + #define insert_random_tag(ptr) ({ \ > + uint64_t __val; \ > + asm("irg %0, %1" : "=r" (__val) : "r" (ptr)); \ > + __val; \ > + })