Re: [PATCH net-next v8 02/24] net: introduce OpenVPN Data Channel Offload (ovpn)

2024-10-02 Thread kernel test robot
Hi Antonio, kernel test robot noticed the following build warnings: [auto build test WARNING on 44badc908f2c85711cb18e45e13119c10ad3a05f] url: https://github.com/intel-lab-lkp/linux/commits/Antonio-Quartulli/netlink-add-NLA_POLICY_MAX_LEN-macro/20241002-172734 base

Re: [PATCH slab hotfixes v2 2/2] slub/kunit: skip test_kfree_rcu when the slub kunit test is built-in

2024-10-02 Thread Vlastimil Babka
On 10/1/24 18:20, Vlastimil Babka wrote: > Guenter Roeck reports that the new slub kunit tests added by commit > 4e1c44b3db79 ("kunit, slub: add test_kfree_rcu() and > test_leak_destroy()") cause a lockup on boot on several architectures > when the kunit tests are configured to be built-in and not

Re: [PATCH bpf] bpf: fix unpopulated name_len field in perf_event link info

2024-10-02 Thread Jiri Olsa
On Mon, Sep 30, 2024 at 11:59:20PM +, tyrone-wu wrote: > Previously when retrieving `bpf_link_info.perf_event` for > kprobe/uprobe/tracepoint, the `name_len` field was not populated by the > kernel, leaving it to reflect the value initially set by the user. This > behavior was inconsistent with

Re: [PATCH V3 0/1] livepatch: Add "stack_order" sysfs attribute

2024-10-02 Thread Miroslav Benes
Hello, On Sun, 29 Sep 2024, Wardenjohn wrote: > As previous discussion, maintainers think that patch-level sysfs interface is > the > only acceptable way to maintain the information of the order that klp_patch > is > applied to the system. > > However, the previous patch introduce klp_ops int

Re: [PATCH bpf-next v2 0/6] selftests/bpf: Various sockmap-related fixes

2024-10-02 Thread Michal Luczaj
On 9/27/24 11:15, Jakub Sitnicki wrote: > On Fri, Sep 27, 2024 at 12:54 AM +02, Michal Luczaj wrote: >> ... >> Here's a follow up: my guess is that some checks are missing. I'm not sure >> if it's the best approach, but this fixes things for me: > > So you have already found a bug with a negative

RE: [PATCH 1/2] compiler.h: Introduce ptr_eq() to preserve address dependency

2024-10-02 Thread David Laight
From: 'Alan Stern' > Sent: 01 October 2024 23:57 > > On Tue, Oct 01, 2024 at 05:11:05PM +, David Laight wrote: > > From: Alan Stern > > > Sent: 30 September 2024 19:53 > > > > > > On Mon, Sep 30, 2024 at 07:05:06PM +0200, Jonas Oberhauser wrote: > > > > > > > > > > > > Am 9/30/2024 um 6:43 PM

Re: [PATCH] selftests/bpf: Add __init and __exit to the functions bpf_test_no_cfi_init()/bpf_test_no_cfi_exit()

2024-10-02 Thread Daniel Borkmann
On 9/30/24 3:33 AM, Yaxiong Tian wrote: From: Yaxiong Tian To save some running memory,Add __init and __exit to the module load/unload functions. Signed-off-by: Yaxiong Tian --- tools/testing/selftests/bpf/bpf_test_no_cfi/bpf_test_no_cfi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 delet

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Linus Torvalds
On Tue, 1 Oct 2024 at 18:04, Mathieu Desnoyers wrote: > > Hazard pointers appear to be a good fit for replacing refcount based lazy > active mm tracking. If the mm refcount is this expensive, I suspect we really shouldn't use it at all. The thing is, we don't _need_ to use the mm refcount - the

Re: [PATCH v3] kselftest/devices/probe: Fix SyntaxWarning in regex strings for Python3

2024-10-02 Thread Alessandro Zanni
Hello, this email is just a friendly reminder to know if the present patch is going to be applied or not. Thank you. Best Regards, Alessandro Zanni On 24/08/06 02:14, Alessandro Zanni wrote: > Insert raw strings to prevent Python3 from interpreting string literals > as Unicode strings and "\d"

[PATCH net-next v8 03/24] ovpn: add basic netlink support

2024-10-02 Thread Antonio Quartulli
This commit introduces basic netlink support with family registration/unregistration functionalities and stub pre/post-doit. More importantly it introduces the YAML uAPI description along with its auto-generated files: - include/uapi/linux/ovpn.h - drivers/net/ovpn/netlink-gen.c - drivers/net/ovpn

[PATCH net-next v8 02/24] net: introduce OpenVPN Data Channel Offload (ovpn)

