Re: [PATCH bpf-next v1 0/2] ktls, sockmap: Fix missing uncharge operation and add selfttest

2025-05-01 Thread John Fastabend
On 2025-04-25 13:59:56, Jiayuan Chen wrote: > Cong reported a warning when running ./test_sockmp: > https://lore.kernel.org/bpf/aAmIi0vlycHtbXeb@pop-os.localdomain/T/#t > > [ cut here ] > WARNING: CPU: 1 PID: 40 at net/ipv4/af_inet.c inet_sock_destruct+0x173/0x1d5 > Tainted

[PATCH net v1] selftests: iou-zcrx: Clean up build warnings for error format

2025-05-01 Thread Haiyue Wang
Clean up two build warnings: [1]: iou-zcrx.c: In function ‘process_recvzc’: iou-zcrx.c:263:37: warning: too many arguments for format [-Wformat-extra-args] 263 | error(1, 0, "payload mismatch at ", i); | ^~ [2]: iou-zcrx.c: In

Re: [PATCH v18 00/15] PCI: EP: Add RC-to-EP doorbell with platform MSI controller

2025-05-01 Thread Frank Li
On Mon, Apr 14, 2025 at 02:30:54PM -0400, Frank Li wrote: Marc Zyngier: Do you have additional comments for this version? Frank Li > ┌┐ ┌───┐ ┌┐ > ││ │ │ ││

[PATCH v8 2/2] selftests: memcg: Increase error tolerance of child memory.current check in test_memcg_protection()

2025-05-01 Thread Waiman Long
The test_memcg_protection() function is used for the test_memcg_min and test_memcg_low sub-tests. This function generates a set of parent/child cgroups like: parent: memory.min/low = 50M child 0: memory.min/low = 75M, memory.current = 50M child 1: memory.min/low = 25M, memory.current = 50

[PATCH v8 1/2] selftests: memcg: Allow low event with no memory.low and memory_recursiveprot on

2025-05-01 Thread Waiman Long
The test_memcontrol selftest consistently fails its test_memcg_low sub-test due to the fact that its 3rd test child cgroup which have a memmory.low of 0 have low event count. This happens when memory_recursiveprot mount option is enabled which is the default setting used by systemd to mount cgroup2

[PATCH v8 0/2] memcg: Fix test_memcg_min/low test failures

2025-05-01 Thread Waiman Long
v8: - Ignore the low event count of child 2 with memory_recursiveprot on in patch 1 as originally suggested by Michal. v7: - Skip the vmscan change as the mem_cgroup_usage() check for now as it is currently redundant. v6: - The memcg_test_low failure is indeed due to the memory_recursive

Re: [PATCH bpf-next v3 10/11] bpf: Allow nospec-protected var-offset stack access

2025-05-01 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 10:17, Luis Gerhorst wrote: > > Insert a nospec before the access to prevent it from ever using an index > that is subject to speculative scalar-confusion. > > The access itself can either happen directly in the BPF program (reads > only, check_stack_read_var_off()) or in a h

Re: [PATCH v2 0/4] of: Common "memory-region" parsing

2025-05-01 Thread Tanmay Shah
On 5/1/25 10:44 AM, Tanmay Shah wrote: Hi Mathieu, I tested this patchset on top of recent for-next branch. I don't see issue on AMD-xlnx ZynqMP platform. With this: Tested-by: Tanmay Shah Hi Mathieu, Looks like I said it too soon. Firmware loading works with this series, but RPMsg d

Re: [PATCH bpf-next v3 08/11] bpf: Fall back to nospec for Spectre v1

2025-05-01 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 10:00, Luis Gerhorst wrote: > > This implements the core of the series and causes the verifier to fall > back to mitigating Spectre v1 using speculation barriers. The approach > was presented at LPC'24 [1] and RAID'24 [2]. > > If we find any forbidden behavior on a speculativ

Re: [PATCH bpf-next v3 07/11] bpf: Rename sanitize_stack_spill to nospec_result

2025-05-01 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 10:02, Luis Gerhorst wrote: > > This is made to clarify that this flag will cause a nospec to be added > after this insn and can therefore be relied upon to reduce speculative > path analysis. > > Signed-off-by: Luis Gerhorst > Cc: Henriette Herzog > Cc: Maximilian Ott > C

