Received: by 2002:a05:6a10:a852:0:0:0:0 with SMTP id d18csp2888613pxy; Mon, 3 May 2021 10:13:09 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxsQEsw3WirVPamX5Fw3Eol3ElyhCN7C1fs1HZOmtsLmmycYNJfeF5I1Xf2IoqxYWvoysYH X-Received: by 2002:aa7:c3c2:: with SMTP id l2mr21669191edr.41.1620061988979; Mon, 03 May 2021 10:13:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620061988; cv=none; d=google.com; s=arc-20160816; b=tD/DtYNIA7PkdNwQGSuOUKYS17hroFyE+F8fe1WT8XRijwasqidhuQdbTlj1uO9wjO 5DChzTlzoiU2ey46UV0P06QUoAU3+TWd93N3o4tqoqY7di5t9tMWPlaBoljKOOJiWrE5 9cRyF9cdhEX5mlIq0ejL0dwtjMGxtCG/05FomVbIZBJ3SIiyd2We3NYqcyQw0Mspll1J b/3jfH5t5UnssCuJV9IMxBrAT3oRFqoPVId8vocybK6OLdXBw7YTp3DpAjr6Jyzs5UbY iaD4g6+Ub/eqPVsBi1GOW+ALGmQSBV2WkRILUiGVaTxb3DQB8lP+yZUM5umVTaqLZfTO 1oRg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=wM98VfnTTVcLAElKoYzYq995tjaZTIzIxDhMpn4EpAg=; b=dpe6fFiN/DNmUuc/Djxo4E1PJI5nOvSHOzxAWqqO4KBkxX90UVZtbbhza6Cw48kj4G XgVQczJF5EcknYgvGhbHifb1Se8Rgws1zJRZ5IX1BS+cI4I2ahbNUK2yZ5FfRo/QLydw Hyuob8hPRd1c9ZtMhpFIuEdx5KOR1IA3BwDXMB/sH+gwPIv3X/SppXRUUEtCAjLFtsVe bTqZkl4WPteOhVeWD+LLYFKZls+2GTqTX91wz6ElR4Rvpp8xmNw/jsr3Ci4I6vT7Y4au z9FztwW4Cau9xw8t8fce8Zy7tdzZbHPHk15lWmJIxMCovog9JMb6czkKLCB8A8tBqDLh YJIw== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s6si288059ejc.744.2021.05.03.10.12.43; Mon, 03 May 2021 10:13:08 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237043AbhECRHv (ORCPT + 99 others); Mon, 3 May 2021 13:07:51 -0400 Received: from mx2.suse.de ([195.135.220.15]:46994 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234825AbhECQ72 (ORCPT ); Mon, 3 May 2021 12:59:28 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 7A1B4AEA3; Mon, 3 May 2021 16:58:33 +0000 (UTC) Date: Mon, 3 May 2021 18:58:31 +0200 From: Michal =?iso-8859-1?Q?Such=E1nek?= To: Jiri Olsa Cc: Jiri Slaby , Yonghong Song , linux-kernel@vger.kernel.org, Martin KaFai Lau , "David S. Miller" , Hideaki YOSHIFUJI , David Ahern , Jakub Kicinski , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Song Liu , John Fastabend , KP Singh , netdev@vger.kernel.org, bpf@vger.kernel.org, Jiri Olsa , Jesper Dangaard Brouer , dwarves@vger.kernel.org, Arnaldo Carvalho de Melo Subject: Re: linux-next failing build due to missing cubictcp_state symbol Message-ID: <20210503165831.GR15381@kitsune.suse.cz> References: <20210427121237.GK6564@kitsune.suse.cz> <20210430174723.GP15381@kitsune.suse.cz> <3d148516-0472-8f0a-085b-94d68c5cc0d5@suse.com> <6c14f3c8-7474-9f3f-b4a6-2966cb19e1ed@kernel.org> <4e051459-8532-7b61-c815-f3435767f8a0@kernel.org> <20210503164656.GO6564@kitsune.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20210503164656.GO6564@kitsune.suse.cz> User-Agent: Mutt/1.11.3 (2019-02-01) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 03, 2021 at 06:46:56PM +0200, Michal Such?nek wrote: > On Mon, May 03, 2021 at 12:08:02PM +0200, Jiri Olsa wrote: > > On Mon, May 03, 2021 at 10:59:44AM +0200, Jiri Slaby wrote: > > > CCing pahole people. > > > > > > On 03. 05. 21, 9:59, Jiri Slaby wrote: > > > > On 03. 05. 21, 8:11, Jiri Slaby wrote: > > > > > > > > > > looks like vfs_truncate did not get into BTF data, > > > > > > > > > > I'll try to reproduce > > > > > > > > > > > > _None_ of the functions are generated by pahole -J from > > > > > > debuginfo on ppc64. debuginfo appears to be correct. Neither > > > > > > pahole -J fs/open.o works correctly. collect_functions in > > > > > > dwarves seems to be defunct on ppc64... "functions" array is > > > > > > bogus (so find_function -- the bsearch -- fails). > > > > > > > > > > It's not that bogus. I forgot an asterisk: > > > > > > #0? find_function (btfe=0x100269f80, name=0x10024631c > > > > > > "stream_open") at > > > > > > /usr/src/debug/dwarves-1.21-1.1.ppc64/btf_encoder.c:350 > > > > > > (gdb) p (*functions)@84 > > > > > > $5 = {{name = 0x7ffff68e0922 ".__se_compat_sys_ftruncate", addr > > > > > > = 75232, size = 72, sh_addr = 65536, generated = false}, { > > > > > > ??? name = 0x7ffff68e019e ".__se_compat_sys_open", addr = 80592, > > > > > > size = 216, sh_addr = 65536, generated = false}, { > > > > > > ??? name = 0x7ffff68e0076 ".__se_compat_sys_openat", addr = > > > > > > 80816, size = 232, sh_addr = 65536, generated = false}, { > > > > > > ??? name = 0x7ffff68e0908 ".__se_compat_sys_truncate", addr = > > > > > > 74304, size = 100, sh_addr = 65536, generated = false}, { > > > > > ... > > > > > > ??? name = 0x7ffff68e0808 ".stream_open", addr = 65824, size = > > > > > > 72, sh_addr = 65536, generated = false}, { > > > > > ... > > > > > > ??? name = 0x7ffff68e0751 ".vfs_truncate", addr = 73392, size = > > > > > > 544, sh_addr = 65536, generated = false}} > > > > > > > > > > The dot makes the difference, of course. The question is why is it > > > > > there? I keep looking into it. Only if someone has an immediate > > > > > idea... > > > > > > > > Well, .vfs_truncate is in .text (and contains an ._mcount call). And > > > > vfs_truncate is in .opd (w/o an ._mcount call). Since setup_functions > > > > excludes all functions without the ._mcount call, is_ftrace_func later > > > > returns false for such functions and they are filtered before the BTF > > > > processing. > > > > > > > > Technically, get_vmlinux_addrs looks at a list of functions between > > > > __start_mcount_loc and __stop_mcount_loc and considers only the listed. > > > > > > > > I don't know what the correct fix is (exclude .opd functions from the > > > > filter?). Neither why cross compiler doesn't fail, nor why ebi v2 avoids > > > > this too. > > > > > > Attaching a patch for pahole which fixes the issue, but I have no idea > > > whether it is the right fix at all. > > > > hi, > > we're considering to disable ftrace filter completely, > > I guess that would solve this issue for ppc as well > > > > https://lore.kernel.org/bpf/20210501001653.x3b4rk4vk4iqv3n7@kafai-mbp.dhcp.thefacebook.com/ > > > Just disabling the ftrace filter in pahole does not seem to fix it. > > Is there some other place where it should be disabled? Nevermind, purging the system dwarves resolved the problem. Although kbuild detects pahole as /usr/local/bin/pahole the system binaries or libraries are still used for something. Thanks Michal