2024-10-02 Thread Antonio Quartulli
OpenVPN is a userspace software existing since around 2005 that allows users to create secure tunnels. So far OpenVPN has implemented all operations in userspace, which implies several back and forth between kernel and user land in order to process packets (encapsulate/decapsulate, encrypt/decrypt

[PATCH net-next v8 04/24] ovpn: add basic interface creation/destruction/management routines

2024-10-02 Thread Antonio Quartulli
Add basic infrastructure for handling ovpn interfaces. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/main.c | 155 +- drivers/net/ovpn/main.h | 10 +++ drivers/net/ovpn/ovpnstruct.h | 8 +++ drivers/net/ovpn/packet.h | 40 ++

[PATCH net-next v8 00/24] Introducing OpenVPN Data Channel Offload

2024-10-02 Thread Antonio Quartulli
1822 + tools/testing/selftests/net/ovpn/tcp_peers.txt|5 + tools/testing/selftests/net/ovpn/udp_peers.txt|5 + 50 files changed, 8957 insertions(+) --- base-commit: 44badc908f2c85711cb18e45e13119c10ad3a05f change-id: 20241002-b4-ovpn-35c694a2 Best re

[PATCH net-next v8 01/24] netlink: add NLA_POLICY_MAX_LEN macro

2024-10-02 Thread Antonio Quartulli
Similarly to NLA_POLICY_MIN_LEN, NLA_POLICY_MAX_LEN defines a policy with a maximum length value. The netlink generator for YAML specs has been extended accordingly. Cc: donald.hun...@gmail.com Signed-off-by: Antonio Quartulli --- include/net/netlink.h | 1 + tools/net/ynl/ynl-gen-c.py | 2

[PATCH net-next v8 05/24] ovpn: implement interface creation/destruction via netlink

2024-10-02 Thread Antonio Quartulli
Allow userspace to create and destroy an interface using netlink commands. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/main.h| 2 ++ drivers/net/ovpn/netlink.c | 59 -- 2 files changed, 59 insertions(+), 2 deletions(-) diff --git a/driv

[PATCH net-next v8 06/24] ovpn: keep carrier always on

2024-10-02 Thread Antonio Quartulli
An ovpn interface will keep carrier always on and let the user decide when an interface should be considered disconnected. This way, even if an ovpn interface is not connected to any peer, it can still retain all IPs and routes and thus prevent any data leak. Signed-off-by: Antonio Quartulli Rev

[PATCH net-next v8 08/24] ovpn: introduce the ovpn_socket object

2024-10-02 Thread Antonio Quartulli
This specific structure is used in the ovpn kernel module to wrap and carry around a standard kernel socket. ovpn takes ownership of passed sockets and therefore an ovpn specific objects is attached to them for status tracking purposes. Initially only UDP support is introduced. TCP will come in a

[PATCH net-next v8 09/24] ovpn: implement basic TX path (UDP)

2024-10-02 Thread Antonio Quartulli
Packets sent over the ovpn interface are processed and transmitted to the connected peer, if any. Implementation is UDP only. TCP will be added by a later patch. Note: no crypto/encapsulation exists yet. packets are just captured and sent. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/

[PATCH net-next v8 10/24] ovpn: implement basic RX path (UDP)

2024-10-02 Thread Antonio Quartulli
Packets received over the socket are forwarded to the user device. Implementation is UDP only. TCP will be added by a later patch. Note: no decryption/decapsulation exists yet, packets are forwarded as they arrive without much processing. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/i

[PATCH net-next v8 07/24] ovpn: introduce the ovpn_peer object

2024-10-02 Thread Antonio Quartulli
An ovpn_peer object holds the whole status of a remote peer (regardless whether it is a server or a client). This includes status for crypto, tx/rx buffers, napi, etc. Only support for one peer is introduced (P2P mode). Multi peer support is introduced with a later patch. Along with the ovpn_pee

[PATCH net-next v8 11/24] ovpn: implement packet processing

2024-10-02 Thread Antonio Quartulli
This change implements encryption/decryption and encapsulation/decapsulation of OpenVPN packets. Support for generic crypto state is added along with a wrapper for the AEAD crypto kernel API. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/Makefile | 3 + drivers/net/ovpn/crypto.c

[PATCH net-next v8 12/24] ovpn: store tunnel and transport statistics

2024-10-02 Thread Antonio Quartulli
Byte/packet counters for in-tunnel and transport streams are now initialized and updated as needed. To be exported via netlink. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/Makefile | 1 + drivers/net/ovpn/crypto_aead.c | 2 ++ drivers/net/ovpn/io.c | 12 +++ dr

[PATCH net-next v8 13/24] ovpn: implement TCP transport

2024-10-02 Thread Antonio Quartulli
With this change ovpn is allowed to communicate to peers also via TCP. Parsing of incoming messages is implemented through the strparser API. Signed-off-by: Antonio Quartulli --- drivers/net/Kconfig | 1 + drivers/net/ovpn/Makefile | 1 + drivers/net/ovpn/io.c | 4 + drivers/net/

[PATCH net-next v8 14/24] ovpn: implement multi-peer support

2024-10-02 Thread Antonio Quartulli
With this change an ovpn instance will be able to stay connected to multiple remote endpoints. This functionality is strictly required when running ovpn on an OpenVPN server. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/main.c | 50 +++- drivers/net/ovpn/ovpnstruct.h |

[PATCH net-next v8 15/24] ovpn: implement peer lookup logic

2024-10-02 Thread Antonio Quartulli
In a multi-peer scenario there are a number of situations when a specific peer needs to be looked up. We may want to lookup a peer by: 1. its ID 2. its VPN destination IP 3. its transport IP/port couple For each of the above, there is a specific routing table referencing all peers for fast look u

[PATCH net-next v8 16/24] ovpn: implement keepalive mechanism

2024-10-02 Thread Antonio Quartulli
OpenVPN supports configuring a periodic keepalive packet. message to allow the remote endpoint detect link failures. This change implements the keepalive sending and timer expiring logic. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/io.c | 77 + drivers/net/ovp

[PATCH net-next v8 18/24] ovpn: add support for peer floating

2024-10-02 Thread Antonio Quartulli
A peer connected via UDP may change its IP address without reconnecting (float). Add support for detecting and updating the new peer IP/port in case of floating. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/bind.c | 10 ++-- drivers/net/ovpn/io.c | 9 drivers/net/ovpn/peer.c

[PATCH net-next v8 17/24] ovpn: add support for updating local UDP endpoint

2024-10-02 Thread Antonio Quartulli
In case of UDP links, the local endpoint used to communicate with a given peer may change without a connection restart. Add support for learning the new address in case of change. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/peer.c | 45 + dr

[PATCH net-next v8 21/24] ovpn: kill key and notify userspace in case of IV exhaustion

2024-10-02 Thread Antonio Quartulli
IV wrap-around is cryptographically dangerous for a number of ciphers, therefore kill the key and inform userspace (via netlink) should the IV space go exhausted. Userspace has two ways of deciding when the key has to be renewed before exhausting the IV space: 1) time based approach: after X se

