Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1377914pxj; Fri, 21 May 2021 12:42:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyIEzGqw8a87KBtGnzoIuuoBw8bUY9blQJ4O7tD6CElRdYlRMbjLmFzbeKskEmda5hPyvIM X-Received: by 2002:a6b:f808:: with SMTP id o8mr452810ioh.140.1621626151389; Fri, 21 May 2021 12:42:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621626151; cv=none; d=google.com; s=arc-20160816; b=zZmM+XwGrkXBYOwRsbnI3ALDp+v3cMz6S3QLFMcqzBZ0X/QkqfX5a+ePFIpJXju3Kj 2whLrOPsHdN7AL9g+C0aRNHAUM0vLxp4HGHK4CWAgf0j/vwYq2Jqmevn1iTXNwN7u+Lp cNL6nepfoJRzJRM0lOAoPXG58QsiQnzKwA/Nt98KNH32HlCh3D+kdOom13G1alfI8jJk 19aM78YOJ+nNa3kjim1WxatNb/kfIvlg6+KDjoNmbErcetknEj4j/1uYsqYkP+0TNr6Y I3Echl4pmImO/zzktgctbgqRJVFgvQmUI7PpP7aHX1LGL1qoc3ZIW6eHdzB/AUf1U+2B vHug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:references:cc :to:from:subject:ironport-sdr:ironport-sdr; bh=5A29EQr/1WLWY4RkT/mRjQy9VCW/MrlDbyxTMUuBkyo=; b=LFnWOg3luxDr1cr20Jdcf1tJUYKo45MsFppaz5d3apraslTbxbybnPdqA2blY8hDy8 ysZwOqN4ukdDyyx7m38Qf1NLtfSLsygS8ZQ6JceGsQJwfMKvK1VKpeVBguPTGik7vgGk WZUF7m/8C57tcZ/8EzEogcEWl1FYs4gqjZhOiO0Tvk9mUXb8ZUKIeLueq62toeS4Cz7H p9Q6ZW6nXWjzj/9fLEZcQK9ipJ7kbl05R3JYhg5rKjdKQBMqpo7eSFLUt4OeOoXCLPq1 VnGax+ij7SZvFA4T2UWA/PbgO7elhDkQzsVaQUH2bK7367871+WaHvQJHsDxx+zR4d+z OLMQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y16si6853954jad.62.2021.05.21.12.42.18; Fri, 21 May 2021 12:42:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229917AbhETVIA (ORCPT + 99 others); Thu, 20 May 2021 17:08:00 -0400 Received: from mga06.intel.com ([134.134.136.31]:40169 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229708AbhETVIA (ORCPT ); Thu, 20 May 2021 17:08:00 -0400 IronPort-SDR: 0Xk6l6xI8sJdlbl0Zki2xb30mFugzrV6bzBMElrpGkJzG04nArOeqMyBn746trLzQ3LYDkos0l DAUV8LtdEHIQ== X-IronPort-AV: E=McAfee;i="6200,9189,9990"; a="262560467" X-IronPort-AV: E=Sophos;i="5.82,313,1613462400"; d="scan'208";a="262560467" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 May 2021 14:06:37 -0700 IronPort-SDR: 1LaHlQbEIAaulARfd6pepuB9A1uuFmz3hYPtGsneBv9e13fT63+Y8VTImuWAG69kBQg6/JNBWa M/5pNrvRTOCw== X-IronPort-AV: E=Sophos;i="5.82,313,1613462400"; d="scan'208";a="440623013" Received: from yyu32-mobl1.amr.corp.intel.com (HELO [10.209.167.234]) ([10.209.167.234]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 May 2021 14:06:34 -0700 Subject: Re: [PATCH v26 26/30] ELF: Introduce arch_setup_elf_property() From: "Yu, Yu-cheng" To: Matthew Wilcox Cc: Borislav Petkov , x86@kernel.org, "H. Peter Anvin" , Thomas Gleixner , Ingo Molnar , linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux-mm@kvack.org, linux-arch@vger.kernel.org, linux-api@vger.kernel.org, Arnd Bergmann , Andy Lutomirski , Balbir Singh , Cyrill Gorcunov , Dave Hansen , Eugene Syromiatnikov , Florian Weimer , "H.J. Lu" , Jann Horn , Jonathan Corbet , Kees Cook , Mike Kravetz , Nadav Amit , Oleg Nesterov , Pavel Machek , Peter Zijlstra , Randy Dunlap , "Ravi V. Shankar" , Vedvyas Shanbhogue , Dave Martin , Weijiang Yang , Pengfei Xu , Haitao Huang , Mark Brown , Catalin Marinas References: <20210427204315.24153-1-yu-cheng.yu@intel.com> <20210427204315.24153-27-yu-cheng.yu@intel.com> <89be0683-e1b3-d843-c4b4-ba351ede7427@intel.com> Message-ID: <3edd6ac7-4aa2-5f09-245a-3e5cf4bb06aa@intel.com> Date: Thu, 20 May 2021 14:06:30 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.10.2 MIME-Version: 1.0 In-Reply-To: <89be0683-e1b3-d843-c4b4-ba351ede7427@intel.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/20/2021 10:52 AM, Yu, Yu-cheng wrote: > On 5/20/2021 10:38 AM, Matthew Wilcox wrote: >> On Wed, May 19, 2021 at 03:14:58PM -0700, Yu, Yu-cheng wrote: >>>>> +++ b/include/uapi/linux/elf.h >>>>> @@ -455,4 +455,13 @@ typedef struct elf64_note { >>>>>    /* Bits for GNU_PROPERTY_AARCH64_FEATURE_1_BTI */ >>>>>    #define GNU_PROPERTY_AARCH64_FEATURE_1_BTI    (1U << 0) >>>>> +/* .note.gnu.property types for x86: */ >>>>> +#define GNU_PROPERTY_X86_FEATURE_1_AND        0xc0000002 >>>> >>>> Why not 0xc0000001? ARM64 is 0xc0000000... >>>> >>> >>> I just looked at the ABI document. >>> >>> ARM has GNU_PROPERTY_AARCH64_FEATURE_1_AND 0xc0000000 >>> >>> X86 has: >>>     GNU_PROPERTY_X86_ISA_1_USED    0xc0000000 >>>     GNU_PROPERTY_X86_ISA_1_NEEDED    0xc0000001 >>>     GNU_PROPERTY_X86_FEATURE_1_AND    0xc0000002 >> >> Please add all three, not just the last one. >> > > Ok! Just found out, I have been reading an older version. Now 0xc0000000 and 0xc0000001 have become reserved/not-used. Maybe I will just put a note about that along with the link to the ABI document. Yu-cheng