Re: [PATCH bpf-next v3 05/11] bpf, arm64, powerpc: Add bpf_jit_bypass_spec_v1/v4()

2025-05-01 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 09:51, Luis Gerhorst wrote: > > JITs can set bpf_jit_bypass_spec_v1/v4() if they want the verifier to > skip analysis/patching for the respective vulnerability. For v4, this > will reduce the number of barriers the verifier inserts. For v1, it > allows more programs to be acc

Re: [PATCH v3 8/8] mm/maps: execute PROCMAP_QUERY ioctl under RCU

2025-05-01 Thread Andrii Nakryiko
On Tue, Apr 29, 2025 at 10:25 AM Jann Horn wrote: > > On Tue, Apr 29, 2025 at 7:15 PM Suren Baghdasaryan wrote: > > On Tue, Apr 29, 2025 at 8:56 AM Jann Horn wrote: > > > On Wed, Apr 23, 2025 at 12:54 AM Andrii Nakryiko > > > wrote: > > > > On Fri, Apr 18, 2025 at 10:50 AM Suren Baghdasaryan

Re: [PATCH bpf-next v3 04/11] bpf: Return -EFAULT on internal errors

2025-05-01 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 09:48, Luis Gerhorst wrote: > > This prevents us from trying to recover from these on speculative paths > in the future. > > Signed-off-by: Luis Gerhorst > Reviewed-by: Eduard Zingerman > Acked-by: Henriette Herzog > Cc: Maximilian Ott > Cc: Milan Stephan > --- Acked-by

Re: [PATCH bpf-next v3 03/11] bpf: Return -EFAULT on misconfigurations

2025-05-01 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 09:48, Luis Gerhorst wrote: > > Mark these cases as non-recoverable to later prevent them from being > caught when they occur during speculative path verification. > > Eduard writes [1]: > > The only pace I'm aware of that might act upon specific error code > from verifie

Re: [PATCH bpf-next v3 02/11] bpf: Move insn if/else into do_check_insn()

2025-05-01 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 09:43, Luis Gerhorst wrote: > > This is required to catch the errors later and fall back to a nospec if > on a speculative path. > > Eliminate the regs variable as it is only used once and insn_idx is not > modified in-between the definition and usage. > > Still pass insn sim

Re: [PATCH 5/5] rcu/exp: Warn on CPU lagging for too long within hotplug IPI's blindspot

2025-05-01 Thread Frederic Weisbecker
Le Wed, Apr 30, 2025 at 02:20:31AM +, Joel Fernandes a écrit : > > > > On Apr 29, 2025, at 9:44 AM, Frederic Weisbecker > > wrote: > > Hi Frederic, > These all look good to me. Do you wish for > these to go into the upcoming merge window or > can I push them to a for-Neeraj branch as he >

Re: [PATCH bpf-next 1/2] btf: allow mmap of vmlinux btf

2025-05-01 Thread Alexei Starovoitov
On Thu, May 1, 2025 at 7:28 AM Lorenz Bauer wrote: > > User space needs access to kernel BTF for many modern features of BPF. > Right now each process needs to read the BTF blob either in pieces or > as a whole. Allow mmaping the sysfs file so that processes can directly > access the memory alloca

Re: [PATCH v3 3/3] selftests: pidfd: add tests for PIDFD_SELF_*

2025-05-01 Thread Sean Christopherson
On Thu, May 01, 2025, Peter Zijlstra wrote: > On Thu, May 01, 2025 at 01:42:35PM +0200, Peter Zijlstra wrote: > > On Wed, Oct 16, 2024 at 07:14:34PM -0700, John Hubbard wrote: > > > Peter Zijlstra's "NAK NAK NAK" response [1] last year was the most > > > colorful, so I'll helpfully cite it here. :)

Re: [PATCH bpf-next v3 02/11] bpf: Move insn if/else into do_check_insn()

2025-05-01 Thread Eduard Zingerman
On Thu, 2025-05-01 at 09:35 +0200, Luis Gerhorst wrote: > This is required to catch the errors later and fall back to a nospec if > on a speculative path. > > Eliminate the regs variable as it is only used once and insn_idx is not > modified in-between the definition and usage. > > Still pass ins

Re: [PATCH bpf-next v3 01/11] selftests/bpf: Fix caps for __xlated/jited_unpriv