[PATCH net-next v8 22/24] ovpn: notify userspace when a peer is deleted

2024-10-02 Thread Antonio Quartulli
Whenever a peer is deleted, send a notification to userspace so that it can react accordingly. This is most important when a peer is deleted due to ping timeout, because it all happens in kernelspace and thus userspace has no direct way to learn about it. Signed-off-by: Antonio Quartulli --- dr

[PATCH net-next v8 19/24] ovpn: implement peer add/dump/delete via netlink

2024-10-02 Thread Antonio Quartulli
This change introduces the netlink command needed to add, delete and retrieve/dump known peers. Userspace is expected to use these commands to handle known peer lifecycles. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/netlink.c | 582 - driver

[PATCH net-next v8 20/24] ovpn: implement key add/del/swap via netlink

2024-10-02 Thread Antonio Quartulli
This change introduces the netlink commands needed to add, delete and swap keys for a specific peer. Userspace is expected to use these commands to create, destroy and rotate session keys for a specific peer. Signed-off-by: Antonio Quartulli --- drivers/net/ovpn/netlink.c | 210

[PATCH net-next v8 24/24] testing/selftest: add test tool and scripts for ovpn module

2024-10-02 Thread Antonio Quartulli
The ovpn-cli tool can be compiled and used as selftest for the ovpn kernel module. It implementes the netlink API and can thus be integrated in any script for more automated testing. Along with the tool, 2 scripts are added that perform basic functionality tests by means of network namespaces. T

[PATCH net-next v8 23/24] ovpn: add basic ethtool support

2024-10-02 Thread Antonio Quartulli
Implement support for basic ethtool functionality. Note that ovpn is a virtual device driver, therefore various ethtool APIs are just not meaningful and thus not implemented. Signed-off-by: Antonio Quartulli Reviewed-by: Andrew Lunn --- drivers/net/ovpn/main.c | 15 +++ 1 file chan

Re: [PATCH rcu 0/11] Add light-weight readers for SRCU

2024-10-02 Thread Andrii Nakryiko
On Tue, Sep 3, 2024 at 3:08 PM Andrii Nakryiko wrote: > > On Tue, Sep 3, 2024 at 9:32 AM Paul E. McKenney wrote: > > > > Hello! > > > > This series provides light-weight readers for SRCU. This lightness > > is selected by the caller by using the new srcu_read_lock_lite() and > > srcu_read_unlock

Re: [PATCH v3 1/1] lib/llist_kunit.c: add KUnit tests for llist

2024-10-02 Thread Rae Moar
On Mon, Sep 16, 2024 at 8:51 PM Artur Alves wrote: > > Add KUnit tests for the llist data structure. They test the vast > majority of methods and macros defined in include/linux/llist.h. > > These are inspired by the existing tests for the 'list' doubly > linked in lib/list-test.c. Each test case

Re: [PATCH v3] kselftest/devices/probe: Fix SyntaxWarning in regex strings for Python3

2024-10-02 Thread Shuah Khan
On 10/2/24 03:00, Alessandro Zanni wrote: Hello, this email is just a friendly reminder to know if the present patch is going to be applied or not. Thank you. Best Regards, Alessandro Zanni No top posting please. On 24/08/06 02:14, Alessandro Zanni wrote: Insert raw strings to prevent Py

Re: [PATCH net-next v8 24/24] testing/selftest: add test tool and scripts for ovpn module

2024-10-02 Thread Shuah Khan
On 10/2/24 03:02, Antonio Quartulli wrote: The ovpn-cli tool can be compiled and used as selftest for the ovpn kernel module. Does this test load ovpn module before running tests? If so does it unload the modules after tests are complete? It implementes the netlink API and can thus be integr

Re: [PATCH] selftests/vdso: Add linux/sched.h to fix CLONE_NEWTIME build error

2024-10-02 Thread Shuah Khan
On 10/2/24 09:28, SurajSonawane2415 wrote: Fix build error in vdso_test_getrandom.c due to missing CLONE_NEWTIME. Include linux/sched.h to define CLONE_NEWTIME. Ensure successful compilation by resolving the missing header issue. Did you run "make headers" before building this test? It builds

