Linux Documentation
 help / color / mirror / Atom feed
From: Alan Maguire <alan.maguire@oracle.com>
To: Sasha Levin <sashal@kernel.org>
Cc: James.Bottomley@hansenpartnership.com, adobriyan@gmail.com,
	akpm@linux-foundation.org, alexei.starovoitov@gmail.com,
	ast@kernel.org, bp@alien8.de, bpf@vger.kernel.org,
	corbet@lwn.net, dave.hansen@linux.intel.com, davidgow@google.com,
	deller@gmx.de, geert@linux-m68k.org, gregkh@linuxfoundation.org,
	hpa@zytor.com, jgross@suse.com, jpoimboe@kernel.org,
	kees@kernel.org, laurent.pinchart@ideasonboard.com,
	linux-doc@vger.kernel.org, linux-kbuild@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-modules@vger.kernel.org,
	masahiroy@kernel.org, mcgrof@kernel.org, mingo@redhat.com,
	nathan@kernel.org, nsc@kernel.org, peterz@infradead.org,
	petr.pavlu@suse.com, pmladek@suse.com, rdunlap@infradead.org,
	rostedt@goodmis.org, tglx@kernel.org, vbabka@kernel.org,
	x86@kernel.org
Subject: Re: [RFC] btf: split core BTF parsing out of BPF subsystem into kernel/btf/
Date: Wed, 22 Apr 2026 11:44:24 +0100	[thread overview]
Message-ID: <c7a8310e-501f-48a8-8ad5-0a40d8b3836b@oracle.com> (raw)
In-Reply-To: <20260325011853.657295-1-sashal@kernel.org>

On 25/03/2026 01:18, Sasha Levin wrote:
> Move BTF type format parsing and inspection code out of the BPF
> subsystem into its own kernel/bf/ directory, separating core BTF
> functionality from BPF-specific extensions.
> 
> CONFIG_DEBUG_INFO_BTF currently depends on CONFIG_BPF_SYSCALL, which
> prevents embedded, automotive, and safety-critical environments from
> using BTF. These platforms often disable BPF for security and size
> reasons but would benefit from BTF type information for crash
> diagnostics and debugging.
> 

I had a go at a refactor in this area too, and it's pretty tricky. How about
we start with a smaller goal; making /sys/kernel/btf available to userspace
on systems without CONFIG_BPF_SYSCALL? This would just involve a small refactor 
of the BTF module-related stuff in kernel/bpf/btf.c, moving it to btf_module.c 
or similar say. No need to split out BTF parsing APIs from those actively used in 
validating BPF etc, since a non-BPF_SYSCALL system would not need to parse BTF 
in the kernel (just make it available in sysfs.

  parent reply	other threads:[~2026-04-22 10:45 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-23 16:48 [PATCH 0/2] kallsyms: show typed function parameters in oops/WARN dumps Sasha Levin
2026-03-23 16:48 ` [PATCH 1/2] kallsyms: show function parameter info " Sasha Levin
2026-03-24 15:03   ` Alexei Starovoitov
2026-03-24 16:00     ` Sasha Levin
2026-03-24 16:04       ` Alexei Starovoitov
2026-03-24 18:44         ` Sasha Levin
2026-03-25  1:18           ` [RFC] btf: split core BTF parsing out of BPF subsystem into kernel/btf/ Sasha Levin
2026-03-25  2:15             ` bot+bpf-ci
2026-04-22 10:44             ` Alan Maguire [this message]
2026-04-22 14:48               ` Alexei Starovoitov
2026-03-24 17:34       ` [PATCH 1/2] kallsyms: show function parameter info in oops/WARN dumps Alan Maguire
2026-03-24 18:51         ` Sasha Levin
2026-03-23 16:48 ` [PATCH 2/2] kallsyms: add BTF-based deep parameter rendering in oops dumps Sasha Levin
2026-03-24 15:07   ` Alexei Starovoitov
2026-03-23 18:43 ` [PATCH 0/2] kallsyms: show typed function parameters in oops/WARN dumps Alexey Dobriyan
2026-03-23 22:58   ` Sasha Levin
2026-03-23 22:50 ` Andrew Morton
2026-03-23 23:08   ` Sasha Levin
2026-03-24  8:57 ` Jiri Olsa
2026-03-24 11:39   ` Sasha Levin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c7a8310e-501f-48a8-8ad5-0a40d8b3836b@oracle.com \
    --to=alan.maguire@oracle.com \
    --cc=James.Bottomley@hansenpartnership.com \
    --cc=adobriyan@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=alexei.starovoitov@gmail.com \
    --cc=ast@kernel.org \
    --cc=bp@alien8.de \
    --cc=bpf@vger.kernel.org \
    --cc=corbet@lwn.net \
    --cc=dave.hansen@linux.intel.com \
    --cc=davidgow@google.com \
    --cc=deller@gmx.de \
    --cc=geert@linux-m68k.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=hpa@zytor.com \
    --cc=jgross@suse.com \
    --cc=jpoimboe@kernel.org \
    --cc=kees@kernel.org \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-modules@vger.kernel.org \
    --cc=masahiroy@kernel.org \
    --cc=mcgrof@kernel.org \
    --cc=mingo@redhat.com \
    --cc=nathan@kernel.org \
    --cc=nsc@kernel.org \
    --cc=peterz@infradead.org \
    --cc=petr.pavlu@suse.com \
    --cc=pmladek@suse.com \
    --cc=rdunlap@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=sashal@kernel.org \
    --cc=tglx@kernel.org \
    --cc=vbabka@kernel.org \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox