From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3C0CEC4708A for ; Thu, 27 May 2021 14:54:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 128D06128D for ; Thu, 27 May 2021 14:54:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236629AbhE0O4S (ORCPT ); Thu, 27 May 2021 10:56:18 -0400 Received: from outbound-smtp37.blacknight.com ([46.22.139.220]:40209 "EHLO outbound-smtp37.blacknight.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234847AbhE0O4Q (ORCPT ); Thu, 27 May 2021 10:56:16 -0400 Received: from mail.blacknight.com (pemlinmail03.blacknight.ie [81.17.254.16]) by outbound-smtp37.blacknight.com (Postfix) with ESMTPS id F08F51EF9 for ; Thu, 27 May 2021 15:54:42 +0100 (IST) Received: (qmail 21500 invoked from network); 27 May 2021 14:54:42 -0000 Received: from unknown (HELO techsingularity.net) (mgorman@techsingularity.net@[84.203.23.168]) by 81.17.254.9 with ESMTPSA (AES256-SHA encrypted, authenticated); 27 May 2021 14:54:42 -0000 Date: Thu, 27 May 2021 15:54:41 +0100 From: Mel Gorman To: Andrii Nakryiko Cc: Andrew Morton , Christoph Hellwig , Arnaldo Carvalho de Melo , Michal Suchanek , Alexei Starovoitov , Daniel Borkmann , Martin KaFai Lau , Song Liu , Yonghong Song , John Fastabend , KP Singh , LKML , Jiri Olsa , Hritik Vijay , Linux-BPF , Linux-Net , Linux-MM Subject: Re: [PATCH v2] mm/page_alloc: Work around a pahole limitation with zero-sized struct pagesets Message-ID: <20210527145441.GE30378@techsingularity.net> References: <20210527120251.GC30378@techsingularity.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Thu, May 27, 2021 at 07:37:05AM -0700, Andrii Nakryiko wrote: > > This patch checks for older versions of pahole and only allows > > DEBUG_INFO_BTF_MODULES if pahole supports zero-sized per-cpu structures. > > DEBUG_INFO_BTF is still allowed as a KVM boot test passed with pahole > > Unfortunately this won't work. The problem is that vmlinux BTF is > corrupted, which results in module BTFs to be rejected as well, as > they depend on it. > > But vmlinux BTF corruption makes BPF subsystem completely unusable. So > even though kernel boots, nothing BPF-related works. So we'd need to > add dependency for DEBUG_INFO_BTF on pahole 1.22+. > While bpf usage would be broken, the kernel will boot and the effect should be transparent to any kernel build based on "make oldconfig". CONFIG_DEBUG_INFO_BTF defaults N so if that is forced out, it will be easily missed by a distribution kernel maintainer. Yes, users of BPF will be affected and it may generate bug reports but the fix will be to build with a working pahole. Breaking boot on the other hand is a lot more visible and hacking around this with a non-zero struct size has been shot down. -- Mel Gorman SUSE Labs