Re: [PATCH HID v3 0/9] HID: bpf: add a new hook to control hid-generic

2024-10-02 Thread Shuah Khan
On 10/1/24 08:30, Benjamin Tissoires wrote: This is a slight change from the fundamentals of HID-BPF. In theory, HID-BPF is abstract to the kernel itself, and makes only changes at the HID level (through report descriptors or events emitted to/from the device). However, we have seen a few use ca

Re: [PATCH] selftests/vdso: Add linux/sched.h to fix CLONE_NEWTIME build error

2024-10-02 Thread Jason A. Donenfeld
Wasn't this already submitted and commented on? https://lore.kernel.org/all/20240919111841.20226-1-liaoy...@huawei.com/

Re: [PATCH] Revert "list: test: fix tests for list_cut_position()"

2024-10-02 Thread Shuah Khan
On 9/30/24 17:18, Jacob Keller wrote: On 9/22/2024 8:05 AM, Guenter Roeck wrote: This reverts commit e620799c414a035dea1208bcb51c869744931dbb. The commit introduces unit test failures. Expected cur == &entries[i], but cur == 037fffadfd80 &entries[i] == 037ff

Re: [PATCH RFT v9 4/8] fork: Add shadow stack support to clone3()

2024-10-02 Thread Mark Brown
On Wed, Oct 02, 2024 at 02:42:58PM +0100, Mark Brown wrote: > On Tue, Oct 01, 2024 at 11:03:10PM +, Edgecombe, Rick P wrote: > > I'm not so sure. The thing is a regular stack can be re-used in full - just > > set > > the RSP to the end and take advantage of the whole stack. A shadow stack can

Re: [PATCH net v4 2/2] bpf: selftests: send packet to devmap redirect XDP

2024-10-02 Thread Martin KaFai Lau
On 9/11/24 1:41 AM, Florian Kauer wrote: @@ -25,14 +28,11 @@ static void test_xdp_with_devmap_helpers(void) if (!ASSERT_OK_PTR(skel, "test_xdp_with_devmap_helpers__open_and_load")) return; - dm_fd = bpf_program__fd(skel->progs.xdp_redir_prog); - err = bpf_xdp_att

Re: [PATCH RFT v9 4/8] fork: Add shadow stack support to clone3()

2024-10-02 Thread Edgecombe, Rick P
On Wed, 2024-10-02 at 22:01 +0100, Mark Brown wrote: > BTW it's probably also worth noting that at least on arm64 (perhaps x86 > is different here?) the shadow stack of a thread that exited won't have > a token placed on it so it won't be possible to use it with clone3() at > all unless another tok

[PATCH bpf v2] bpf: fix unpopulated name_len field in perf_event link info

