]> www.infradead.org Git - users/jedix/linux-maple.git/commit
selftests/bpf: Fix bpf selftest build error
authorSaket Kumar Bhaskar <skb99@linux.ibm.com>
Mon, 12 May 2025 09:11:07 +0000 (14:41 +0530)
committerAlexei Starovoitov <ast@kernel.org>
Sun, 1 Jun 2025 19:57:41 +0000 (12:57 -0700)
commit4b65d5ae971430287855a89635a184c489bd02a5
treeae9f597a48cfdbaa89c0cc49d315cefba82ac0f5
parentbb1556ec94647060c6b52bf434b9fd824724a6f4
selftests/bpf: Fix bpf selftest build error

On linux-next, build for bpf selftest displays an error due to
mismatch in the expected function signature of bpf_testmod_test_read
and bpf_testmod_test_write.

Commit 97d06802d10a ("sysfs: constify bin_attribute argument of bin_attribute::read/write()")
changed the required type for struct bin_attribute to const struct bin_attribute.

To resolve the error, update corresponding signature for the callback.

Fixes: 97d06802d10a ("sysfs: constify bin_attribute argument of bin_attribute::read/write()")
Reported-by: Venkat Rao Bagalkote <venkat88@linux.ibm.com>
Closes: https://lore.kernel.org/all/e915da49-2b9a-4c4c-a34f-877f378129f6@linux.ibm.com/
Tested-by: Venkat Rao Bagalkote <venkat88@linux.ibm.com>
Signed-off-by: Saket Kumar Bhaskar <skb99@linux.ibm.com>
Link: https://lore.kernel.org/r/20250512091108.2015615-1-skb99@linux.ibm.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
tools/testing/selftests/bpf/test_kmods/bpf_testmod.c