Re: [PATCH v1 2/2] selftests/mm: hugetlb_fault_after_madv: improve test output

2024-09-30 Thread Breno Leitao
On Thu, Sep 26, 2024 at 05:20:44PM +0200, David Hildenbrand wrote: > Let's improve the test output. For example, print the proper test > result. Install a SIGBUS handler to catch any SIGBUS instead of > crashing the test on failure. That is way better now. Thanks for improving it. > With unsuitab

Re: [PATCH 1/8] dt-bindings: power: supply: Add DT schema for Qualcomm SMBCHG

2024-09-30 Thread Yassine Oudjana
Coming back to this patch series after putting it on hold for too long. On 30/11/2022 7:24 pm, Krzysztof Kozlowski wrote: On 08/08/2022 09:34, Yassine Oudjana wrote: From: Yassine Oudjana + See Documentation/devicetree/bindings/power/supply/battery.yaml + + interrupts: +items: +

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

2024-09-30 Thread Alan Huang
On Sep 30, 2024, at 17:33, Jonas Oberhauser wrote: > > > > Am 9/30/2024 um 11:27 AM schrieb Alan Huang: >> 2024年9月30日 17:15,Alan Huang 写道: >>> >>> 2024年9月30日 16:57,Jonas Oberhauser 写道: Am 9/29/2024 um 12:26 AM schrieb Alan Huang: > 2024年9月28日 23:55,Mathieu Desnoye

Re: [RFC PATCH 0/3] introduce PIDFD_SELF

2024-09-30 Thread Florian Weimer
* Lorenzo Stoakes: > If you wish to utilise a pidfd interface to refer to the current process > (from the point of view of userland - from the kernel point of view - the > thread group leader), it is rather cumbersome, requiring something like: > > int pidfd = pidfd_open(getpid(), 0); > >

Re: [RFC PATCH 0/3] introduce PIDFD_SELF

2024-09-30 Thread Lorenzo Stoakes
On Mon, Sep 30, 2024 at 12:33:18PM GMT, Florian Weimer wrote: > * Lorenzo Stoakes: > > > If you wish to utilise a pidfd interface to refer to the current process > > (from the point of view of userland - from the kernel point of view - the > > thread group leader), it is rather cumbersome, requirin

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

2024-09-30 Thread Alan Huang
2024年9月30日 16:57,Jonas Oberhauser 写道: > > > > Am 9/29/2024 um 12:26 AM schrieb Alan Huang: >> 2024年9月28日 23:55,Mathieu Desnoyers wrote: >>> >>> On 2024-09-28 17:49, Alan Stern wrote: On Sat, Sep 28, 2024 at 11:32:18AM -0400, Mathieu Desnoyers wrote: > On 2024-09-28 16:49, Alan Stern

[RFC PATCH 3/3] selftests: pidfd: add tests for PIDFD_SELF

2024-09-30 Thread Lorenzo Stoakes
Add tests to assert that PIDFD_SELF correctly refers to the current process. This is only practically meaningful to pidfd_send_signal() and pidfd_getfd(), but also explicitly test that we disallow this feature for setns() where it would make no sense. We cannot reasonably wait on ourself using wa

[RFC PATCH 2/3] pidfd: add PIDFD_SELF sentinel to refer to own process