2025-05-01 Thread Eduard Zingerman
On Thu, 2025-05-01 at 09:35 +0200, Luis Gerhorst wrote: > Currently, __xlated_unpriv and __jited_unpriv do not work because the > BPF syscall will overwrite info.jited_prog_len and info.xlated_prog_len > with 0 if the process is not bpf_capable(). This bug was not noticed > before, because there is

Re: [PATCH bpf-next v3 01/11] selftests/bpf: Fix caps for __xlated/jited_unpriv

2025-05-01 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 09:39, Luis Gerhorst wrote: > > Currently, __xlated_unpriv and __jited_unpriv do not work because the > BPF syscall will overwrite info.jited_prog_len and info.xlated_prog_len > with 0 if the process is not bpf_capable(). This bug was not noticed > before, because there is no

[PATCH 4/4] selftests/mm/uffd: Swap global variables with global test opts

2025-05-01 Thread Ujwal Kundur
We use the refactored uffd_global_test_opts instead of global variables for uffd-wp-mremap tests. Signed-off-by: Ujwal Kundur --- tools/testing/selftests/mm/uffd-wp-mremap.c | 23 + 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/tools/testing/selftests/mm/uffd

[PATCH 3/4] selftests/mm/uffd: Swap global variables with global test opts

2025-05-01 Thread Ujwal Kundur
We use the refactored uffd_global_test_opts instead of global variables for uffd-unit-tests. Signed-off-by: Ujwal Kundur --- tools/testing/selftests/mm/uffd-unit-tests.c | 523 ++- 1 file changed, 269 insertions(+), 254 deletions(-) diff --git a/tools/testing/selftests/mm/uffd-u

[PATCH 2/4] selftests/mm/uffd: Swap global vars with global test options

2025-05-01 Thread Ujwal Kundur
We use the refactored uffd_global_test_opts struct instead of global variables for uffd-stress tests. Signed-off-by: Ujwal Kundur --- tools/testing/selftests/mm/uffd-stress.c | 226 --- 1 file changed, 122 insertions(+), 104 deletions(-) diff --git a/tools/testing/selftests/

[PATCH 1/4] selftests/mm/uffd: Refactor non-composite global vars into struct

2025-05-01 Thread Ujwal Kundur
This patch deals with the common uffd routines, refactoring macros and non-composite global variable definitions into a struct that is defined at the start of a test and is passed around instead of relying on global vars. Signed-off-by: Ujwal Kundur --- tools/testing/selftests/mm/uffd-common.c |

[PATCH 0/4] selftests/mm/uffd: refactor global variables

2025-05-01 Thread Ujwal Kundur
This patchset refactors non-composite global variables into a common struct that can be initialized and passed around per-test instead of relying on the presence of global variables. This allows: - Better encapsulation - Debugging becomes easier -- local variable state can be viewed per stack fr

Re: [PATCH bpf-next 0/2] Allow mmap of /sys/kernel/btf/vmlinux

2025-05-01 Thread Daniel Xu
> 3 files changed, 104 insertions(+), 3 deletions(-) > --- > base-commit: 38d976c32d85ef12dcd2b8a231196f7049548477 > change-id: 20250501-vmlinux-mmap-2ec5563c3ef1 > > Best regards, > -- > Lorenz Bauer

Re: [PATCH v2 0/4] of: Common "memory-region" parsing

2025-05-01 Thread Tanmay Shah
Hi Mathieu, I tested this patchset on top of recent for-next branch. I don't see issue on AMD-xlnx ZynqMP platform. With this: Tested-by: Tanmay Shah On 4/24/25 9:14 AM, Mathieu Poirier wrote: Arnaud, Daniel, Iuliana, Andrew and Tanmay - please test this patchset on the platforms you are wo

[syzbot] [lvs?] KMSAN: uninit-value in do_output_route4

2025-05-01 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:bc3372351d0c Merge tag 'for-6.15-rc3-tag' of git://git.ker.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=12d6457458 kernel config: https://syzkaller.appspot.com/x/.config?x=fca45111586bf9a6 das

[PATCH bpf-next 0/2] Allow mmap of /sys/kernel/btf/vmlinux

