From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 63995 invoked by alias); 19 Jun 2018 20:38:58 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 63967 invoked by uid 89); 19 Jun 2018 20:38:57 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mx0b-00082601.pphosted.com Subject: Re: [PATCH] elf.h: Add BPF relocation types. To: Mark Wielaard , Florian Weimer , CC: Richard Henderson References: <20180616214515.10737-1-mark@klomp.org> <1529440472.12946.129.camel@klomp.org> From: Yonghong Song Message-ID: Date: Tue, 19 Jun 2018 20:38:00 -0000 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 MIME-Version: 1.0 In-Reply-To: <1529440472.12946.129.camel@klomp.org> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: MWHPR02CA0041.namprd02.prod.outlook.com (2603:10b6:301:60::30) To BY1PR15MB0070.namprd15.prod.outlook.com (2a01:111:e400:507c::23) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 8612f994-4312-4c73-6776-08d5d624a875 X-MS-TrafficTypeDiagnostic: BY1PR15MB0070: X-Exchange-Antispam-Report-Test: UriScan:(10436049006162)(166708455590820)(5213294742642); X-MS-Exchange-SenderADCheck: 1 X-Forefront-PRVS: 07083FF734 Received-SPF: None (protection.outlook.com: fb.com does not designate permitted sender hosts) SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Jun 2018 20:38:47.2873 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 8612f994-4312-4c73-6776-08d5d624a875 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 8ae927fe-1255-47a7-a2af-5f3a069daaa2 X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR15MB0070 X-OriginatorOrg: fb.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-06-19_10:,, signatures=0 X-Proofpoint-Spam-Reason: safe X-FB-Internal: Safe X-SW-Source: 2018-06/txt/msg00572.txt.bz2 On 6/19/18 1:34 PM, Mark Wielaard wrote: > On Tue, 2018-06-19 at 22:06 +0200, Florian Weimer wrote: >> On 06/16/2018 11:45 PM, Mark Wielaard wrote: >>> The BPF ELF format has new relocation types R_BPF_64_64 and R_BPF_64_32. >>> The existing R_BPF_MAP_FD was an extension that never got implemented. >>> Remove it, because its constant conflicts with the official R_BPF_64_64. >> >> Is there an ABI manual against which we could review this change? >> >> The last change said that this was added to the Generic ABI >>> , but there is >> no evidence of that. > > Only the EM values are, since they are generic. > It just takes a while before they make it to the public website. > rth has an email from the maintainer though with the assigned value. > > The relocation constants don't have a separate ABI manual > (because BPF isn't really a full blown architecture/abi). > Those are kept in sync between the projects handling BPF elf files > (which is this patch, which is a prerequisite for getting the same > constants into elfutils, because we see the glibc elf.h as the > master copy that holds all GNU/Linux ELF constants.) The LLVM source code for the definition is here: https://github.com/llvm-mirror/llvm/blob/master/include/llvm/BinaryFormat/ELFRelocs/BPF.def Yes, BPF related documentation has been lacking. For example, the support in binutils is not there yet. But we are starting to work on it. Thanks! Yonghong > > Thanks, > > Mark >