From nobody Tue Apr 14 15:58:11 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D922FC19F2B for ; Tue, 2 Aug 2022 20:11:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234373AbiHBULf (ORCPT ); Tue, 2 Aug 2022 16:11:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53936 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234071AbiHBULc (ORCPT ); Tue, 2 Aug 2022 16:11:32 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A5F1C14D1C; Tue, 2 Aug 2022 13:11:31 -0700 (PDT) Date: Tue, 02 Aug 2022 20:11:29 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1659471090; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=SATzoMBj9sEgF2bNHztIfGVAPHICwvpaJN0/DnFssCE=; b=0WnbN0rCWBUNLiRsDbdtB5rxJmUqdiPD4O3srcqQi0Xfx4RSr4JjXO9LQ8e0UtXASh9tjb /PkbnNmPuDXt+r6S+wBwOY3RtSp/J2g+CUO388gwZur/Q0r4c9GHBfmczONCbNALD4+/J5 xaYpJGirRSD/k1GGtaPlvvQyaPsAAWOGWyX5eqgJBXWUo8y4eWOrftsTC0YhjqJLuY+CYA dlptixOnXnaPWAuq7X7rviS1qoCQhp2gZRZRqJ+Zvj3gFHZboMgjrB5VuThdxKGLLSjuDi bWX2BR2/LJlPNLB25B0OUbEi59bSxStuWkVLi/BjNgiDwb4sRbukhhC51rZP5A== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1659471090; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=SATzoMBj9sEgF2bNHztIfGVAPHICwvpaJN0/DnFssCE=; b=H6466TLXs9t1PVXst4R+I9kB9HZUbhYULlnm4Rig0JEZ7ElNDEDVZxXO8q/4fHiKiV5c1X UivLrFOw3xVXgMBg== From: "tip-bot2 for Josh Poimboeuf" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: perf/urgent] scripts/faddr2line: Fix vmlinux detection on arm64 Cc: John Garry , Josh Poimboeuf , Ingo Molnar , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: References: MIME-Version: 1.0 Message-ID: <165947108915.15455.153331710686410.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the perf/urgent branch of tip: Commit-ID: b6a5068854cfe372da7dee3224dcf023ed5b00cb Gitweb: https://git.kernel.org/tip/b6a5068854cfe372da7dee3224dcf023e= d5b00cb Author: Josh Poimboeuf AuthorDate: Thu, 21 Jul 2022 11:01:23 -07:00 Committer: Ingo Molnar CommitterDate: Tue, 02 Aug 2022 22:08:16 +02:00 scripts/faddr2line: Fix vmlinux detection on arm64 Since commit dcea997beed6 ("faddr2line: Fix overlapping text section failures, the sequel"), faddr2line is completely broken on arm64. For some reason, on arm64, the vmlinux ELF object file type is ET_DYN rather than ET_EXEC. Check for both when determining whether the object is vmlinux. Modules and vmlinux.o have type ET_REL on all arches. Fixes: dcea997beed6 ("faddr2line: Fix overlapping text section failures, th= e sequel") Reported-by: John Garry Signed-off-by: Josh Poimboeuf Signed-off-by: Ingo Molnar Tested-by: John Garry Link: https://lore.kernel.org/r/dad1999737471b06d6188ce4cdb11329aa41682c.16= 58426357.git.jpoimboe@kernel.org --- scripts/faddr2line | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/faddr2line b/scripts/faddr2line index 94ed98d..5709968 100755 --- a/scripts/faddr2line +++ b/scripts/faddr2line @@ -112,7 +112,9 @@ __faddr2line() { # section offsets. local file_type=3D$(${READELF} --file-header $objfile | ${AWK} '$1 =3D=3D "Type:" { print $2; exit }') - [[ $file_type =3D "EXEC" ]] && is_vmlinux=3D1 + if [[ $file_type =3D "EXEC" ]] || [[ $file_type =3D=3D "DYN" ]]; then + is_vmlinux=3D1 + fi =20 # Go through each of the object's symbols which match the func name. # In rare cases there might be duplicates, in which case we print all