2025-05-01 Thread Lorenz Bauer
tools/testing/selftests/bpf/prog_tests/btf_sysfs.c | 79 ++ 3 files changed, 104 insertions(+), 3 deletions(-) --- base-commit: 38d976c32d85ef12dcd2b8a231196f7049548477 change-id: 20250501-vmlinux-mmap-2ec5563c3ef1 Best regards, -- Lorenz Bauer

[PATCH bpf-next 2/2] selftests: bpf: add a test for mmapable vmlinux BTF

2025-05-01 Thread Lorenz Bauer
Add a basic test for the ability to mmap /sys/kernel/btf/vmlinux. Since libbpf doesn't have an API to parse BTF from memory we do some basic sanity checks ourselves. Signed-off-by: Lorenz Bauer --- tools/testing/selftests/bpf/prog_tests/btf_sysfs.c | 79 ++ 1 file changed, 79

[PATCH bpf-next 1/2] btf: allow mmap of vmlinux btf

2025-05-01 Thread Lorenz Bauer
User space needs access to kernel BTF for many modern features of BPF. Right now each process needs to read the BTF blob either in pieces or as a whole. Allow mmaping the sysfs file so that processes can directly access the memory allocated for it in the kernel. Signed-off-by: Lorenz Bauer --- i

Re: [RFC net-next v1 1/2] udp: Introduce UDP_STOP_RCV option for UDP

2025-05-01 Thread Willem de Bruijn
Kuniyuki Iwashima wrote: > From: "Jiayuan Chen" > Date: Thu, 01 May 2025 06:22:17 + > > 2025/5/1 12:42, "Kuniyuki Iwashima" wrote: > > > > > > > > From: Jiayuan Chen > > > > > > Date: Thu, 1 May 2025 11:51:08 +0800 > > > > > > > > > > > For some services we are using "established-over-u

Re: [PATCH v3 2/5] ASoC: qcom: sm8250: set card driver name from match data

2025-05-01 Thread Luca Weiss
Hi Srini, Srinivas Kandagatla schreef op 1 mei 2025 13:37:45 CEST: >On Fri, Apr 25, 2025 at 10:07:26AM +0200, Luca Weiss wrote: >> Sound machine drivers for Qualcomm SoCs can be reused across multiple >> SoCs. But user space ALSA UCM files depend on the card driver name which >> should be set per

Re: [PATCH net-next v3] vhost/net: Defer TX queue re-enable until after sendmsg

2025-05-01 Thread Michael S. Tsirkin
On Wed, Apr 30, 2025 at 07:04:28PM -0700, Jon Kohler wrote: > In handle_tx_copy, TX batching processes packets below ~PAGE_SIZE and > batches up to 64 messages before calling sock->sendmsg. > > Currently, when there are no more messages on the ring to dequeue, > handle_tx_copy re-enables kicks on

Re: [PATCH v3 0/3] RISC-V KVM selftests improvements

2025-05-01 Thread Anup Patel
On Wed, Apr 30, 2025 at 1:46 PM Atish Patra wrote: > > This series improves the following tests. > 1. Get-reg-list : Adds vector support > 2. SBI PMU test : Distinguish between different types of illegal exception > > The first patch is just helper patch that adds stval support during > exception

Re: [PATCH v3 3/3] selftests: pidfd: add tests for PIDFD_SELF_*

2025-05-01 Thread Peter Zijlstra
On Thu, May 01, 2025 at 01:42:35PM +0200, Peter Zijlstra wrote: > On Wed, Oct 16, 2024 at 07:14:34PM -0700, John Hubbard wrote: > > On 10/16/24 3:06 PM, Lorenzo Stoakes wrote: > > > On Wed, Oct 16, 2024 at 02:00:27PM -0600, Shuah Khan wrote: > > > > On 10/16/24 04:20, Lorenzo Stoakes wrote: > > ...

Re: [PATCH v1 1/7] mfd: stmpe-spi: Correct the name used in MODULE_DEVICE_TABLE

2025-05-01 Thread Lee Jones
On Sun, 27 Apr 2025, Krzysztof Kozlowski wrote: > On 26/04/2025 18:16, Alexey Gladkov wrote: > > The name used in the macro does not exist. > > > > drivers/mfd/stmpe-spi.c:132:26: error: use of undeclared identifier > > 'stmpe_id' > > 132 | MODULE_DEVICE_TABLE(spi, stmpe_id); > > |

