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 A98B8C4706C for ; Fri, 12 Jan 2024 16:21:17 +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=/cP2OCHiBeV1sU9PCODmK5/QwVcEQIsIJ8Z8G0WfEkE=; b=gAhwh98OMIzjFE ypTEKQFzHrDo+/jGHrDYWMwZ14xoyCXk4XXBbrZg8pGwYWtdnFDXjEHLURG8wx3eclBgLaqRL1vmb j9TarDxDNHME0mr9QzurfkIzpqpGErQCY3Twrt4SXPXVmuXSyT2LYqTSLiPGN0eS78XF5fY0iWhTI MAprvvW1HLw5y0DmdLDSn133qdzKidUVf5QVJZVEA/+bWvDy9xuxAz2aHhq45Yd7pSQDZCIAHDb+E QCJAfLg8oMGxUdTXKElWARZ1A00GHy4h2hrnkU5cywS+Oakf/oafjiz9Jsd/2fMNzVbAVul+aevur k8U1Jye1H4SGsXRgQPow==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rOKH2-003Iid-0V; Fri, 12 Jan 2024 16:20:48 +0000 Received: from mail-lj1-x22b.google.com ([2a00:1450:4864:20::22b]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rOKGz-003Ihk-2N for linux-arm-kernel@lists.infradead.org; Fri, 12 Jan 2024 16:20:47 +0000 Received: by mail-lj1-x22b.google.com with SMTP id 38308e7fff4ca-2cda523725bso1561071fa.3 for ; Fri, 12 Jan 2024 08:20:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1705076443; x=1705681243; 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=AXoDO1itquPIC9RJIHRuZv9xrGW2cJyAPsZoJpPFw+4=; b=MLQad0W3ZTWwwMAG0ER3J0DXvs/NY+zyR/nZI/ukn6PyA7+DqV7Xflt7Xz4g/zoUCp 40IhRuYqMfpRFEJQY4zdyVKXimcChJtNqr7+v2ceVEIALJLOqFP6d0ATXpIk2I2xEWjv ZgJxBgG84YtYa7LQrMCNMG0zpRKiYbBabBgI1X0FvXf8Ygb/DGP4GSGyfRrAKFnICtUn Si5hyY5VhNKEwr4axfG0QTYas5ApJPy1RpIZeeZXlJMM4SlD+eUSZknpHxv1+6dMVe0v CzXhDJLwyhkJ3H9F/MDw8sYlYCmfwppVWk8o7+kp+QE4DGHrpSWOe4MuJRNuz9jwhLbM anOw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705076443; x=1705681243; 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=AXoDO1itquPIC9RJIHRuZv9xrGW2cJyAPsZoJpPFw+4=; b=EuxHugnU49v9guJIaU5xKyZzCNKQKI5edICc4qUqD4MscF6ro7+SbrSYFfQgdGyfWo pCjOKDc4+pvsIVDM4xVGxUTdOoNEHB5mfWkuYJFl2uJ4KsfoIOCExQUyLvK3Q0MyUsfW 637k03XPpi+FdJH+nhq8r4mMeQCrq7imjQYurPZIRvtRWRnwlomwg9vQUosQGVMCApgr QeWjHDwpooZ61FySra8Uq12zVR0TKmRIFICwA+tWcuhhpE8rcZqA7kkzu5KZvV03kRMI mHL9KPqjM8IyB41SN+bUd1ahc3yNn9C9bNjxRnH2mzEUrryR6qqkfFPZOGR0zykDDJxS Ch0Q== X-Gm-Message-State: AOJu0YxgqvH3NSGkN9YKkz1ePru8roqmlLLB/HHfyvP6Uxhbw5RIdkUE hWW8xCd8Ocfk15iA1iYAPo0= X-Google-Smtp-Source: AGHT+IE54+pPKK6YhmHg0iM9e5UupkHUdB/tKeoGr8eQ2XZMM3dBdNGnw8BrNqPksBRiLQFF6ydb5Q== X-Received: by 2002:a05:6512:128d:b0:50e:7b9c:8b1a with SMTP id u13-20020a056512128d00b0050e7b9c8b1amr697559lfs.95.1705076443029; Fri, 12 Jan 2024 08:20:43 -0800 (PST) Received: from krava (ip-94-113-247-30.net.vodafone.cz. [94.113.247.30]) by smtp.gmail.com with ESMTPSA id w26-20020a17090652da00b00a1c7b20e9e6sm1931682ejn.32.2024.01.12.08.20.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Jan 2024 08:20:42 -0800 (PST) From: Jiri Olsa X-Google-Original-From: Jiri Olsa Date: Fri, 12 Jan 2024 17:20:39 +0100 To: Daniel Xu Cc: 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, olsajiri@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: 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-20240112_082045_774188_AE43AC2A X-CRM114-Status: GOOD ( 17.29 ) 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 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? jirka > > [0]: https://github.com/danobi/pahole/tree/kfunc_btf-mailed > > === Changelog === > > Changes from v2: > * Only WARN() for vmlinux kfuncs > > Changes from v1: > * Move WARN_ON() up a call level > * Also return error when kfunc set is not properly tagged > * Use BTF_KFUNCS_START/END instead of flags > * Rename BTF_SET8_KFUNC to BTF_SET8_KFUNCS > > Daniel Xu (3): > bpf: btf: Support flags for BTF_SET8 sets > bpf: btf: Add BTF_KFUNCS_START/END macro pair > bpf: treewide: Annotate BPF kfuncs in BTF > > drivers/hid/bpf/hid_bpf_dispatch.c | 8 +++---- > fs/verity/measure.c | 4 ++-- > include/linux/btf_ids.h | 21 +++++++++++++++---- > kernel/bpf/btf.c | 8 +++++++ > kernel/bpf/cpumask.c | 4 ++-- > kernel/bpf/helpers.c | 8 +++---- > kernel/bpf/map_iter.c | 4 ++-- > kernel/cgroup/rstat.c | 4 ++-- > kernel/trace/bpf_trace.c | 8 +++---- > net/bpf/test_run.c | 8 +++---- > net/core/filter.c | 16 +++++++------- > net/core/xdp.c | 4 ++-- > net/ipv4/bpf_tcp_ca.c | 4 ++-- > net/ipv4/fou_bpf.c | 4 ++-- > net/ipv4/tcp_bbr.c | 4 ++-- > net/ipv4/tcp_cubic.c | 4 ++-- > net/ipv4/tcp_dctcp.c | 4 ++-- > net/netfilter/nf_conntrack_bpf.c | 4 ++-- > net/netfilter/nf_nat_bpf.c | 4 ++-- > net/xfrm/xfrm_interface_bpf.c | 4 ++-- > net/xfrm/xfrm_state_bpf.c | 4 ++-- > .../selftests/bpf/bpf_testmod/bpf_testmod.c | 8 +++---- > 22 files changed, 81 insertions(+), 60 deletions(-) > > -- > 2.42.1 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel