Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp4586527ybl; Mon, 13 Jan 2020 16:36:35 -0800 (PST) X-Google-Smtp-Source: APXvYqxOaSYWQBNAYvnzAfmCg95UrJEh38P8tUGdj95sQJm+antPwoV9q6gC0Tlrw7SBeP76axWL X-Received: by 2002:aca:d4c1:: with SMTP id l184mr15153388oig.172.1578962195345; Mon, 13 Jan 2020 16:36:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1578962195; cv=none; d=google.com; s=arc-20160816; b=weTBl319BtjSvD1BkoofsVCkkuUAqIiCb+ZwxMC3YOnZqzy9z2+k7itaRC0mIE8dli 4exivvVvCLHjKHTisgBv37c8c72o8rEc8zs4R1PHhcMF7bW40kE4SlBebKCWW/ulp+4L mlx7ZIqTuKBxsFi1j4bHtHjRz1Ny8BKtgpSo7tfiQUfoDj6PkF6uryod6jnDYdTPSoKQ qF1JB+/kB8wgNjwSS4RYwObgn6V/cGpHa8iq8qaixFJo7OnC5aApLtIe91StfFKvCHGM 9saK8dPV7YPQPoCWppnLeCsnuKZBuSE3HtrBFXA7sesYNu/OwvAq2llrmqIWH1ahxMag c/yQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:date:from:dkim-signature; bh=SvvC5/J9xQahIMTC+riQHl1QpQjv6jCMZ1dJFy4P8xc=; b=x4+1f5/6enw2C7Q/D2SyS17L2wkLFX09dvh4G6IBlQ5jNFjDuQ5K5t9oKaMDpWI5Db eUaM661NACPhqR2Nru7ov5A4eywXXP9KJj0m6emuIhsCpwQ7dJrG8eHmGkiErhCCkoCG V/rOqKypJaZ4O+0KFDzB9uwFxOwq71LblKsXRYDge5iYTvUTi/JJDhIKdgTc+uwFZ5Aj I+OBLgdOgRTXJuv0JR0/JulxeX6kZW2Sd0u6DVNcpNzrioGOKaq2NdWalICmTqyRWLil Aw7MK18X1RzFmn85VW2sShBGLSy95yaqzr/OfxtmbxLLg6RSPX+wvvmZC/C8ePjNMyHM cf1w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=aeXyjC0I; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p22si7359348ota.43.2020.01.13.16.36.23; Mon, 13 Jan 2020 16:36:35 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=aeXyjC0I; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729075AbgAMXid (ORCPT + 99 others); Mon, 13 Jan 2020 18:38:33 -0500 Received: from mail-qv1-f68.google.com ([209.85.219.68]:40086 "EHLO mail-qv1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728769AbgAMXid (ORCPT ); Mon, 13 Jan 2020 18:38:33 -0500 Received: by mail-qv1-f68.google.com with SMTP id dp13so4861683qvb.7 for ; Mon, 13 Jan 2020 15:38:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:date:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=SvvC5/J9xQahIMTC+riQHl1QpQjv6jCMZ1dJFy4P8xc=; b=aeXyjC0ISSVaDLyhH85V9ZPYGGZPEqTz8eY1Dz43DjlN87H8nj0a4L5BNcgHVv/heK Wg2N5oQdR33gnkKZ6e6Vfh4XN3oWcWqkOdHY3/B6m7FGU3XrhuXI1WSRLT+vskX1pt1M ozCoPlqlfLpENW0sgK+T96RNUAjr3xw6g2YvagIonnj5ATDumoxXQD57mF40wC1mRfQm Vb7Lm/DTILuCHjShFl4S1bkcpwmkt+1qguCJJpIYF8ZdEDWeQQbHWTkJKnvnUD0G3/ha eSJgRHitVq46jhXbjhXDE0rgY8zn3NvMlfw8KKfroBHp21NiudWdq6JuearcbfQH8WM6 3hKQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:date:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=SvvC5/J9xQahIMTC+riQHl1QpQjv6jCMZ1dJFy4P8xc=; b=fCLsAn05jDAyZyrVqsJFLHkLW4r3lt927NODB2m+Le8DKOwxoPFm2UOhcqKJO4beYK CQwbRAqMmnjKe5j7FpTB1NQvtDjSMPWmtz/8mm7qZAy+ezGwS3U0POf1dstBhja2yiqH JZ4rsroBlajwfWETwg+JuJFf5I1K61tc4cjKNxCwkTBqQlalbNWI3Rzg33x1E+0HX4i3 lRO8IYE54nljRTgXBtrHdAb6rECnVXqLLHJleke2JFR32Ua7JbLNgQNYABf4ov0PqSde vdOPm0n03gH2sxirR7b0Ls2wF3LaJPRfRPlYO93q6WK2BFRFY/Fu7j8DE0LVaypog5xK Q4mA== X-Gm-Message-State: APjAAAWoXJiBGg+Ot+l7zKf9elVmVtflcNZOeHjiyEQujK3DSfZnKn/3 6nKUIy4wHq0Q61uSUG6d5U0= X-Received: by 2002:a05:6214:3e7:: with SMTP id cf7mr13990133qvb.129.1578958712235; Mon, 13 Jan 2020 15:38:32 -0800 (PST) Received: from rani.riverdale.lan ([2001:470:1f07:5f3::b55f]) by smtp.gmail.com with ESMTPSA id k22sm5828768qkg.80.2020.01.13.15.38.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2020 15:38:32 -0800 (PST) From: Arvind Sankar X-Google-Original-From: Arvind Sankar Date: Mon, 13 Jan 2020 18:38:29 -0500 To: Borislav Petkov Cc: Arvind Sankar , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , x86@kernel.org, linux-kernel@vger.kernel.org, Kees Cook , Thomas Lendacky Subject: Re: [PATCH] x86/tools/relocs: Add _etext and __end_of_kernel_reserve to S_REL Message-ID: <20200113233829.GB2000869@rani.riverdale.lan> References: <20200110202349.1881840-1-nivedita@alum.mit.edu> <20200110203828.GK19453@zn.tnic> <20200110205028.GA2012059@rani.riverdale.lan> <20200111130243.GA23583@zn.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20200111130243.GA23583@zn.tnic> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Jan 11, 2020 at 02:02:43PM +0100, Borislav Petkov wrote: > On Fri, Jan 10, 2020 at 03:50:29PM -0500, Arvind Sankar wrote: > > On Fri, Jan 10, 2020 at 09:38:28PM +0100, Borislav Petkov wrote: > > > On Fri, Jan 10, 2020 at 03:23:49PM -0500, Arvind Sankar wrote: > > > > Pre-2.23 binutils makes symbols defined outside sections absolute, so > > > > these two symbols break the build on old linkers. > > > > > > -ENOTENOUGHINFO > > > > > > Which old linkers, how exactly do they break the build, etc etc? > > > > > > Please give exact reproduction steps. > > > > > > Thx. > > > > > > > binutils-2.21 and -2.22. An x86-64 defconfig will fail with > > Invalid absolute R_X86_64_32S relocation: _etext > > and after fixing that one, with > > Invalid absolute R_X86_64_32S relocation: __end_of_kernel_reserve > > I'm still not clear as to why this happens. I tried reproducing on > openSUSE 12.1 which has > > Repository: openSUSE-12.1-Oss > Name: binutils > Version: 2.21.1-12.1.4 > > and the build there fails with: > > objdump: arch/x86/lib/clear_page_64.o: File format not recognized > objdump: arch/x86/lib/cmdline.o: File format not recognized > objdump: arch/x86/lib/cmpxchg16b_emu.o: File format not recognized > objdump: arch/x86/lib/copy_page_64.o: File format not recognized > objdump: arch/x86/lib/copy_user_64.o: File format not recognized > objdump: arch/x86/lib/cpu.o: File format not recognized > ... > > and objdump is part of binutils. > > Now, this looks like another symptom of what you're reporting but what > we're missing is the rootcause about *why* this happens. I tried out OpenSUSE 12.1 in a VM, and this one seems to be related to something that changes in the build when libelf-devel is installed. Deleting that package and switching UNWINDER_ORC (which says it requires libelf-devel) to UNWINDER_FRAME_POINTER builds without the file format errors. > > Because if the issue is hard to fix or similar, then we probably should > raise the minimum supported binutils version from 2.21 to something > newer and not do this fix. > > But before we do that, we need a proper analysis as to why it happens. > > Also, what distro are you using to reproduce it on? > > Thx. > > -- > Regards/Gruss, > Boris. > > https://people.kernel.org/tglx/notes-about-netiquette