BPF List
 help / color / mirror / Atom feed
From: Kui-Feng Lee <thinker.li@gmail.com>
To: bpf@vger.kernel.org, ast@kernel.org, martin.lau@linux.dev,
	song@kernel.org, kernel-team@meta.com, andrii@kernel.org
Cc: sinquersw@gmail.com, kuifeng@meta.com,
	Kui-Feng Lee <thinker.li@gmail.com>
Subject: [PATCH bpf-next 0/2] Update a struct_ops link through a pinned path
Date: Tue, 16 Apr 2024 17:25:11 -0700	[thread overview]
Message-ID: <20240417002513.1534535-1-thinker.li@gmail.com> (raw)

Applications already have the ability to update a struct_ops link with
another struct_ops map. However, they were unable to open pinned paths
of the links. This implies that updating a link through its pinned
paths was not feasible. By allowing the "open" operator on pinned
paths, applications can pin a struct_ops link and update the link
through the pinned path later.

Kui-Feng Lee (2):
  bpf: enable the "open" operator on a pinned path of a struct_osp link.
  selftests/bpf: open a pinned path of a struct_ops link.

 include/linux/bpf.h                           |  4 ++
 kernel/bpf/bpf_struct_ops.c                   | 10 ++++
 kernel/bpf/inode.c                            | 11 +++-
 kernel/bpf/syscall.c                          | 14 ++++-
 .../selftests/bpf/bpf_testmod/bpf_testmod.c   |  6 ++
 .../bpf/prog_tests/test_struct_ops_module.c   | 56 +++++++++++++++++++
 6 files changed, 97 insertions(+), 4 deletions(-)

-- 
2.34.1


             reply	other threads:[~2024-04-17  0:25 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-17  0:25 Kui-Feng Lee [this message]
2024-04-17  0:25 ` [PATCH bpf-next 1/2] bpf: enable the "open" operator on a pinned path of a struct_osp link Kui-Feng Lee
2024-04-17 23:19   ` kernel test robot
2024-04-18  6:13   ` kernel test robot
2024-04-20  0:05   ` Martin KaFai Lau
2024-04-22 17:12     ` Kui-Feng Lee
2024-04-22 17:30       ` Kui-Feng Lee
2024-04-22 23:43         ` Martin KaFai Lau
2024-04-23 17:16           ` Kui-Feng Lee
2024-04-24  0:29             ` Martin KaFai Lau
2024-04-25  0:17               ` Andrii Nakryiko
2024-04-25 17:11                 ` Kui-Feng Lee
2024-04-17  0:25 ` [PATCH bpf-next 2/2] selftests/bpf: open a pinned path of a struct_ops link Kui-Feng Lee

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=20240417002513.1534535-1-thinker.li@gmail.com \
    --to=thinker.li@gmail.com \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=kernel-team@meta.com \
    --cc=kuifeng@meta.com \
    --cc=martin.lau@linux.dev \
    --cc=sinquersw@gmail.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