public inbox for live-patching@vger.kernel.org
 help / color / mirror / Atom feed
From: Miroslav Benes <mbenes@suse.cz>
To: Song Liu <song@kernel.org>
Cc: live-patching@vger.kernel.org, linux-kernel@vger.kernel.org,
	 jpoimboe@kernel.org, jikos@kernel.org, pmladek@suse.com,
	 joe.lawrence@redhat.com, laoar.shao@gmail.com,
	kernel-team@meta.com
Subject: Re: [PATCH] samples/livepatch: Add BPF struct_ops integration sample
Date: Fri, 17 Apr 2026 10:13:34 +0200 (CEST)	[thread overview]
Message-ID: <alpine.LSU.2.21.2604171011570.24300@pobox.suse.cz> (raw)
In-Reply-To: <20260416001628.2062468-1-song@kernel.org>

Hi,

On Wed, 15 Apr 2026, Song Liu wrote:

> Add a sample module that demonstrates how BPF struct_ops can work
> together with kernel livepatch. The module livepatches
> cmdline_proc_show() and delegates the output to a BPF struct_ops
> callback. When no BPF program is attached, a fallback message is
> shown; when a BPF struct_ops program is attached, it controls the
> /proc/cmdline output via the bpf_klp_seq_write kfunc.
> 
> This builds on the existing livepatch-sample.c pattern but shows how
> livepatch and BPF struct_ops can be combined to make livepatched
> behavior programmable from userspace.
> 
> The module is built when both CONFIG_SAMPLE_LIVEPATCH and
> CONFIG_BPF_JIT are enabled.
> 
> Signed-off-by: Song Liu <song@kernel.org>

Interesting. It does not make me comfortable to be honest. Is this 
something we want to advertise through samples?

Sashiko has comments... 
https://sashiko.dev/#/patchset/20260416001628.2062468-1-song%40kernel.org

Miroslav

  parent reply	other threads:[~2026-04-17  8:13 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-16  0:16 [PATCH] samples/livepatch: Add BPF struct_ops integration sample Song Liu
2026-04-16  0:18 ` Song Liu
2026-04-16  7:45 ` Yafang Shao
2026-04-16 16:32   ` Song Liu
2026-04-17  7:45     ` Yafang Shao
2026-04-17 15:45       ` Song Liu
2026-04-17 13:20     ` Petr Mladek
2026-04-17 15:52       ` Song Liu
2026-04-19  3:19         ` Yafang Shao
2026-04-17  8:13 ` Miroslav Benes [this message]
2026-04-17 15:46   ` Song Liu

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=alpine.LSU.2.21.2604171011570.24300@pobox.suse.cz \
    --to=mbenes@suse.cz \
    --cc=jikos@kernel.org \
    --cc=joe.lawrence@redhat.com \
    --cc=jpoimboe@kernel.org \
    --cc=kernel-team@meta.com \
    --cc=laoar.shao@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=live-patching@vger.kernel.org \
    --cc=pmladek@suse.com \
    --cc=song@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