2024-10-02 Thread tyrone-wu
Previously when retrieving `bpf_link_info.perf_event` for kprobe/uprobe/tracepoint, the `name_len` field was not populated by the kernel, leaving it to reflect the value initially set by the user. This behavior was inconsistent with how other input/output string buffer fields function (e.g. `raw_tr

Re: [RFC PATCH 1/4] compiler.h: Introduce ptr_eq() to preserve address dependency

2024-10-02 Thread Joel Fernandes
On Tue, Oct 01, 2024 at 09:02:02PM -0400, Mathieu Desnoyers wrote: > Compiler CSE and SSA GVN optimizations can cause the address dependency > of addresses returned by rcu_dereference to be lost when comparing those > pointers with either constants or previously loaded pointers. > > Introduce ptr_

[PATCH bpf-next v4 0/2] Support eliding map lookup nullness

2024-10-02 Thread Daniel Xu
This patch allows progs to elide a null check on statically known map lookup keys. In other words, if the verifier can statically prove that the lookup will be in-bounds, allow the prog to drop the null check. This is useful for two reasons: 1. Large numbers of nullness checks (especially when th

[PATCH bpf-next v4 1/2] bpf: verifier: Support eliding map lookup nullness

2024-10-02 Thread Daniel Xu
This commit allows progs to elide a null check on statically known map lookup keys. In other words, if the verifier can statically prove that the lookup will be in-bounds, allow the prog to drop the null check. This is useful for two reasons: 1. Large numbers of nullness checks (especially when t

[PATCH bpf-next v4 2/2] bpf: selftests: verifier: Add nullness elision tests

2024-10-02 Thread Daniel Xu
Test that nullness elision works for common use cases. For example, we want to check that both full and subreg stack slots are recognized. As well as when there's both const and non-const values of R2 leading up to a lookup. And obviously some bound checks. Acked-by: Eduard Zingerman Signed-off-b

Re: [RFC PATCH 3/4] hp: Implement Hazard Pointers

2024-10-02 Thread Boqun Feng
On Tue, Oct 01, 2024 at 09:02:04PM -0400, Mathieu Desnoyers wrote: > This API provides existence guarantees of objects through Hazard > Pointers (HP). > > Each HP domain defines a fixed number of hazard pointer slots (nr_cpus) > across the entire system. > > Its main benefit over RCU is that it a

[PATCH] arm64: dts: qcom: sm6350: Fix GPU frequencies missing on some speedbins

2024-10-02 Thread Luca Weiss
gt;; opp-level = ; - opp-supported-hw = <0xff>; + opp-supported-hw = <0x1f>; }; }; }; --- base-commit: 9852d85ec9d492ebef56dc5f229416c925758edc change-id: 20241002-sm6350-gpu-speedbin-fix-2fc32b4ba0fd Best regards, -- Luca Weiss

Re: [PATCH] vsock/virtio: use GFP_ATOMIC under RCU read lock

2024-10-02 Thread Stefano Garzarella
On Wed, Oct 02, 2024 at 09:41:42AM GMT, Michael S. Tsirkin wrote: virtio_transport_send_pkt in now called on transport fast path, under RCU read lock. In that case, we have a bug: virtio_add_sgs is called with GFP_KERNEL, and might sleep. Pass the gfp flags as an argument, and use GFP_ATOMIC on

RE: [PATCH 1/2] compiler.h: Introduce ptr_eq() to preserve address dependency

2024-10-02 Thread David Laight
From: 'Alan Stern' > Sent: 02 October 2024 15:15 > > On Wed, Oct 02, 2024 at 08:13:15AM +, David Laight wrote: > > From: 'Alan Stern' > > > Sent: 01 October 2024 23:57 > > > > > > On Tue, Oct 01, 2024 at 05:11:05PM +, David Laight wrote: > > > > From: Alan Stern > > > > > Sent: 30 Septembe

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Mathieu Desnoyers
On 2024-10-02 16:09, Paul E. McKenney wrote: On Tue, Oct 01, 2024 at 09:02:01PM -0400, Mathieu Desnoyers wrote: Hazard pointers appear to be a good fit for replacing refcount based lazy active mm tracking. Highlight: will-it-scale context_switch1_threads nr threads (-t) speedup 24

Re: [PATCH v4 3/3] selftests: livepatch: test livepatching a kprobed function

2024-10-02 Thread Miroslav Benes
Hi, On Mon, 30 Sep 2024, Michael Vetter wrote: > The test proves that a function that is being kprobed and uses a > post_handler cannot be livepatched. > > Only one ftrace_ops with FTRACE_OPS_FL_IPMODIFY set may be registered > to any given function at a time. > > Signed-off-by: Michael Vetter

Re: [PATCH v4 1/3] selftests: livepatch: rename KLP_SYSFS_DIR to SYSFS_KLP_DIR

2024-10-02 Thread Miroslav Benes
Hi, On Mon, 30 Sep 2024, Michael Vetter wrote: > This naming makes more sense according to the directory structure. > Especially when we later add more paths. > > Signed-off-by: Michael Vetter > --- > tools/testing/selftests/livepatch/functions.sh | 6 +++--- > 1 file changed, 3 insertions(+),

[PATCH] selftests/vdso: Add linux/sched.h to fix CLONE_NEWTIME build error

2024-10-02 Thread SurajSonawane2415
Fix build error in vdso_test_getrandom.c due to missing CLONE_NEWTIME. Include linux/sched.h to define CLONE_NEWTIME. Ensure successful compilation by resolving the missing header issue. Signed-off-by: SurajSonawane2415 --- tools/testing/selftests/vDSO/vdso_test_getrandom.c | 1 + 1 file changed

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Matthew Wilcox
On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers wrote: > On 2024-10-02 16:09, Paul E. McKenney wrote: > > On Tue, Oct 01, 2024 at 09:02:01PM -0400, Mathieu Desnoyers wrote: > > > Hazard pointers appear to be a good fit for replacing refcount based lazy > > > active mm tracking. > > > >

Re: [PATCH] remoteproc: virtio: Add synchronize_cbs to remoteproc_virtio

2024-10-02 Thread Mathieu Poirier
On Fri, Sep 27, 2024 at 02:51:38AM +, Mark-PK Tsai (蔡沛剛) wrote: > Hi, > > Could someone help to review it or provide suggestions? > Any comments are welcome. > > This patch is intended to allow the rproc driver to handle the > following use-after-free issue: > > > ### UAF log What does "UA

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Mathieu Desnoyers
On 2024-10-02 17:33, Matthew Wilcox wrote: On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers wrote: On 2024-10-02 16:09, Paul E. McKenney wrote: On Tue, Oct 01, 2024 at 09:02:01PM -0400, Mathieu Desnoyers wrote: Hazard pointers appear to be a good fit for replacing refcount based laz

Re: [PATCH net v4 1/2] bpf: devmap: provide rxq after redirect

2024-10-02 Thread Jakub Kicinski
On Wed, 11 Sep 2024 10:41:18 +0200 Florian Kauer wrote: > rxq contains a pointer to the device from where > the redirect happened. Currently, the BPF program > that was executed after a redirect via BPF_MAP_TYPE_DEVMAP* > does not have it set. Acked-by: Jakub Kicinski

[PATCH] arm64: dts: qcom: qcm6490-fairphone-fp5: Add thermistor for UFS/RAM

2024-10-02 Thread Luca Weiss
qcom,hw-settle-time-us = <200>; + }; +}; + +&pm7250b_gpios { + pm7250b_adc_default: adc-default-state { + pins = "gpio12"; + function = PMIC_GPIO_FUNC_NORMAL; + bias-high-impedance; + }; }; &pm7325_gpios { --- base-commit: 9852d85ec9d492ebef56dc5f229416c925758edc change-id: 20241002-fp5-ufs-therm-0f1649d5d212 Best regards, -- Luca Weiss

[PATCH 2/3] rcu/nocb: Fix rcuog wake-up from offline softirq

2024-10-02 Thread Frederic Weisbecker
After a CPU has set itself offline and before it eventually calls rcutree_report_cpu_dead(), there are still opportunities for callbacks to be enqueued, for example from an IRQ. When that happens on NOCB, the rcuog wake-up is deferred through an IPI to an online CPU in order not to call into the sc

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Mathieu Desnoyers
On 2024-10-02 17:58, Jens Axboe wrote: On 10/2/24 9:53 AM, Mathieu Desnoyers wrote: On 2024-10-02 17:36, Mathieu Desnoyers wrote: On 2024-10-02 17:33, Matthew Wilcox wrote: On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers wrote: On 2024-10-02 16:09, Paul E. McKenney wrote: On Tue,

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Jens Axboe
On 10/2/24 10:02 AM, Mathieu Desnoyers wrote: > On 2024-10-02 17:58, Jens Axboe wrote: >> On 10/2/24 9:53 AM, Mathieu Desnoyers wrote: >>> On 2024-10-02 17:36, Mathieu Desnoyers wrote: On 2024-10-02 17:33, Matthew Wilcox wrote: > On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers

[PATCH net-next v2 1/2] selftests: net: remove ioam tests

2024-10-02 Thread Justin Iurman
This patch entirely removes the ioam selftests to prepare for the next patch in this series, which re-adds the new ioam selftests for better readability. Signed-off-by: Justin Iurman --- tools/testing/selftests/net/Makefile | 2 - tools/testing/selftests/net/config | 1 - tools

[PATCH net-next v2 0/2] selftests: net: ioam: add tunsrc support

2024-10-02 Thread Justin Iurman
v2: - v1 missed the merge window, so while we're at it... - split changes into two patches instead of one for readability (#1 removes the ioam selftests, #2 adds the updated ioam selftests) TL;DR This patch comes from a discussion we had with Jakub and Paolo on aligning the ioam selftests wit

[PATCH net-next v2 2/2] selftests: net: add new ioam tests

2024-10-02 Thread Justin Iurman
This patch re-adds the (updated) ioam selftests with support for the tunsrc feature. Signed-off-by: Justin Iurman --- tools/testing/selftests/net/Makefile |2 + tools/testing/selftests/net/config |1 + tools/testing/selftests/net/ioam6.sh | 1683

Re: [PATCH] vsock/virtio: use GFP_ATOMIC under RCU read lock

2024-10-02 Thread Stefano Garzarella
On Wed, Oct 02, 2024 at 04:02:06PM GMT, Stefano Garzarella wrote: On Wed, Oct 02, 2024 at 09:41:42AM GMT, Michael S. Tsirkin wrote: virtio_transport_send_pkt in now called on transport fast path, under RCU read lock. In that case, we have a bug: virtio_add_sgs is called with GFP_KERNEL, and migh

Re: [PATCH net] selftests: rds: move include.sh to TEST_FILES

2024-10-02 Thread patchwork-bot+netdevbpf
Hello: This patch was applied to netdev/net.git (main) by Jakub Kicinski : On Fri, 27 Sep 2024 12:13:49 +0800 you wrote: > The include.sh file is generated for inclusion and should not be executable. > Otherwise, it will be added to kselftest-list.txt. Additionally, add the > executable bit for t

Re: [PATCH] vsock/virtio: use GFP_ATOMIC under RCU read lock

2024-10-02 Thread Luigi Leonardi
> Link: > https://lore.kernel.org/all/hfcr2aget2zojmqpr4uhlzvnep4vgskblx5b6xf2ddosbsrke7@nt34bxgp7j2x > Fixes: efcd71af38be ("vsock/virtio: avoid queuing packets when intermediate > queue is empty") > Reported-by: Christian Brauner > Cc: Stefano Garzarella > Cc: Luigi Leonardi > Signed-off-by:

Re: [PATCH 1/2] compiler.h: Introduce ptr_eq() to preserve address dependency

2024-10-02 Thread 'Alan Stern'
On Wed, Oct 02, 2024 at 03:24:45PM +, David Laight wrote: > I think I know what you are trying to do, and you just fail. > Whether something can work is another matter, but that code > can't ever work. > > Inside if (a == b) the compiler will always use the same register > for references to a

Re: [PATCH v8 3/3] irqchip/loongson-eiointc: Add extioi virt extension support

2024-10-02 Thread Thomas Gleixner
On Wed, Sep 11 2024 at 17:11, Huacai Chen wrote: > Hi, Thomas, > > On Fri, Aug 30, 2024 at 5:32 PM Bibo Mao wrote: >> >> Interrupts can be routed to maximal four virtual CPUs with one HW >> EIOINTC interrupt controller model, since interrupt routing is encoded with >> CPU bitmap and EIOINTC node c

[PATCH] vsock/virtio: use GFP_ATOMIC under RCU read lock

2024-10-02 Thread Michael S. Tsirkin
virtio_transport_send_pkt in now called on transport fast path, under RCU read lock. In that case, we have a bug: virtio_add_sgs is called with GFP_KERNEL, and might sleep. Pass the gfp flags as an argument, and use GFP_ATOMIC on the fast path. Link: https://lore.kernel.org/all/hfcr2aget2zojmqpr

Re: [PATCH RFT v9 4/8] fork: Add shadow stack support to clone3()

2024-10-02 Thread Mark Brown
On Tue, Oct 01, 2024 at 11:03:10PM +, Edgecombe, Rick P wrote: > On Tue, 2024-10-01 at 18:33 +0100, Mark Brown wrote: > > My suspicion would be that if we're doing the pivot to a previously used > > shadow stack we'd also be pivoting the regular stack along with it which > > would face similar

Re: [PATCH slab hotfixes v2 2/2] slub/kunit: skip test_kfree_rcu when the slub kunit test is built-in

2024-10-02 Thread Guenter Roeck
On 10/1/24 09:20, Vlastimil Babka wrote: Guenter Roeck reports that the new slub kunit tests added by commit 4e1c44b3db79 ("kunit, slub: add test_kfree_rcu() and test_leak_destroy()") cause a lockup on boot on several architectures when the kunit tests are configured to be built-in and not module

Re: [PATCH slab hotfixes v2 2/2] slub/kunit: skip test_kfree_rcu when the slub kunit test is built-in

2024-10-02 Thread Vlastimil Babka
On 10/2/24 15:52, Guenter Roeck wrote: > On 10/2/24 03:26, Vlastimil Babka wrote: >> On 10/1/24 18:20, Vlastimil Babka wrote: >>> Guenter Roeck reports that the new slub kunit tests added by commit >>> 4e1c44b3db79 ("kunit, slub: add test_kfree_rcu() and >>> test_leak_destroy()") cause a lockup on

[PATCH 0/3] rcu: Fix yet another wake up from offline related issue

2024-10-02 Thread Frederic Weisbecker
Hi, A new warning has been reported due to swake_up_one_online() use from an offline IRQ: https://lore.kernel.org/oe-lkp/202409231644.4c55582d-...@intel.com Here is a tentative fix. Similar issue can happen with exp kthread and GP kthread if offline tick fires and there is a pending def

[PATCH 1/3] rcu/nocb: Use switch/case on NOCB timer state machine

2024-10-02 Thread Frederic Weisbecker
It's more convenient to benefit from the fallthrough feature of switch / case to handle the timer state machine. Also a new state is about to be added that will take advantage of it. No intended functional change. Signed-off-by: Frederic Weisbecker --- kernel/rcu/tree_nocb.h | 33 ++

[PATCH 3/3] rcu: Report callbacks enqueued on offline CPU blind spot

2024-10-02 Thread Frederic Weisbecker
Callbacks enqueued after rcutree_report_cpu_dead() fall into RCU barrier blind spot. Report any potential misuse. Reported-by: Paul E. McKenney Signed-off-by: Frederic Weisbecker --- kernel/rcu/tree.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c i

Re: [PATCH 3/3] rcu: Report callbacks enqueued on offline CPU blind spot

2024-10-02 Thread Frederic Weisbecker
Le Wed, Oct 02, 2024 at 04:57:38PM +0200, Frederic Weisbecker a écrit : > Callbacks enqueued after rcutree_report_cpu_dead() fall into RCU barrier > blind spot. Report any potential misuse. > > Reported-by: Paul E. McKenney > Signed-off-by: Frederic Weisbecker > --- > kernel/rcu/tree.c | 3 +++

Re: [PATCH v3 1/2] exec: fix up /proc/pid/comm in the execveat(AT_EMPTY_PATH) case

2024-10-02 Thread Zbigniew Jędrzejewski-Szmek
On Tue, Oct 01, 2024 at 08:42:56PM +0200, Aleksa Sarai wrote: > On 2024-10-01, Tycho Andersen wrote: > > From: Tycho Andersen > > > > Zbigniew mentioned at Linux Plumber's that systemd is interested in > > switching to execveat() for service execution, but can't, because the > > contents of /pro

Re: [PATCH slab hotfixes v2 2/2] slub/kunit: skip test_kfree_rcu when the slub kunit test is built-in

2024-10-02 Thread Guenter Roeck
On 10/2/24 03:26, Vlastimil Babka wrote: On 10/1/24 18:20, Vlastimil Babka wrote: Guenter Roeck reports that the new slub kunit tests added by commit 4e1c44b3db79 ("kunit, slub: add test_kfree_rcu() and test_leak_destroy()") cause a lockup on boot on several architectures when the kunit tests ar

Re: [PATCH v4 0/3] selftests: livepatch: test livepatching a kprobed function

2024-10-02 Thread Marcos Paulo de Souza
On Mon, 2024-09-30 at 11:33 +0200, Michael Vetter wrote: > Thanks to Miroslav, Petr and Marcos for the reviews! As the only changes were regarding bash nitpicks I keep my review from earlier patchset, so: Reviewed-by: Marcos Paulo de Souza > > V4: > Use variable for /sys/kernel/debug. > Be con

Re: [PATCH v3 1/2] exec: fix up /proc/pid/comm in the execveat(AT_EMPTY_PATH) case

2024-10-02 Thread Tycho Andersen
On Wed, Oct 02, 2024 at 01:45:15PM +, Zbigniew Jędrzejewski-Szmek wrote: > On Tue, Oct 01, 2024 at 08:42:56PM +0200, Aleksa Sarai wrote: > > On 2024-10-01, Tycho Andersen wrote: > > > From: Tycho Andersen > > > > > > Zbigniew mentioned at Linux Plumber's that systemd is interested in > > > s

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Paul E. McKenney
On Tue, Oct 01, 2024 at 09:02:01PM -0400, Mathieu Desnoyers wrote: > Hazard pointers appear to be a good fit for replacing refcount based lazy > active mm tracking. > > Highlight: > > will-it-scale context_switch1_threads > > nr threads (-t) speedup > 24+3% > 48

Re: [PATCH net-next v8 03/24] ovpn: add basic netlink support

2024-10-02 Thread kernel test robot
Hi Antonio, kernel test robot noticed the following build warnings: [auto build test WARNING on 44badc908f2c85711cb18e45e13119c10ad3a05f] url: https://github.com/intel-lab-lkp/linux/commits/Antonio-Quartulli/netlink-add-NLA_POLICY_MAX_LEN-macro/20241002-172734 base

Re: [PATCH 1/2] compiler.h: Introduce ptr_eq() to preserve address dependency

2024-10-02 Thread 'Alan Stern'
On Wed, Oct 02, 2024 at 08:13:15AM +, David Laight wrote: > From: 'Alan Stern' > > Sent: 01 October 2024 23:57 > > > > On Tue, Oct 01, 2024 at 05:11:05PM +, David Laight wrote: > > > From: Alan Stern > > > > Sent: 30 September 2024 19:53 > > > > > > > > On Mon, Sep 30, 2024 at 07:05:06PM +

Re: [PATCH v2] vhost/vsock: specify module version

2024-10-02 Thread Jakub Kicinski
On Mon, 30 Sep 2024 19:03:52 +0200 Aleksandr Mikhalitsyn wrote: > > At this point my question is, should we solve the problem higher and > > show all the modules in /sys/modules, either way? > > Probably, yes. We can ask Luis Chamberlain's opinion on this one. > > +cc Luis Chamberlain > > > >

Re: [RFC PATCH 0/4] sched+mm: Track lazy active mm existence with hazard pointers

2024-10-02 Thread Jens Axboe
On 10/2/24 9:53 AM, Mathieu Desnoyers wrote: > On 2024-10-02 17:36, Mathieu Desnoyers wrote: >> On 2024-10-02 17:33, Matthew Wilcox wrote: >>> On Wed, Oct 02, 2024 at 11:26:27AM -0400, Mathieu Desnoyers wrote: On 2024-10-02 16:09, Paul E. McKenney wrote: > On Tue, Oct 01, 2024 at 09:02:01P

Re: [PATCH V3 1/1] livepatch: Add "stack_order" sysfs attribute

2024-10-02 Thread zhang warden
Hi, Josh! > On Oct 1, 2024, at 07:26, Josh Poimboeuf wrote: >> >> diff --git a/Documentation/ABI/testing/sysfs-kernel-livepatch >> b/Documentation/ABI/testing/sysfs-kernel-livepatch >> index a5df9b4910dc..2a60b49aa9a5 100644 >> --- a/Documentation/ABI/testing/sysfs-kernel-livepatch >> +++ b/Do

Re: [RESEND PATCH v3] list: test: Mending tests for list_cut_position()

2024-10-02 Thread David Gow
On Tue, 1 Oct 2024 at 01:06, I Hsin Cheng wrote: > > Mending test for list_cut_position*() for the missing check of integer > "i" after the second loop. The variable should be checked for second > time to make sure both lists after the cut operation are formed as > expected. > > Signed-off-by: I H

Re: [PATCH slab hotfixes 2/2] kunit: move call to kunit_run_all_tests() after rcu_end_inkernel_boot()

2024-10-02 Thread David Gow
On Tue, 1 Oct 2024 at 07:55, Guenter Roeck wrote: > > On 9/30/24 11:50, Guenter Roeck wrote: > > On 9/30/24 01:37, Vlastimil Babka wrote: > >> Guenter Roeck reports that the new slub kunit tests added by commit > >> 4e1c44b3db79 ("kunit, slub: add test_kfree_rcu() and > >> test_leak_destroy()") ca

Re: [PATCH] Revert "list: test: fix tests for list_cut_position()"

2024-10-02 Thread David Gow
On Thu, 3 Oct 2024 at 04:39, Shuah Khan wrote: > > On 9/30/24 17:18, Jacob Keller wrote: > > > > > > On 9/22/2024 8:05 AM, Guenter Roeck wrote: > >> This reverts commit e620799c414a035dea1208bcb51c869744931dbb. > >> > >> The commit introduces unit test failures. > >> > >> Expected cur == &en

Re: [PATCH v3 1/1] lib/llist_kunit.c: add KUnit tests for llist

2024-10-02 Thread David Gow
On Tue, 17 Sept 2024 at 08:51, Artur Alves wrote: > > Add KUnit tests for the llist data structure. They test the vast > majority of methods and macros defined in include/linux/llist.h. > > These are inspired by the existing tests for the 'list' doubly > linked in lib/list-test.c. Each test case (

Re: [PATCH 6.6 000/538] 6.6.54-rc1 review

2024-10-02 Thread Naresh Kamboju
On Wed, 2 Oct 2024 at 19:56, Greg Kroah-Hartman wrote: > > This is the start of the stable review cycle for the 6.6.54 release. > There are 538 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know. > > Resp