Re: (subset) [PATCH v1 1/7] mfd: stmpe-spi: Correct the name used in MODULE_DEVICE_TABLE

2025-05-01 Thread Lee Jones
On Sat, 26 Apr 2025 18:16:32 +0200, Alexey Gladkov wrote: > The name used in the macro does not exist. > > drivers/mfd/stmpe-spi.c:132:26: error: use of undeclared identifier 'stmpe_id' > 132 | MODULE_DEVICE_TABLE(spi, stmpe_id); > | ^ > 1 error generated. > > [..

Re: [PATCH v3 3/3] selftests: pidfd: add tests for PIDFD_SELF_*

2025-05-01 Thread Peter Zijlstra
On Wed, Oct 16, 2024 at 07:14:34PM -0700, John Hubbard wrote: > On 10/16/24 3:06 PM, Lorenzo Stoakes wrote: > > On Wed, Oct 16, 2024 at 02:00:27PM -0600, Shuah Khan wrote: > > > On 10/16/24 04:20, Lorenzo Stoakes wrote: > ... > > > > diff --git a/tools/testing/selftests/pidfd/pidfd.h > > > > b/too

Re: [PATCH v3 2/5] ASoC: qcom: sm8250: set card driver name from match data

2025-05-01 Thread Srinivas Kandagatla
On Fri, Apr 25, 2025 at 10:07:26AM +0200, Luca Weiss wrote: > Sound machine drivers for Qualcomm SoCs can be reused across multiple > SoCs. But user space ALSA UCM files depend on the card driver name which > should be set per board/SoC. > > Allow such customization by using driver match data as s

Re: [PATCH v2 4/5] arm64: dts: qcom: sm6350: Add q6usbdai node

2025-05-01 Thread Konrad Dybcio
On 5/1/25 8:48 AM, Luca Weiss wrote: > Add a node for q6usb which handles USB audio offloading, allowing to > play audio via a USB-C headset with lower power consumption and enabling > some other features. > > We also need to set num-hc-interrupters for the dwc3 for the q6usb to be > able to use i

Re: [PATCH v10 1/3] rust: str: add radix prefixed integer parsing functions

2025-05-01 Thread Miguel Ojeda
On Thu, May 1, 2025 at 9:55 AM Andreas Hindborg wrote: > > +pub mod parse_int { > + > +use crate::prelude::*; Spurious newline. > +use crate::str::BStr; > +use core::ops::Deref; > +/// # Examples > +/// ``` Missing newline. > +// integer. We choose u64

Re: [PATCH v2 5/5] arm64: dts: qcom: sm7225-fairphone-fp4: Enable USB audio offload support

2025-05-01 Thread Konrad Dybcio
On 5/1/25 8:48 AM, Luca Weiss wrote: > Enable USB audio offloading which allows to play audio via a USB-C > headset with lower power consumption and enabling some other features. > > This can be used like the following: > > $ amixer -c0 cset name='USB_RX Audio Mixer MultiMedia1' On > $ aplay

[PATCH bpf-next v3 10/11] bpf: Allow nospec-protected var-offset stack access

2025-05-01 Thread Luis Gerhorst
Insert a nospec before the access to prevent it from ever using an index that is subject to speculative scalar-confusion. The access itself can either happen directly in the BPF program (reads only, check_stack_read_var_off()) or in a helper (read/write, check_helper_mem_access()). This relies on

[PATCH bpf-next v3 11/11] bpf: Fall back to nospec for sanitization-failures

2025-05-01 Thread Luis Gerhorst
ALU sanitization was introduced to ensure that a subsequent ptr access can never go OOB, even under speculation. This is required because we currently allow speculative scalar confusion. Spec. scalar confusion is possible because Spectre v4 sanitization only adds a nospec after critical stores (e.g

[PATCH net-next v4 0/3] vsock: SOCK_LINGER rework

2025-05-01 Thread Michal Luczaj
Change vsock's lingerning to wait on close() until all data is sent, i.e. until workers picked all the packets for processing. Changes in v4: - While in virtio, stick to virtio_transport_unsent_bytes() [Stefano] - Squash the indentation reduction [Stefano] - Pull SOCK_LINGER check into vsock_linge

[PATCH net-next v4 2/3] vsock: Move lingering logic to af_vsock core

2025-05-01 Thread Michal Luczaj
Lingering should be transport-independent in the long run. In preparation for supporting other transports, as well the linger on shutdown(), move code to core. Generalize by querying vsock_transport::unsent_bytes(), guard against the callback being unimplemented. Do not pass sk_lingertime explicit

[PATCH net-next v4 1/3] vsock/virtio: Linger on unsent data

2025-05-01 Thread Michal Luczaj
Currently vsock's lingering effectively boils down to waiting (or timing out) until packets are consumed or dropped by the peer; be it by receiving the data, closing or shutting down the connection. To align with the semantics described in the SO_LINGER section of man socket(7) and to mimic AF_INE

[PATCH net-next v4 3/3] vsock/test: Expand linger test to ensure close() does not misbehave

2025-05-01 Thread Michal Luczaj
There was an issue with SO_LINGER: instead of blocking until all queued messages for the socket have been successfully sent (or the linger timeout has been reached), close() would block until packets were handled by the peer. Add a check to alert on close() lingering when it should not. Signed-of

[PATCH bpf-next v3 09/11] selftests/bpf: Add test for Spectre v1 mitigation

2025-05-01 Thread Luis Gerhorst
This is based on the gadget from the description of commit 9183671af6db ("bpf: Fix leakage under speculation on mispredicted branches"). Signed-off-by: Luis Gerhorst --- .../selftests/bpf/progs/verifier_unpriv.c | 57 +++ 1 file changed, 57 insertions(+) diff --git a/tools/t

[PATCH bpf-next v3 08/11] bpf: Fall back to nospec for Spectre v1

2025-05-01 Thread Luis Gerhorst
This implements the core of the series and causes the verifier to fall back to mitigating Spectre v1 using speculation barriers. The approach was presented at LPC'24 [1] and RAID'24 [2]. If we find any forbidden behavior on a speculative path, we insert a nospec (e.g., lfence speculation barrier o

Re: [PATCH v10 0/3] rust: extend `module!` macro with integer parameter support

2025-05-01 Thread Greg KH
On Thu, May 01, 2025 at 09:53:36AM +0200, Andreas Hindborg wrote: > Extend the `module!` macro with support module parameters. Also add some > string > to integer parsing functions and updates `BStr` with a method to strip a > string > prefix. > > Based on code by Adam Bratschi-Kaye lifted from

[PATCH bpf-next v3 07/11] bpf: Rename sanitize_stack_spill to nospec_result

2025-05-01 Thread Luis Gerhorst
This is made to clarify that this flag will cause a nospec to be added after this insn and can therefore be relied upon to reduce speculative path analysis. Signed-off-by: Luis Gerhorst Cc: Henriette Herzog Cc: Maximilian Ott Cc: Milan Stephan --- include/linux/bpf_verifier.h | 2 +- kernel/b

[PATCH v10 1/3] rust: str: add radix prefixed integer parsing functions

2025-05-01 Thread Andreas Hindborg
Add the trait `ParseInt` for parsing string representations of integers where the string representations are optionally prefixed by a radix specifier. Implement the trait for the primitive integer types. Tested-by: Daniel Almeida Reviewed-by: Daniel Almeida Signed-off-by: Andreas Hindborg ---

[PATCH v10 2/3] rust: add parameter support to the `module!` macro

2025-05-01 Thread Andreas Hindborg
Add support for module parameters to the `module!` macro. Implement read only support for integer types without `sysfs` support. Acked-by: Petr Pavlu # from modules perspective Tested-by: Daniel Gomez Signed-off-by: Andreas Hindborg --- rust/kernel/lib.rs | 1 + rust/kernel/module_

[PATCH v10 3/3] modules: add rust modules files to MAINTAINERS

2025-05-01 Thread Andreas Hindborg
The module subsystem people agreed to maintain rust support for modules [1]. Thus, add entries for relevant files to modules entry in MAINTAINERS. Link: https://lore.kernel.org/all/0d9e596a-5316-4e00-862b-fd77552ae...@suse.com/ [1] Acked-by: Daniel Gomez Signed-off-by: Andreas Hindborg --- MAI

[PATCH v10 0/3] rust: extend `module!` macro with integer parameter support

2025-05-01 Thread Andreas Hindborg
Extend the `module!` macro with support module parameters. Also add some string to integer parsing functions and updates `BStr` with a method to strip a string prefix. Based on code by Adam Bratschi-Kaye lifted from the original `rust` branch [1]. Link: https://github.com/Rust-for-Linux/linux/tr

[PATCH bpf-next v3 06/11] bpf, arm64, powerpc: Change nospec to include v1 barrier

2025-05-01 Thread Luis Gerhorst
This changes the semantics of BPF_NOSPEC (previously a v4-only barrier) to always emit a speculation barrier that works against both Spectre v1 AND v4. If mitigation is not needed on an architecture, the backend should set bpf_jit_bypass_spec_v4/v1(). As of now, this commit only has the user-visib

[PATCH bpf-next v3 05/11] bpf, arm64, powerpc: Add bpf_jit_bypass_spec_v1/v4()

2025-05-01 Thread Luis Gerhorst
JITs can set bpf_jit_bypass_spec_v1/v4() if they want the verifier to skip analysis/patching for the respective vulnerability. For v4, this will reduce the number of barriers the verifier inserts. For v1, it allows more programs to be accepted. The primary motivation for this is to not regress unp

[PATCH bpf-next v3 04/11] bpf: Return -EFAULT on internal errors

2025-05-01 Thread Luis Gerhorst
This prevents us from trying to recover from these on speculative paths in the future. Signed-off-by: Luis Gerhorst Reviewed-by: Eduard Zingerman Acked-by: Henriette Herzog Cc: Maximilian Ott Cc: Milan Stephan --- kernel/bpf/verifier.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions

[PATCH bpf-next v3 00/11] bpf: Mitigate Spectre v1 using barriers

2025-05-01 Thread Luis Gerhorst
This improves the expressiveness of unprivileged BPF by inserting speculation barriers instead of rejecting the programs. The approach was previously presented at LPC'24 [1] and RAID'24 [2]. To mitigate the Spectre v1 (PHT) vulnerability, the kernel rejects potentially-dangerous unprivileged BPF

[PATCH bpf-next v3 03/11] bpf: Return -EFAULT on misconfigurations

2025-05-01 Thread Luis Gerhorst
Mark these cases as non-recoverable to later prevent them from being caught when they occur during speculative path verification. Eduard writes [1]: The only pace I'm aware of that might act upon specific error code from verifier syscall is libbpf. Looking through libbpf code, it seems that

[PATCH bpf-next v3 02/11] bpf: Move insn if/else into do_check_insn()

2025-05-01 Thread Luis Gerhorst
This is required to catch the errors later and fall back to a nospec if on a speculative path. Eliminate the regs variable as it is only used once and insn_idx is not modified in-between the definition and usage. Still pass insn simply to match the other check_*() functions. As Eduard points out

[PATCH bpf-next v3 01/11] selftests/bpf: Fix caps for __xlated/jited_unpriv

2025-05-01 Thread Luis Gerhorst
Currently, __xlated_unpriv and __jited_unpriv do not work because the BPF syscall will overwrite info.jited_prog_len and info.xlated_prog_len with 0 if the process is not bpf_capable(). This bug was not noticed before, because there is no test that actually uses __xlated_unpriv/__jited_unpriv. To

Re: [PATCH 6.1 000/167] 6.1.136-rc1 review

2025-05-01 Thread Greg Kroah-Hartman
On Wed, Apr 30, 2025 at 11:54:49AM -0400, Matthew Rosato wrote: > > > 2) > > Regressions on s390 with defconfig builds with gcc-13, gcc-8 and > > clang-20 and clang-nightly toolchains on the stable-rc 6.1.136-rc1. > > > > * s390, build > > - clang-20-defconfig > > - clang-nightly-defconfig >

Re: [RFC net-next v1 1/2] udp: Introduce UDP_STOP_RCV option for UDP

2025-05-01 Thread Kuniyuki Iwashima
From: "Jiayuan Chen" Date: Thu, 01 May 2025 06:22:17 + > 2025/5/1 12:42, "Kuniyuki Iwashima" wrote: > > > > > From: Jiayuan Chen > > > > Date: Thu, 1 May 2025 11:51:08 +0800 > > > > > > > > For some services we are using "established-over-unconnected" model. > > > > > > > > > > > >