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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 24458C4707B for ; Sat, 13 Jan 2024 19:50:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ZgN2sHR4MDe88hkf4x+D0h0db304rP9f8xodE5pZEyg=; b=4fd3Gg4U5FeUx0 UPdGI+aaRWL4CaXfE5u03HerRdCPCLKOAPfhDVgOfhi+ppRrYWlzgiOtXzNF1NjB0aEM0Gg8iYnX6 6ZZyVkcSF/xTJnN7OraogSJVEa5z9ILtMdKfrnLIcd7bqxvneVPOgYOsfrrGvtfyBiC3p4Y/0r36H rEK+oDqjyy4WJrcXiQPnT5/Xmj+U5s9YI4htjr4Ut9rr0rm9HNVhvk20MxWfW7NN+9A/t3ZCd/EAF dUKb9DD0WqN9zPLusOhN7B4bWR1OXks/HZJ6G5uGkR26jd2GyjL4J5sInY6gp7UJAeaow55yZceK2 i/iY+PbQdtOJ1xHiFheQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rOk0U-005cVf-2q; Sat, 13 Jan 2024 19:49:26 +0000 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rOk0R-005cVJ-1P for linux-arm-kernel@lists.infradead.org; Sat, 13 Jan 2024 19:49:24 +0000 Received: by mail-wm1-x334.google.com with SMTP id 5b1f17b1804b1-40e636fd3d2so19852035e9.1 for ; Sat, 13 Jan 2024 11:49:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1705175357; x=1705780157; darn=lists.infradead.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:date:from:from:to:cc:subject:date:message-id:reply-to; bh=1HammmbmKVZr2MOKZbNt/I1t0w3fHw/pSzTd2SPHXwE=; b=QGvEZ9jIrzckWg6RvzdvunjgB9pDts4OfwCv5DjvYzmXV2z8CbykRFg32PKdKv+t5h DtOg68MfK+WK/ghtp5o8E+Q5QlGEtpT2OQF+EEXpSNiQXhdnqeW28iuMK0oArng6mEIx 84KkLhPGFC5PafNZFnCCkzVoh9xbyYC0Cs+TgBieDGvJfniFKEG1OxZsnwpBd4h88Sle 2ruvkmgjVz6ZI43nXKt0GZEk6VxouWrGYW37tkMsm6wx5ec9k/eZVojBIAiVU3xs1tA1 aKZZxsjr2FnkLtlwJFRex0Vvb6K8b6CP+EmmlPNN6btJWv/tSqq97sOv/jqLMekFZAPe lxPg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705175357; x=1705780157; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:date:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=1HammmbmKVZr2MOKZbNt/I1t0w3fHw/pSzTd2SPHXwE=; b=uRl6PIZJ7T3vqHya7GDU55VnDCFSeztgK9YAOlpnmCkXbmaWPGYnnlqHX+tqqe5LLh I0Zdo2yN5jA4nUegkEsBHsyqKjLRGV4DGy0oel8LCazwuiimp+zyD3lSlcUiP2GzV69D hUR3ANab7xV2Px1/Rk9fx3PmW+Bupzv109h3S9gbgC2DuznnItNvVbxeo/uFFRrGRdJx xWA5cuqfFqbZeeNaOgK4WMShTNEfI+O/7GBuyyaoiI/gj1CAz76lGG+5faJS4491ZPYT eXQLXToJ6f1T4l+fVaW1yjRsc8aOHiqa2EHa7m6lCjD15zifj7IBGmcmx05fi2Tb8gVD wf3A== X-Gm-Message-State: AOJu0YzoGVUdMInWLidZyryW4hXJ/GHfD3D3RomkBaEqoXcuzOgeIYDD 7fNBT/4wlN5KzdIzX794T4U= X-Google-Smtp-Source: AGHT+IGB6b1STgkpJhSgj3KuApjLbo2cpOqH+Lo8IF+ZLe2NNqtVVUnWy/HbRsbdtahuuLtgdZIrFQ== X-Received: by 2002:a1c:7510:0:b0:40e:50e9:9b0c with SMTP id o16-20020a1c7510000000b0040e50e99b0cmr1665802wmc.181.1705175356706; Sat, 13 Jan 2024 11:49:16 -0800 (PST) Received: from krava (ip-94-113-247-30.net.vodafone.cz. [94.113.247.30]) by smtp.gmail.com with ESMTPSA id a22-20020a05600c349600b0040d83ab2ecdsm10412099wmq.21.2024.01.13.11.49.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 13 Jan 2024 11:49:16 -0800 (PST) From: Jiri Olsa X-Google-Original-From: Jiri Olsa Date: Sat, 13 Jan 2024 20:49:14 +0100 To: Daniel Xu Cc: Jiri Olsa , linux-input@vger.kernel.org, coreteam@netfilter.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, netfilter-devel@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-trace-kernel@vger.kernel.org, fsverity@lists.linux.dev, bpf@vger.kernel.org, netdev@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, cgroups@vger.kernel.org, alexei.starovoitov@gmail.com, quentin@isovalent.com, alan.maguire@oracle.com, memxor@gmail.com Subject: Re: [PATCH bpf-next v3 0/3] Annotate kfuncs in .BTF_ids section Message-ID: References: <2dhmwvfnnqnlrui2qcr5fob54gdsuse5caievct42trvvia6qe@p24nymz3uttv> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240113_114923_492782_71D8D52C X-CRM114-Status: GOOD ( 27.64 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Sat, Jan 13, 2024 at 09:17:44AM -0700, Daniel Xu wrote: > Hi Jiri, > > On Sat, Jan 13, 2024 at 02:57:40PM +0100, Jiri Olsa wrote: > > On Fri, Jan 12, 2024 at 01:03:59PM -0700, Daniel Xu wrote: > > > On Fri, Jan 12, 2024 at 05:20:39PM +0100, Jiri Olsa wrote: > > > > On Sat, Jan 06, 2024 at 11:24:07AM -0700, Daniel Xu wrote: > > > > > === Description === > > > > > > > > > > This is a bpf-treewide change that annotates all kfuncs as such inside > > > > > .BTF_ids. This annotation eventually allows us to automatically generate > > > > > kfunc prototypes from bpftool. > > > > > > > > > > We store this metadata inside a yet-unused flags field inside struct > > > > > btf_id_set8 (thanks Kumar!). pahole will be taught where to look. > > > > > > > > > > More details about the full chain of events are available in commit 3's > > > > > description. > > > > > > > > > > The accompanying pahole changes (still needs some cleanup) can be viewed > > > > > here on this "frozen" branch [0]. > > > > > > > > so the plan is to have bpftool support to generate header file > > > > with detected kfuncs? > > > > > > Yep, that's the major use case. But I see other use cases as well like > > > > ok, any chance you could already include it in the patchset? > > would be a great way to test this.. maybe we could change > > selftests to use that > > I haven't start working on that code yet, but I can. > > Here is my plan FWIW: > > 1. Bump minimum required pahole version up. Or feature probe for > kfunc decl tag support. Whatever is the standard practice here. > > 2. Teach bpftool to dump kfunc prototypes, guarded behind a flag. > > 3. Flip bpftool flag on in selftest build and remove all manual kfunc > prototypes atomically in 1 commit. > > I thought it'd be nicer to do it incrementally given all the moving > pieces. But if we want to land it all at once that is ok by me too. I think it'd be best to try the whole thing before we merge the change to pahole.. I guess the tests changes can come later, but would be great to try the kfunc dump and make sure it works as expected jirka _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel