Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp1694620ybh; Sun, 15 Mar 2020 08:49:16 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuyQEdXh/LSXNnvEvp+J0ooKmH9RCQeAB4Ln0kbc/yoVk1Qpb0ZbAnBUI+a07uxuoaoo/jN X-Received: by 2002:a9d:65ca:: with SMTP id z10mr17948420oth.244.1584287356460; Sun, 15 Mar 2020 08:49:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584287356; cv=none; d=google.com; s=arc-20160816; b=ZX61G0JOwEvNILikIakHGF5s0n1nxt1uuYtNFXGzcAj5sNwBPHcUiJ80/76n+fG8Zh TnbZ3jfhJg12NsEb71fe1rH8JYCim8W5PtJhOKUDA/LxDGEaRw2oYQgLDhTcGWF8/rMY ozFgJKzVSx4f48kRJ0hOQbiB0F89QitIZa0Am4HWiTPTNyP9ATkKAaG9s0fEnN487pNr P/bARLaEBVtyfRsbI7AQEyw75KDh4g31JB+Yb4alvHfjMuZL6SyUzpFmDLHGKbTqji5w TMsgDaIRFoRuiSRHj7ZrjZfGfiR6UPY1JXxVeeW5k/sWnDWTC7Hjyf++H/tScfFGKv1A qIrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=Bie5CPQtCgzry/0WDpDIJAhXG0M76l/FmCw1sQZPC+0=; b=F24+/0hhBBZPqHapk9YcEjjT5nwAhEQOUcSC6JenuPgvKXdchbwiL2pnB4M7mOW+S+ AYq3BHjnWk8NyYMMHGPaEcXdYtAgOD7rXTaIrN/FxG7EYDKXbSiEKlaU1ScD5GzshBfm U0O0DhUzoXwL2obuDeiiQt7Qp7ANUYARDQtX9jB9Ij4umrXBRbxMexkknM6KCwVrx+Tf 54GxyAho7Dl7kYzh7PaNEX1ElrlTKRFtyF+nPbPlad8TRHZZ5v4EJw+77rUoLftBgl2F oqxc1WkYnJgFGvAHsXl7PKhOfyqdf/PZT54POT65Vd54qaKMeXfTy14KYpiPd8fzACsd 2cIA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=HYjleVWD; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y16si1974305oie.225.2020.03.15.08.48.50; Sun, 15 Mar 2020 08:49:16 -0700 (PDT) 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=pass header.i=@redhat.com header.s=mimecast20190719 header.b=HYjleVWD; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728825AbgCOPpR (ORCPT + 99 others); Sun, 15 Mar 2020 11:45:17 -0400 Received: from us-smtp-2.mimecast.com ([205.139.110.61]:29786 "EHLO us-smtp-delivery-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728535AbgCOPpR (ORCPT ); Sun, 15 Mar 2020 11:45:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1584287115; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Bie5CPQtCgzry/0WDpDIJAhXG0M76l/FmCw1sQZPC+0=; b=HYjleVWDDl3QMgJ1I0tnZ3rQG9QTwgzFNGbouBtdWFs1zPajtjou3mW/ftahESagPPgfT5 Qgg28tFFI7tXeyu8c6alASAWEbAw3eN4PToixszso9f8ZTB2XwYyvHvjQrlG/fIqJAbU0s AGFbSMXlqWGE00wxkQL+cEfptCJJm6Y= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-450-PMK0aUfPNQ-KG0iHGBCKKw-1; Sun, 15 Mar 2020 11:45:12 -0400 X-MC-Unique: PMK0aUfPNQ-KG0iHGBCKKw-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 21A6A800D4E; Sun, 15 Mar 2020 15:45:11 +0000 (UTC) Received: from treble (ovpn-120-135.rdu2.redhat.com [10.10.120.135]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 65C3889F1C; Sun, 15 Mar 2020 15:45:10 +0000 (UTC) Date: Sun, 15 Mar 2020 10:45:08 -0500 From: Josh Poimboeuf To: Peter Zijlstra Cc: tglx@linutronix.de, linux-kernel@vger.kernel.org, x86@kernel.org Subject: Re: [RFC][PATCH 04/16] objtool: Annotate identity_mapped() Message-ID: <20200315154508.m4b6ttdp3hb7pfla@treble> References: <20200312134107.700205216@infradead.org> <20200312135041.641079164@infradead.org> <20200313143429.GB12521@hirez.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20200313143429.GB12521@hirez.programming.kicks-ass.net> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 13, 2020 at 03:34:29PM +0100, Peter Zijlstra wrote: > This conflicts with: > > 7acfe5315312 ("objtool: Improve call destination function detection") > > which wasn't in the tree we were working against :/ > > I've resolved it something like so. > > --- > --- a/tools/objtool/check.c > +++ b/tools/objtool/check.c > @@ -406,7 +406,7 @@ static void add_ignores(struct objtool_f > { > struct instruction *insn; > struct section *sec; > - struct symbol *func; > + struct symbol *sym; > struct rela *rela; > > sec = find_section_by_name(file->elf, ".rela.discard.func_stack_frame_non_standard"); > @@ -416,12 +416,12 @@ static void add_ignores(struct objtool_f > list_for_each_entry(rela, &sec->rela_list, list) { > switch (rela->sym->type) { > case STT_FUNC: > - func = rela->sym; > + sym = rela->sym; > break; > > case STT_SECTION: > - func = find_func_by_offset(rela->sym->sec, rela->addend); > - if (!func) > + sym = find_symbol_by_offset(rela->sym->sec, rela->addend); > + if (!sym || (sym->type != STT_FUNC || sym->type != STT_NOTYPE)) ^^ && -- Josh