2024-09-30 Thread Lorenzo Stoakes
Add a PIDFD_SELF special sentinel value which can be passed as a pidfd to indicate that the current process is to be targeted (as this is a process from the userland perspective, this means from the kernel's perspective the current thread group leader is to be targeted). Due to the refactoring of

[RFC PATCH 0/3] introduce PIDFD_SELF

2024-09-30 Thread Lorenzo Stoakes
If you wish to utilise a pidfd interface to refer to the current process (from the point of view of userland - from the kernel point of view - the thread group leader), it is rather cumbersome, requiring something like: int pidfd = pidfd_open(getpid(), 0); ... close(pidfd

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

2024-09-30 Thread Alan Huang
2024年9月30日 17:15,Alan Huang 写道: > > 2024年9月30日 16:57,Jonas Oberhauser 写道: >> >> >> >> Am 9/29/2024 um 12:26 AM schrieb Alan Huang: >>> 2024年9月28日 23:55,Mathieu Desnoyers wrote: On 2024-09-28 17:49, Alan Stern wrote: > On Sat, Sep 28, 2024 at 11:32:18AM -0400, Mathieu Desnoyers

[RFC PATCH 1/3] pidfd: refactor pidfd_get_pid/to_pid() and de-duplicate pid lookup

2024-09-30 Thread Lorenzo Stoakes
The means by which a pid is determined from a pidfd is duplicated, some callers holding a reference to the (pid)fd, and others explicitly pinning the pid. Introduce __pidfd_get_pid() which abstracts both approaches and provide optional output parameters for file->f_flags and the fd (the latter of

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

2024-09-30 Thread Michael Vetter
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 --- tools/testing/selftests/livepatch/Makefile| 3 +- ..

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

2024-09-30 Thread Michael Vetter
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(+), 3 deletions(-) diff --git a/tools/testing/selftests/livepatch

[PATCH v4 2/3] selftests: livepatch: save and restore kprobe state

2024-09-30 Thread Michael Vetter
Save the state of /sys/kernel/debug/kprobes/enabled during setup_config() and restore it during cleanup(). This is in preparation for a future commit that will add a test that should confirm that we cannot livepatch a kprobed function if that kprobe has a post handler. Signed-off-by: Michael Vett

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

2024-09-30 Thread Michael Vetter
Thanks to Miroslav, Petr and Marcos for the reviews! V4: Use variable for /sys/kernel/debug. Be consistent with "" around variables. Fix path in commit message to /sys/kernel/debug/kprobes/enabled. V3: Save and restore kprobe state also when test fails, by integrating it into setup_config() and c

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

2024-09-30 Thread Jonas Oberhauser
Am 9/30/2024 um 11:27 AM schrieb Alan Huang: 2024年9月30日 17:15,Alan Huang 写道: 2024年9月30日 16:57,Jonas Oberhauser 写道: Am 9/29/2024 um 12:26 AM schrieb Alan Huang: 2024年9月28日 23:55,Mathieu Desnoyers wrote: The motivation for introducing ptr_eq() is indeed because the compiler barrier i

Re: [PATCH v2 7/7] kunit, slub: add test_kfree_rcu() and test_leak_destroy()

2024-09-30 Thread Vlastimil Babka
Any opinions, Vlastimil? > > Yes, we should suppress the existing warning on kmem_cache_destroy() in Done here: https://lore.kernel.org/all/20240930-b4-slub-kunit-fix-v1-0-32ca9dbbb...@suse.cz/ > kunit test context, and separately we can change pr_err() to WARN() as long > as they ar

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

2024-09-30 Thread Jonas Oberhauser
Am 9/29/2024 um 12:26 AM schrieb Alan Huang: 2024年9月28日 23:55,Mathieu Desnoyers wrote: On 2024-09-28 17:49, Alan Stern wrote: On Sat, Sep 28, 2024 at 11:32:18AM -0400, Mathieu Desnoyers wrote: On 2024-09-28 16:49, Alan Stern wrote: On Sat, Sep 28, 2024 at 09:51:27AM -0400, Mathieu Desnoy

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

2024-09-30 Thread Jonas Oberhauser
Am 9/28/2024 um 11:15 PM schrieb Alan Stern: On Sat, Sep 28, 2024 at 11:55:22AM -0400, Mathieu Desnoyers wrote: On 2024-09-28 17:49, Alan Stern wrote: Isn't it true that on strongly ordered CPUs, a compiler barrier is sufficient to prevent the rcu_dereference() problem? So the whole idea be

Re: [PATCH v1 1/2] selftests/mm: hugetlb_fault_after_madv: use default hguetlb page size

2024-09-30 Thread Breno Leitao
On Thu, Sep 26, 2024 at 05:20:43PM +0200, David Hildenbrand wrote: > We currently assume that the hugetlb page size is 2 MiB, which is > why we mmap() a 2 MiB range. > > Is the default hugetlb size is larger, mmap() will fail because the > range is not suitable. If the default hugetlb size is smal

[PATCH slab hotfixes 0/2] slub kunit tests fixes for 6.12

2024-09-30 Thread Vlastimil Babka
init/main.c | 4 ++-- lib/slub_kunit.c | 4 ++-- mm/slab.h| 6 ++ mm/slab_common.c | 5 +++-- mm/slub.c| 5 +++-- 5 files changed, 16 insertions(+), 8 deletions(-) --- base-commit: 9852d85ec9d492ebef56dc5f229416c925758edc change-id: 20240930-b4-slub-kunit-fix-6fba4d

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

2024-09-30 Thread Vlastimil Babka
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 modules. These tests invoke kfree_rcu() and kvfr

Re: [PATCH] selftest: hid: add missing run-hid-tools-tests.sh

2024-09-30 Thread Benjamin Tissoires
On Sep 29 2024, Yun Lu wrote: > The HID test cases actually run tests using the run-hid-tools-tests.sh > script. However, if installed with "make install", the run-hid-tools-tests.sh > script will not be copied over, resulting in the following error message. > > make -C tools/testing/selftests/

Re: [PATCH v2 -next] selftests/bpf: Use ARRAY_SIZE for array length

2024-09-30 Thread Tony Ambardar
On Sun, Sep 29, 2024 at 05:28:11PM +0800, Jiapeng Chong wrote: > Use of macro ARRAY_SIZE to calculate array size minimizes > the redundant code and improves code reusability. > > ./tools/testing/selftests/bpf/prog_tests/core_reloc_raw.c:98:34-35: WARNING: > Use ARRAY_SIZE. > ./tools/testing/selft

Re: [PATCH v1 2/2] selftests/mm: hugetlb_fault_after_madv: improve test output

2024-09-30 Thread David Hildenbrand
On 30.09.24 12:05, Breno Leitao wrote: On Thu, Sep 26, 2024 at 05:20:44PM +0200, David Hildenbrand wrote: Let's improve the test output. For example, print the proper test result. Install a SIGBUS handler to catch any SIGBUS instead of crashing the test on failure. That is way better now. Than

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

2024-09-30 Thread Aleksandr Mikhalitsyn
On Mon, Sep 30, 2024 at 4:27 PM Stefano Garzarella wrote: > > On Sun, Sep 29, 2024 at 08:21:03PM GMT, Alexander Mikhalitsyn wrote: > >Add an explicit MODULE_VERSION("0.0.1") specification for the vhost_vsock > >module. > > > >It is useful because it allows userspace to check if vhost_vsock is the

Re: [PATCH net-next] selftests: net: csum: Clean up recv_verify_packet_ipv6

2024-09-30 Thread Willem de Bruijn
Sean Anderson wrote: > Rename ip_len to payload_len since the length in this case refers only > to the payload, and not the entire IP packet like for IPv4. While we're > at it, just use the variable directly when calling > recv_verify_packet_udp/tcp. > > Signed-off-by: Sean Anderson Not sure suc

[PATCH 0/3] selftests: net: add missing gitignore and EXTRA_CLEAN entries.

2024-09-30 Thread Javier Carrasco
/rds/.gitignore | 1 + tools/testing/selftests/net/rds/Makefile | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) --- base-commit: 9852d85ec9d492ebef56dc5f229416c925758edc change-id: 20240930-net-selftests-gitignore-18b844f29391 Best regards, -- Javier Carrasco

[PATCH 1/3] selftests: net: add msg_oob to gitignore

2024-09-30 Thread Javier Carrasco
This executable is missing from the corresponding gitignore file. Add msg_oob to the net gitignore list. Signed-off-by: Javier Carrasco --- tools/testing/selftests/net/.gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/testing/selftests/net/.gitignore b/tools/testing/selftests

[PATCH net-next] selftests: net: csum: Clean up recv_verify_packet_ipv6

2024-09-30 Thread Sean Anderson
Rename ip_len to payload_len since the length in this case refers only to the payload, and not the entire IP packet like for IPv4. While we're at it, just use the variable directly when calling recv_verify_packet_udp/tcp. Signed-off-by: Sean Anderson --- tools/testing/selftests/net/lib/csum.c |

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

2024-09-30 Thread Stefano Garzarella
Hi Aleksandr, On Mon, Sep 30, 2024 at 04:43:36PM GMT, Aleksandr Mikhalitsyn wrote: On Mon, Sep 30, 2024 at 4:27 PM Stefano Garzarella wrote: On Sun, Sep 29, 2024 at 08:21:03PM GMT, Alexander Mikhalitsyn wrote: >Add an explicit MODULE_VERSION("0.0.1") specification for the vhost_vsock module.

Re: [PATCH V2 04/13] selftests/resctrl: Protect against array overrun during iMC config parsing

2024-09-30 Thread Reinette Chatre
Hi Ilpo, On 9/30/24 6:35 AM, Ilpo Järvinen wrote: > On Thu, 12 Sep 2024, Reinette Chatre wrote: > >> The MBM and MBA tests need to discover the event and umask with which to >> configure the performance event used to measure read memory bandwidth. >> This is done by parsing the >> /sys/bus/event_

Re: [PATCH V2 07/13] selftests/resctrl: Only support measured read operation

2024-09-30 Thread Reinette Chatre
Hi Ilpo, On 9/30/24 6:52 AM, Ilpo Järvinen wrote: > On Thu, 12 Sep 2024, Reinette Chatre wrote: >> diff --git a/tools/testing/selftests/resctrl/resctrl.h >> b/tools/testing/selftests/resctrl/resctrl.h >> index 51f5f4b25e06..ba1ce1b35699 100644 >> --- a/tools/testing/selftests/resctrl/resctrl.h >

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

2024-09-30 Thread Aleksandr Mikhalitsyn
On Mon, Sep 30, 2024 at 5:43 PM Stefano Garzarella wrote: > > Hi Aleksandr, > > On Mon, Sep 30, 2024 at 04:43:36PM GMT, Aleksandr Mikhalitsyn wrote: > >On Mon, Sep 30, 2024 at 4:27 PM Stefano Garzarella > > wrote: > >> > >> On Sun, Sep 29, 2024 at 08:21:03PM GMT, Alexander Mikhalitsyn wrote: > >>

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

2024-09-30 Thread Jonas Oberhauser
Am 9/30/2024 um 6:43 PM schrieb Alan Stern: On Mon, Sep 30, 2024 at 01:26:53PM +0200, Jonas Oberhauser wrote: Am 9/28/2024 um 4:49 PM schrieb Alan Stern: On Sat, Sep 28, 2024 at 09:51:27AM -0400, Mathieu Desnoyers wrote: Compiler CSE and SSA GVN optimizations can cause the address depende

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

2024-09-30 Thread I Hsin Cheng
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 Hsin Cheng --- lib/list-test.c | 4 1 file changed, 4 ins

Re: [PATCH V2 06/13] selftests/resctrl: Remove "once" parameter required to be false

2024-09-30 Thread Ilpo Järvinen
On Thu, 12 Sep 2024, Reinette Chatre wrote: > The CMT, MBM, and MBA tests rely on a benchmark that runs while > the test makes changes to needed configuration (for example memory > bandwidth allocation) and takes needed measurements. By default > the "fill_buf" benchmark is used and by default (vi

Re: [PATCH V2 07/13] selftests/resctrl: Only support measured read operation

2024-09-30 Thread Ilpo Järvinen
On Thu, 12 Sep 2024, Reinette Chatre wrote: > The CMT, MBM, and MBA tests rely on a benchmark to generate > memory traffic. By default this is the "fill_buf" benchmark that > can be replaced via the "-b" command line argument. > > The original intent of the "-b" command line parameter was > to re

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

2024-09-30 Thread Paul E. McKenney
On Mon, Sep 30, 2024 at 02:06:12PM +0200, Jonas Oberhauser wrote: > > > Am 9/30/2024 um 1:04 PM schrieb Paul E. McKenney: > > On Mon, Sep 30, 2024 at 11:42:11AM +0200, Jonas Oberhauser wrote: > > > > > > > > > I also currently don't see any major difference between the constant and > > > regist

[PATCH 05/35] libnvdimm: Reorganize kerneldoc parameter names

2024-09-30 Thread Julia Lawall
Reorganize kerneldoc parameter names to match the parameter order in the function header. Problems identified using Coccinelle. Signed-off-by: Julia Lawall --- drivers/nvdimm/dimm_devs.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/nvdimm/dimm_devs.c b/drivers

[PATCH] rcu/kvfree: Refactor kvfree_rcu_queue_batch()

2024-09-30 Thread Uladzislau Rezki (Sony)
Improve readability of kvfree_rcu_queue_batch() function in away that, after a first batch queuing, the loop is break and success value is returned to a caller. There is no reason to loop and check batches further as all outstanding objects have already been picked and attached to a certain batch

Re: [PATCH 1/1] remoteproc: Use iommu_paging_domain_alloc()

2024-09-30 Thread Mathieu Poirier
On Mon, Aug 12, 2024 at 03:28:11PM +0800, Lu Baolu wrote: > An iommu domain is allocated in rproc_enable_iommu() and is attached to > rproc->dev.parent in the same function. > > Use iommu_paging_domain_alloc() to make it explicit. > > Signed-off-by: Lu Baolu > Reviewed-by: Jason Gunthorpe > Lin

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

2024-09-30 Thread Alan Stern
On Mon, Sep 30, 2024 at 01:26:53PM +0200, Jonas Oberhauser wrote: > > > Am 9/28/2024 um 4:49 PM schrieb Alan Stern: > > On Sat, Sep 28, 2024 at 09:51:27AM -0400, Mathieu Desnoyers wrote: > > > Compiler CSE and SSA GVN optimizations can cause the address dependency > > > of addresses returned by r

Re: [PATCH] remoteproc: k3: Call of_node_put(rmem_np) only once in three functions

2024-09-30 Thread Mathieu Poirier
On Tue, Sep 24, 2024 at 02:43:40PM +0200, Markus Elfring wrote: > From: Markus Elfring > Date: Tue, 24 Sep 2024 14:28:35 +0200 > > An of_node_put(rmem_np) call was immediately used after a pointer check > for a of_reserved_mem_lookup() call in three function implementations. > Thus call such a fu

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

2024-09-30 Thread Paul E. McKenney
On Mon, Sep 30, 2024 at 11:42:11AM +0200, Jonas Oberhauser wrote: > > > Am 9/28/2024 um 11:15 PM schrieb Alan Stern: > > On Sat, Sep 28, 2024 at 11:55:22AM -0400, Mathieu Desnoyers wrote: > > > On 2024-09-28 17:49, Alan Stern wrote: > > > > Isn't it true that on strongly ordered CPUs, a compiler

Re: [RFC PATCH 0/3] introduce PIDFD_SELF

2024-09-30 Thread Christian Brauner
On Mon, Sep 30, 2024 at 11:39:49AM GMT, Lorenzo Stoakes wrote: > On Mon, Sep 30, 2024 at 12:33:18PM GMT, Florian Weimer wrote: > > * Lorenzo Stoakes: > > > > > If you wish to utilise a pidfd interface to refer to the current process > > > (from the point of view of userland - from the kernel point

Re: [PATCH V2 04/13] selftests/resctrl: Protect against array overrun during iMC config parsing

2024-09-30 Thread Ilpo Järvinen
On Thu, 12 Sep 2024, Reinette Chatre wrote: > The MBM and MBA tests need to discover the event and umask with which to > configure the performance event used to measure read memory bandwidth. > This is done by parsing the > /sys/bus/event_source/devices/uncore_imc_/events/cas_count_read > file for

Re: [PATCH v3 0/5] selftests: gitignore and clean target file additions

2024-09-30 Thread Javier Carrasco
On 25/09/2024 23:55, Javier Carrasco wrote: > Trivial patches to update the gitignore files unders selftests, and a > little addition to EXTRA_CLEAN under net/rds to account for the > automatically generated include.sh. > > Signed-off-by: Javier Carrasco > --- > Changes in v3: > - Split new entri

[PATCH 2/3] selftests: net: rds: add include.sh to EXTRA_CLEAN

2024-09-30 Thread Javier Carrasco
The include.sh file is generated when building the net/rds selftests, but there is no rule to delete it with the clean target. Add the file to EXTRA_CLEAN in order to remove it when required. Reviewed-by: Allison Henderson Signed-off-by: Javier Carrasco --- tools/testing/selftests/net/rds/Makef

[PATCH 3/3] selftests: net: rds: add gitignore file for include.sh

2024-09-30 Thread Javier Carrasco
The generated include.sh should be ignored by git. Create a new gitignore and add the file to the list. Reviewed-by: Allison Henderson Signed-off-by: Javier Carrasco --- tools/testing/selftests/net/rds/.gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/testing/selftests/net/rd

Re: [PATCH v3 1/5] selftests: core: add unshare_test to gitignore

2024-09-30 Thread Shuah Khan
On 9/25/24 15:55, Javier Carrasco wrote: This executable is missing from the corresponding gitignore file. Add unshare_test to the core gitignore list. Signed-off-by: Javier Carrasco --- tools/testing/selftests/core/.gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/testing

Re: [PATCH v3 5/5] selftests: exec: update gitignore for load_address

2024-09-30 Thread Shuah Khan
On 9/25/24 15:55, Javier Carrasco wrote: The name of the "load_address" objects has been modified, but the corresponding entry in the gitignore file must be updated. Update the load_address entry in the gitignore file to account for the new names, adding an exception to keep on tracking load_add

[PATCH v2 1/2] virt: pvmemcontrol: control guest physical memory properties

2024-09-30 Thread Yuanchu Xie
Pvmemcontrol provides a way for the guest to control its physical memory properties, and enables optimizations and security features. For example, the guest can provide information to the host where parts of a hugepage may be unbacked, or sensitive data may not be swapped out, etc. Pvmemcontrol al

[PATCH v2 2/2] virt: pvmemcontrol: add Yuanchu and Pasha as maintainers

2024-09-30 Thread Yuanchu Xie
The pvmemcontrol driver lives under drivers/virt/pvmemcontrol. We specify maintainers for the driver. Change-Id: I3ba78d0fefe594cd5ed6805775e6497572bb7187 Signed-off-by: Yuanchu Xie --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index aacccb3

Re: [PATCH v2 1/2] virt: pvmemcontrol: control guest physical memory properties

2024-09-30 Thread Yuanchu Xie
I made a mistake. This is supposed to be v3. On Mon, Sep 30, 2024 at 6:13 PM Yuanchu Xie wrote: > > Pvmemcontrol provides a way for the guest to control its physical memory > properties, and enables optimizations and security features. For > example, the guest can provide information to the host

Re: [PATCH bpf-next/net v7 0/3] selftests/bpf: new MPTCP subflow subtest

2024-09-30 Thread patchwork-bot+netdevbpf
Hello: This series was applied to bpf/bpf-next.git (net) by Martin KaFai Lau : On Thu, 26 Sep 2024 19:30:21 +0200 you wrote: > In this series from Geliang, modifying MPTCP BPF selftests, we have: > > - A new MPTCP subflow BPF program setting socket options per subflow: it > looks better to hav

Re: [PATCH v2 00/19] iommufd: Add VIOMMU infrastructure (Part-1)

2024-09-30 Thread Alexey Kardashevskiy
On 11/9/24 17:08, Nicolin Chen wrote: On Wed, Sep 11, 2024 at 06:12:21AM +, Tian, Kevin wrote: From: Nicolin Chen Sent: Wednesday, August 28, 2024 1:00 AM [...] On a multi-IOMMU system, the VIOMMU object can be instanced to the number of vIOMMUs in a guest VM, while holding the same pare

Re: [PATCH bpf-next v2 2/2] bpf, selftests: Add test case for cgroup skb to get net_cls classid helpers

2024-09-30 Thread Martin KaFai Lau
On 9/18/24 12:45 AM, Feng zhou wrote: From: Feng Zhou This patch adds a test for cgroup skb to get classid. Signed-off-by: Feng Zhou --- .../bpf/prog_tests/cg_skb_get_classid.c | 87 +++ .../selftests/bpf/progs/cg_skb_get_classid.c | 19 2 files changed, 106 in

Re: [PATCH V2 03/13] selftests/resctrl: Fix memory overflow due to unhandled wraparound

2024-09-30 Thread Ilpo Järvinen
On Thu, 12 Sep 2024, Reinette Chatre wrote: > alloc_buffer() allocates and initializes (with random data) a > buffer of requested size. The initialization starts from the beginning > of the allocated buffer and incrementally assigns sizeof(uint64_t) random > data to each cache line. The initializa

Re: [RFC PATCH 0/3] introduce PIDFD_SELF

2024-09-30 Thread Lorenzo Stoakes
On Mon, Sep 30, 2024 at 04:21:23PM GMT, Aleksa Sarai wrote: > On 2024-09-30, Lorenzo Stoakes wrote: > > On Mon, Sep 30, 2024 at 02:34:33PM GMT, Christian Brauner wrote: > > > On Mon, Sep 30, 2024 at 11:39:49AM GMT, Lorenzo Stoakes wrote: > > > > On Mon, Sep 30, 2024 at 12:33:18PM GMT, Florian Weim

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

2024-09-30 Thread Aleksandr Mikhalitsyn
On Mon, Sep 30, 2024 at 4:05 PM Michael S. Tsirkin wrote: > > On Mon, Sep 30, 2024 at 02:28:30PM +0200, Aleksandr Mikhalitsyn wrote: > > On Sun, Sep 29, 2024 at 9:03 PM Michael S. Tsirkin wrote: > > > > > > On Sun, Sep 29, 2024 at 08:21:03PM +0200, Alexander Mikhalitsyn wrote: > > > > Add an expl

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

2024-09-30 Thread Jonas Oberhauser
Am 9/28/2024 um 4:49 PM schrieb Alan Stern: On Sat, Sep 28, 2024 at 09:51:27AM -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 pre

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

2024-09-30 Thread Jonas Oberhauser
Am 9/30/2024 um 1:04 PM schrieb Paul E. McKenney: On Mon, Sep 30, 2024 at 11:42:11AM +0200, Jonas Oberhauser wrote: I also currently don't see any major difference between the constant and register case. The point is that the address is known before loading into b, and hence the compiler +

Re: [PATCH V2 06/13] selftests/resctrl: Remove "once" parameter required to be false

2024-09-30 Thread Reinette Chatre
Hi Ilpo, On 9/30/24 6:49 AM, Ilpo Järvinen wrote: > On Thu, 12 Sep 2024, Reinette Chatre wrote: > >> The CMT, MBM, and MBA tests rely on a benchmark that runs while >> the test makes changes to needed configuration (for example memory >> bandwidth allocation) and takes needed measurements. By def

Re: [PATCH v2 00/19] iommufd: Add VIOMMU infrastructure (Part-1)

2024-09-30 Thread Alexey Kardashevskiy
On 1/10/24 13:36, Nicolin Chen wrote: On Tue, Oct 01, 2024 at 11:55:59AM +1000, Alexey Kardashevskiy wrote: On 11/9/24 17:08, Nicolin Chen wrote: On Wed, Sep 11, 2024 at 06:12:21AM +, Tian, Kevin wrote: From: Nicolin Chen Sent: Wednesday, August 28, 2024 1:00 AM [...] On a multi-IOM

Re: [RFC PATCH 0/3] introduce PIDFD_SELF

2024-09-30 Thread Aleksa Sarai
On 2024-09-30, Lorenzo Stoakes wrote: > On Mon, Sep 30, 2024 at 02:34:33PM GMT, Christian Brauner wrote: > > On Mon, Sep 30, 2024 at 11:39:49AM GMT, Lorenzo Stoakes wrote: > > > On Mon, Sep 30, 2024 at 12:33:18PM GMT, Florian Weimer wrote: > > > > * Lorenzo Stoakes: > > > > > > > > > If you wish t

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

2024-09-30 Thread Stefano Garzarella
On Sun, Sep 29, 2024 at 08:21:03PM GMT, Alexander Mikhalitsyn wrote: Add an explicit MODULE_VERSION("0.0.1") specification for the vhost_vsock module. It is useful because it allows userspace to check if vhost_vsock is there when it is configured as a built-in. This is what we have *without*

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

2024-09-30 Thread Aleksandr Mikhalitsyn
On Sun, Sep 29, 2024 at 9:03 PM Michael S. Tsirkin wrote: > > On Sun, Sep 29, 2024 at 08:21:03PM +0200, Alexander Mikhalitsyn wrote: > > Add an explicit MODULE_VERSION("0.0.1") specification for the vhost_vsock > > module. > > > > It is useful because it allows userspace to check if vhost_vsock i

Re: [RFC PATCH 0/3] introduce PIDFD_SELF

2024-09-30 Thread Lorenzo Stoakes
On Mon, Sep 30, 2024 at 02:34:33PM GMT, Christian Brauner wrote: > On Mon, Sep 30, 2024 at 11:39:49AM GMT, Lorenzo Stoakes wrote: > > On Mon, Sep 30, 2024 at 12:33:18PM GMT, Florian Weimer wrote: > > > * Lorenzo Stoakes: > > > > > > > If you wish to utilise a pidfd interface to refer to the current

Re: [PATCH V2 08/13] selftests/resctrl: Remove unused measurement code

2024-09-30 Thread Ilpo Järvinen
On Thu, 12 Sep 2024, Reinette Chatre wrote: > The MBM and MBA resctrl selftests run a benchmark during which > it takes measurements of read memory bandwidth via perf. > Code exists to support measurements of write memory bandwidth > but there exists no path with which this code can execute. > >

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

2024-09-30 Thread Michael S. Tsirkin
On Mon, Sep 30, 2024 at 02:28:30PM +0200, Aleksandr Mikhalitsyn wrote: > On Sun, Sep 29, 2024 at 9:03 PM Michael S. Tsirkin wrote: > > > > On Sun, Sep 29, 2024 at 08:21:03PM +0200, Alexander Mikhalitsyn wrote: > > > Add an explicit MODULE_VERSION("0.0.1") specification for the vhost_vsock > > > m

Re: [PATCH v2 00/19] iommufd: Add VIOMMU infrastructure (Part-1)

2024-09-30 Thread Nicolin Chen
On Tue, Oct 01, 2024 at 11:55:59AM +1000, Alexey Kardashevskiy wrote: > On 11/9/24 17:08, Nicolin Chen wrote: > > On Wed, Sep 11, 2024 at 06:12:21AM +, Tian, Kevin wrote: > > > > From: Nicolin Chen > > > > Sent: Wednesday, August 28, 2024 1:00 AM > > > > > > > [...] > > > > On a multi-IOMMU s

Re: [PATCH] remoteproc: qcom: Fix NULL pointer in glink_subdev_stop()

2024-09-30 Thread Mukesh Ojha
On Fri, Sep 27, 2024 at 02:59:09PM -0700, Bjorn Andersson wrote: > On Sat, Sep 28, 2024 at 01:07:43AM +0530, Mukesh Ojha wrote: > > On Wed, Sep 25, 2024 at 08:41:55PM -0700, Bjorn Andersson wrote: > > > On Wed, Sep 25, 2024 at 04:03:51PM +0530, Mukesh Ojha wrote: > > > > Multiple call to glink_subd

Re: [PATCH net-next] selftests: net: csum: Clean up recv_verify_packet_ipv6

2024-09-30 Thread Sean Anderson
On 9/30/24 13:16, Willem de Bruijn wrote: > Sean Anderson wrote: >> Rename ip_len to payload_len since the length in this case refers only >> to the payload, and not the entire IP packet like for IPv4. While we're >> at it, just use the variable directly when calling >> recv_verify_packet_udp/tcp.

Re: [PATCH v3 2/2] cgroup/rstat: Selftests for niced CPU statistics

2024-09-30 Thread Joshua Hahn
On Thu, Sep 26, 2024 at 2:10 PM Michal Koutný wrote: > > On Mon, Sep 23, 2024 at 07:20:06AM GMT, Joshua Hahn > wrote: > > +/* > > + * Creates a nice process that consumes CPU and checks that the elapsed > > + * usertime in the cgroup is close to the expected time. > > + */ > > + user_usec =

Re: [PATCH] selftests: timers: improve timer_create failure message

2024-09-30 Thread Shuah Khan
On 8/29/24 09:37, Gianfranco Trad wrote: improve timer_create failure message with strerror() function to give more information to the user. Signed-off-by: Gianfranco Trad --- tools/testing/selftests/timers/alarmtimer-suspend.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff

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

2024-09-30 Thread Guenter Roeck
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()") cause a lockup on boot on several architectures when the kunit tests are configured to be built-in and not module

Re: update core.c

2024-09-30 Thread Shuah Khan
On 9/29/24 16:40, Okan Tümüklü wrote: 1:The control flow was simplified by using else if statements instead of goto structure. 2:Error conditions are handled more clearly. 3:The device_unlock call at the end of the function is guaranteed in all cases. Github request : https://github.com/torva

Re: [PATCH v3 0/2] Properly initialize speed/duplex and remove vDPA config updates

2024-09-30 Thread Carlos Bilbao
On 9/11/24 11:55 AM, Carlos Bilbao wrote: > Hello, > > On 9/10/24 10:42 PM, Jason Wang wrote: >> On Tue, Sep 10, 2024 at 2:29 PM Michael S. Tsirkin wrote: >>> On Wed, Sep 04, 2024 at 10:11:13AM -0500, Carlos Bilbao wrote: From: Carlos Bilbao Initialize speed and duplex for virtio_

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

2024-09-30 Thread Guenter Roeck
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()") cause a lockup on boot on several architectures when the kunit tests are

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

2024-09-30 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

[PATCH] KVM: selftests: Fix build on architectures other than x86_64

2024-09-30 Thread Mark Brown
QUIRKS2) & KVM_X86_QUIRK_SLOT_ZAP_ALL); break; +#endif case 's': targs->nslots = atoi_paranoid(optarg); if (targs->nslots <= 1 && targs->nslots !=

Re: [PATCH] selftests: timers: improve timer_create failure message

2024-09-30 Thread Shuah Khan
On 9/30/24 13:19, John Stultz wrote: On Mon, Sep 30, 2024 at 11:49 AM Shuah Khan wrote: Jon, Does this look good to you? I can pick this up if you okay with this change. No objection from me, sorry this slipped by me. Acked-by: John Stultz Thank you. Applied to linux-kselftest next fo

Re: [PATCH] selftest: hid: add missing run-hid-tools-tests.sh

2024-09-30 Thread Shuah Khan
On 9/30/24 02:38, Benjamin Tissoires wrote: On Sep 29 2024, Yun Lu wrote: The HID test cases actually run tests using the run-hid-tools-tests.sh script. However, if installed with "make install", the run-hid-tools-tests.sh script will not be copied over, resulting in the following error message.

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

2024-09-30 Thread Josh Poimboeuf
On Sun, Sep 29, 2024 at 10:43:34PM +0800, Wardenjohn wrote: > Add "stack_order" sysfs attribute which holds the order in which a live > patch module was loaded into the system. A user can then determine an > active live patched version of a function. > > cat /sys/kernel/livepatch/livepatch_1/stack

Re: [PATCH net-next] selftests: net: csum: Clean up recv_verify_packet_ipv6

2024-09-30 Thread Willem de Bruijn
Sean Anderson wrote: > On 9/30/24 13:16, Willem de Bruijn wrote: > > Sean Anderson wrote: > >> Rename ip_len to payload_len since the length in this case refers only > >> to the payload, and not the entire IP packet like for IPv4. While we're > >> at it, just use the variable directly when calling

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

2024-09-30 Thread Alan Stern
On Mon, Sep 30, 2024 at 07:05:06PM +0200, Jonas Oberhauser wrote: > > > Am 9/30/2024 um 6:43 PM schrieb Alan Stern: > > On Mon, Sep 30, 2024 at 01:26:53PM +0200, Jonas Oberhauser wrote: > > > > > > > > > Am 9/28/2024 um 4:49 PM schrieb Alan Stern: > > > > > > I should also point out that it is

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

2024-09-30 Thread Jacob Keller
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] == 037fffadfd60 > # list_test_li

Re: [PATCH] selftests: timers: improve timer_create failure message

2024-09-30 Thread John Stultz
On Mon, Sep 30, 2024 at 11:49 AM Shuah Khan wrote: > > On 8/29/24 09:37, Gianfranco Trad wrote: > > improve timer_create failure message with strerror() function > > to give more information to the user. > > > > Signed-off-by: Gianfranco Trad > > --- > > tools/testing/selftests/timers/alarmtime

Re: [PATCH v2 1/2] exec: add a flag for "reasonable" execveat() comm

2024-09-30 Thread Eric W. Biederman
"Eric W. Biederman" writes: > Kees Cook writes: >> I'm not super comfortable doing this regardless of bprm->fdpath; that >> seems like too many cases getting changed. Can we just leave it as >> depending on bprm->fdpath? I was recommending that because I did not expect that there was any wides

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

2024-09-30 Thread Andrew Lunn
> > >Hi Stefano, > > > > > >> > > >> I was looking at other commits to see how versioning is handled in order > > >> to make sense (e.g. using the same version of the kernel), and I saw > > >> many commits that are removing MODULE_VERSION because they say it > > >> doesn't make sense in in-tree mod

Re: [PATCH v2 00/19] iommufd: Add VIOMMU infrastructure (Part-1)

2024-09-30 Thread Nicolin Chen
On Sun, Sep 29, 2024 at 03:16:55PM +0800, Yi Liu wrote: > > > > I feel these two might act somehow similarly to the two DIDs > > > > during nested translations? > > > > > > not quite the same. Is it possible that the ASID is the same for stage-1? > > > Intel VT-d side can have the pasid to be the

Re: [PATCH 05/35] libnvdimm: Reorganize kerneldoc parameter names

2024-09-30 Thread Ira Weiny
Julia Lawall wrote: > Reorganize kerneldoc parameter names to match the parameter > order in the function header. > > Problems identified using Coccinelle. > > Signed-off-by: Julia Lawall Acked-by: Ira Weiny > > --- > drivers/nvdimm/dimm_devs.c |2 +- > 1 file changed, 1 insertion(+), 1

Re: [PATCH bpf-next v3 1/2] bpf: Fix bpf_get/setsockopt to tos not take effect when TCP over IPv4 via INET6 API

2024-09-30 Thread Martin KaFai Lau
On 9/14/24 3:32 AM, Feng zhou wrote: From: Feng Zhou when TCP over IPv4 via INET6 API, bpf_get/setsockopt with ipv4 will I think you meant bpf_get/setsockopt with SOL_IP will fail. so s/ipv4/SOL_IP/? fail, because sk->sk_family is AF_INET6. With ipv6 will success, not take effect, because i

Re: [PATCH bpf-next v3 2/2] selftests/bpf: Setget_sockopt add a test for tcp over ipv4 via ipv6

2024-09-30 Thread Martin KaFai Lau
On 9/14/24 3:32 AM, Feng zhou wrote: From: Feng Zhou This patch adds a test for TCP over IPv4 via INET6 API. Signed-off-by: Feng Zhou --- .../selftests/bpf/prog_tests/setget_sockopt.c | 33 +++ .../selftests/bpf/progs/setget_sockopt.c | 13 ++-- 2 files changed, 4

Re: [PATCH] selftest: hid: add missing run-hid-tools-tests.sh

2024-09-30 Thread luyun
在 2024/10/1 04:57, Shuah Khan 写道: On 9/30/24 02:38, Benjamin Tissoires wrote: On Sep 29 2024, Yun Lu wrote: The HID test cases actually run tests using the run-hid-tools-tests.sh script. However, if installed with "make install", the run-hid-tools-tests.sh script will not be copied over, res