Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Nicolin Chen
On Thu, Jun 12, 2025 at 08:31:38PM -0300, Jason Gunthorpe wrote: > On Thu, Jun 12, 2025 at 12:03:14PM -0700, Nicolin Chen wrote: > > On Thu, Jun 12, 2025 at 03:56:13PM -0300, Jason Gunthorpe wrote: > > > On Thu, Jun 12, 2025 at 11:53:24AM -0700, Nicolin Chen wrote: > > > > @@ -2022,7 +2023,19 @@ FI

[PATCH] virtio_fs: Remove redundant spinlock in virtio_fs_request_complete()

2025-06-12 Thread lirongqing
From: Li RongQing Since clear_bit is an atomic operation, the spinlock is redundant and can be removed, reducing lock contention is good for performance. Signed-off-by: Li RongQing --- fs/fuse/virtio_fs.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/fs/fuse/virtio_fs.c b/fs/fuse/virtio

[PATCH v3 10/10] selftests/sched_ext: Add test for sched_ext dl_server

2025-06-12 Thread Joel Fernandes
From: Andrea Righi Add a selftest to validate the correct behavior of the deadline server for the ext_sched_class. [ Joel: Replaced occurences of CFS in the test with EXT. ] Signed-off-by: Joel Fernandes Signed-off-by: Andrea Righi --- tools/testing/selftests/sched_ext/Makefile| 1 + .

[PATCH net-next v1 4/4] selftests: devmem: add ipv4 support to chunks test

2025-06-12 Thread Mina Almasry
Add ipv4 support to the recently added chunks tests, which was added as ipv6 only. Signed-off-by: Mina Almasry --- tools/testing/selftests/drivers/net/hw/devmem.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/testing/selftests/drivers/net/hw/devmem.py b/tools/

[PATCH net-next v1 3/4] selftests: devmem: remove unused variable

2025-06-12 Thread Mina Almasry
Trivial fix to unused variable. Signed-off-by: Mina Almasry --- tools/testing/selftests/drivers/net/hw/ncdevmem.c | 1 - 1 file changed, 1 deletion(-) diff --git a/tools/testing/selftests/drivers/net/hw/ncdevmem.c b/tools/testing/selftests/drivers/net/hw/ncdevmem.c index 02e4d3d7ded2..cc9b40d9

[PATCH net-next v1 2/4] netmem: fix netmem comments

2025-06-12 Thread Mina Almasry
Trivial fix to a couple of outdated netmem comments. No code changes, just more accurately describing current code. Signed-off-by: Mina Almasry --- include/net/netmem.h | 21 - 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/include/net/netmem.h b/include/net/n

[PATCH net-next v1 1/4] net: netmem: fix skb_ensure_writable with unreadable skbs

2025-06-12 Thread Mina Almasry
skb_ensure_writable actually makes sure that the header of the skb is writable, and doesn't touch the payload. It doesn't need an skb_frags_readable check. Removing this check restores DSCP functionality with unreadable skbs as it's called from dscp_tg. Fixes: 65249feb6b3d ("net: add support for

Re: [PATCH v2 1/2] selftests: khugepaged: fix the shmem collapse failure

2025-06-12 Thread Dev Jain
On 13/06/25 7:19 am, Baolin Wang wrote: When running the khugepaged selftest for shmem (./khugepaged all:shmem), I encountered the following test failures: " Run test: collapse_full (khugepaged:shmem) Collapse multiple fully populated PTE table Fail ... Run test: collapse_single_pte_entry (

[PATCH net-next v2 3/3] test/vsock: Add ioctl SIOCINQ tests

2025-06-12 Thread Xuewei Niu
This patch adds SIOCINQ ioctl tests for both SOCK_STREAM and SOCK_SEQPACKET. The client waits for the server to send data, and checks if the SIOCINQ ioctl value matches the data size. After consuming the data, the client checks if the SIOCINQ value is 0. Signed-off-by: Xuewei Niu --- tools/test

[PATCH net-next v2 2/3] vsock/virtio: Add SIOCINQ support for all virtio based transports

2025-06-12 Thread Xuewei Niu
The value of the SIOCINQ is obtained by `virtio_transport_unread_bytes()`, which is generic for all virtio transports. The function acquires the `rx_lock` and returns the value of `rx_bytes`. Signed-off-by: Xuewei Niu --- drivers/vhost/vsock.c | 1 + include/linux/virtio_vsock

[PATCH net-next v2 1/3] vsock: Add support for SIOCINQ ioctl

2025-06-12 Thread Xuewei Niu
This patch adds support for SIOCINQ ioctl, which returns the number of bytes unread in the socket. Signed-off-by: Xuewei Niu --- include/net/af_vsock.h | 2 ++ net/vmw_vsock/af_vsock.c | 22 ++ 2 files changed, 24 insertions(+) diff --git a/include/net/af_vsock.h b/includ

[PATCH net-next v2 0/3] vsock: Introduce SIOCINQ ioctl support

2025-06-12 Thread Xuewei Niu
This patchset introduces SIOCINQ ioctl support for vsock, indicating the length of unread bytes. Similar with SIOCOUTQ ioctl, the information is transport-dependent. The first patch introduces a new callback, unread_bytes, in vsock transport, and adds ioctl support in AF_VSOCK. The second patch

[PATCH V5 2/2] KVM: selftests: Change MDSCR_EL1 register holding variables as uint64_t

2025-06-12 Thread Anshuman Khandual
Change MDSCR_EL1 register holding local variables as uint64_t that reflects its true register width as well. Cc: Marc Zyngier Cc: Oliver Upton Cc: Joey Gouly Cc: k...@vger.kernel.org Cc: kvm...@lists.linux.dev Cc: linux-kernel@vger.kernel.org Cc: linux-kselft...@vger.kernel.org Cc: linux-arm-ke

Re: [PATCH net-next RFC] selftests: net: add netpoll basic functionality test

2025-06-12 Thread Willem de Bruijn
s_per_s = check_traffic_flowing(cfg, netdevnl) > +with open("/dev/kmsg", "w", encoding="utf-8") as kmsg: > +kmsg.write(f"netcons test #{i}: ({pkts_per_s} packets/s)\n") > + > + > +def test_netpoll(cfg: NetDrvEpEnv, netdevnl: NetdevFam

Re: [PATCH v4 7/7] cxl/dax: Defer DAX consumption of SOFT RESERVED resources until after CXL region creation

2025-06-12 Thread Zhijian Li (Fujitsu)
Hi Smita, Nathan, Terry I am struggling to understand if this patch is truly necessary, or if I haven't fully grasped the scenario where it provides value. Without applying this patch on a QEMU/VM with both HMEM and CXL.mem installed, I observed no issues. (Are there specific config options requi

Re: [PATCH] virtio: document ENOSPC

2025-06-12 Thread Xuan Zhuo
On Tue, 27 May 2025 10:27:19 -0400, "Michael S. Tsirkin" wrote: > drivers handle ENOSPC specially since it's an error one can > get from a working VQ. Document the semantics. > > Reported-by: Parav Pandit > Signed-off-by: Michael S. Tsirkin Reviewed-by: Xuan Zhuo > --- > drivers/virtio/virt

Re: [PATCH net] virtio-net: drop the multi-buffer XDP packet in zerocopy

2025-06-12 Thread Xuan Zhuo
On Tue, 3 Jun 2025 22:06:13 +0700, Bui Quang Minh wrote: > In virtio-net, we have not yet supported multi-buffer XDP packet in > zerocopy mode when there is a binding XDP program. However, in that > case, when receiving multi-buffer XDP packet, we skip the XDP program > and return XDP_PASS. As a

[PATCH v2 1/2] selftests: khugepaged: fix the shmem collapse failure

2025-06-12 Thread Baolin Wang
When running the khugepaged selftest for shmem (./khugepaged all:shmem), I encountered the following test failures: " Run test: collapse_full (khugepaged:shmem) Collapse multiple fully populated PTE table Fail ... Run test: collapse_single_pte_entry (khugepaged:shmem) Collapse PTE table with si

[PATCH v2 2/2] selftests: mm: add shmem collapse as a default test item

2025-06-12 Thread Baolin Wang
Currently, we only test anonymous memory collapse by default. We should also add shmem collapse as a default test item to catch issues that could break the test cases. Reviewed-by: Dev Jain Tested-by: Dev Jain Acked-by: David Hildenbrand Acked-by: Zi Yan Signed-off-by: Baolin Wang --- Changes

Re: [PATCH 1/2] selftests: khugepaged: fix the shmem collapse failure

2025-06-12 Thread Baolin Wang
On 2025/6/12 23:46, Zi Yan wrote: On 11 Jun 2025, at 23:54, Baolin Wang wrote: When running the khugepaged selftest for shmem (./khugepaged all:shmem), I encountered the following test failures: " Run test: collapse_full (khugepaged:shmem) Collapse multiple fully populated PTE table Fail

Re: [PATCH v2 1/3] virtio: Fix typo in register_virtio_device() doc comment

2025-06-12 Thread Xuan Zhuo
On Thu, 29 May 2025 01:42:39 -0700, Alok Tiwari wrote: > Corrected "suceess" to "success" in the function documentation > for clarity. > > Signed-off-by: Alok Tiwari > Acked-by: Jason Wang Reviewed-by: Xuan Zhuo > --- > v1 -> v2 > No changes; only added Acked-by: Jason Wang. > --- > drivers

Re: [PATCH net-next] selftests: tcp_ao: fix spelling in seq-ext.c comment

2025-06-12 Thread patchwork-bot+netdevbpf
Hello: This patch was applied to netdev/net-next.git (main) by Jakub Kicinski : On Tue, 10 Jun 2025 12:49:03 +0530 you wrote: > Spelling fix: > conneciton --> connection > > This is a non-functional change aimed at improving code clarity. > > Signed-off-by: Ankit Chauhan > > [...] Here is th

Re: [RFC 3/6] vduse: add vq group asid support

2025-06-12 Thread Jason Wang
On Thu, Jun 12, 2025 at 3:25 PM Eugenio Perez Martin wrote: > > On Thu, Jun 12, 2025 at 2:30 AM Jason Wang wrote: > > > > On Fri, Jun 6, 2025 at 7:50 PM Eugenio Pérez wrote: > > > > > > Make one IOTLB domain per address space, and allow the driver to assign > > > each ASID to a vq group. Each a

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Jason Gunthorpe
On Thu, Jun 12, 2025 at 12:03:14PM -0700, Nicolin Chen wrote: > On Thu, Jun 12, 2025 at 03:56:13PM -0300, Jason Gunthorpe wrote: > > On Thu, Jun 12, 2025 at 11:53:24AM -0700, Nicolin Chen wrote: > > > @@ -2022,7 +2023,19 @@ FIXTURE_SETUP(iommufd_dirty_tracking) > > > self->fd = open("/dev/i

[PATCH 3/3] arm64: dts: qcom: msm8976-longcheer-l9360: Add initial device tree

2025-06-12 Thread André Apitzsch via B4 Relay
From: André Apitzsch This dts adds support for BQ Aquaris X5 Plus (Longcheer L9360) released in 2016. Add a device tree with initial support for: - GPIO keys - NFC - SDHCI - Status LED - Touchscreen Signed-off-by: André Apitzsch --- arch/arm64/boot/dts/qcom/Makefile | 1 +

[PATCH 0/3] arm64: dts: qcom: msm8976-longcheer-l9360: Add initial device tree

2025-06-12 Thread André Apitzsch via B4 Relay
-l9360.dts | 532 + arch/arm64/boot/dts/qcom/msm8976.dtsi | 2 + 4 files changed, 540 insertions(+) --- base-commit: 0bb71d301869446810a0b13d3da290bd455d7c78 change-id: 20250612-bqx5plus-d72e11f5877c Best regards, -- André Apitzsch

[PATCH 1/3] arm64: dts: qcom: msm8976: Make blsp_dma controlled-remotely

2025-06-12 Thread André Apitzsch via B4 Relay
From: André Apitzsch The blsp_dma controller is shared between the different subsystems, which is why it is already initialized by the firmware. We should not reinitialize it from Linux to avoid potential other users of the DMA engine to misbehave. In mainline this can be described using the "qc

[PATCH 2/3] dt-bindings: arm: qcom: Add MSM8976 BQ Aquaris X5 Plus

2025-06-12 Thread André Apitzsch via B4 Relay
From: André Apitzsch BQ Aquaris X5 Plus (Longcheer L9360) is a smartphone based on MSM8976 SoC. Signed-off-by: André Apitzsch --- Documentation/devicetree/bindings/arm/qcom.yaml | 5 + 1 file changed, 5 insertions(+) diff --git a/Documentation/devicetree/bindings/arm/qcom.yaml b/Document

Re: [PATCH net-next v2 7/7] selftest: netconsole: add test for cmdline configuration

2025-06-12 Thread Jakub Kicinski
On Wed, 11 Jun 2025 07:18:56 -0700 Breno Leitao wrote: > Add a new selftest to verify netconsole module loading with command > line arguments. This test exercises the init_netconsole() path and > validates proper parsing of the netconsole= parameter format. > > The test: > - Loads netconsole modul

Re: [RFC PATCH 1/1] nvdimm: allow exposing RAM carveouts as NVDIMM DIMM devices

2025-06-12 Thread jane . chu
On 6/12/2025 1:31 AM, Mike Rapoport wrote: From: "Mike Rapoport (Microsoft)" There are use cases, for example virtual machine hosts, that create "persistent" memory regions using memmap= option on x86 or dummy pmem-region device tree nodes on DT based systems. Both these options are inflexib

Re: [PATCH 1/3] rcu: Return early if callback is not specified

2025-06-12 Thread Boqun Feng
On Thu, Jun 12, 2025 at 07:46:12PM +0200, Uladzislau Rezki wrote: > On Thu, Jun 12, 2025 at 10:30:38AM -0700, Boqun Feng wrote: > > > > > > On Tue, Jun 10, 2025, at 12:33 PM, Joel Fernandes wrote: > > > On 6/10/2025 1:34 PM, Uladzislau Rezki (Sony) wrote: > > >> Currently the call_rcu() API does

Re: [PATCH v2 00/62] objtool,livepatch: klp-build livepatch module generation

2025-06-12 Thread Josh Poimboeuf
On Fri, May 09, 2025 at 01:16:24PM -0700, Josh Poimboeuf wrote: > I've tested with a variety of patches on defconfig and Fedora-config > kernels with both GCC and Clang. > > These patches can also be found at: > > git://git.kernel.org/pub/scm/linux/kernel/git/jpoimboe/linux.git > klp-build-v2

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Nicolin Chen
On Thu, Jun 12, 2025 at 03:56:13PM -0300, Jason Gunthorpe wrote: > On Thu, Jun 12, 2025 at 11:53:24AM -0700, Nicolin Chen wrote: > > @@ -2022,7 +2023,19 @@ FIXTURE_SETUP(iommufd_dirty_tracking) > > self->fd = open("/dev/iommu", O_RDWR); > > ASSERT_NE(-1, self->fd); > > > > -

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Jason Gunthorpe
On Thu, Jun 12, 2025 at 11:53:24AM -0700, Nicolin Chen wrote: > @@ -2022,7 +2023,19 @@ FIXTURE_SETUP(iommufd_dirty_tracking) > self->fd = open("/dev/iommu", O_RDWR); > ASSERT_NE(-1, self->fd); > > - rc = posix_memalign(&self->buffer, HUGEPAGE_SIZE, > variant->buffer_size); >

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Nicolin Chen
On Thu, Jun 12, 2025 at 10:53:34AM -0700, Nicolin Chen wrote: > On Thu, Jun 12, 2025 at 12:42:42PM -0300, Jason Gunthorpe wrote: > > On Thu, Jun 12, 2025 at 05:23:01PM +0200, Thomas Weißschuh wrote: > > > On Thu, Jun 12, 2025 at 11:58:01AM -0300, Jason Gunthorpe wrote: > > > > On Thu, Jun 12, 2025

Re: [PATCH v2 59/62] livepatch/klp-build: Introduce klp-build script for generating livepatch modules

2025-06-12 Thread Joe Lawrence
On 6/11/25 7:12 PM, Josh Poimboeuf wrote: > > Hm, revert_patch() already has a call to git_refresh(), so there doesn't > appear to be any point to that extra refresh in revert_patches(). > > Does this fix? > > diff --git a/scripts/livepatch/klp-build b/scripts/livepatch/klp-build > index 7ec07c4

Re: [PATCH v4 0/2] x86/fred: Prevent single-step upon ERETU completion

2025-06-12 Thread Xin Li
On 6/5/2025 2:51 PM, Sohil Mehta wrote: Xin Li (Intel) (2): x86/fred/signal: Prevent single-step upon ERETU completion selftests/x86: Add a test to detect infinite sigtrap handler loop I tested the patches on a machine that supports FRED. The results are as expected: Seeing a split lock

Re: [PATCH v2 3/3] mm/huge_memory: don't mark refcounted folios special in vmf_insert_folio_pud()

2025-06-12 Thread Jason Gunthorpe
On Wed, Jun 11, 2025 at 02:06:54PM +0200, David Hildenbrand wrote: > Marking PUDs that map a "normal" refcounted folios as special is > against our rules documented for vm_normal_page(). > > Fortunately, there are not that many pud_special() check that can be > mislead and are right now rather har

Re: [PATCH v2 2/3] mm/huge_memory: don't mark refcounted folios special in vmf_insert_folio_pmd()

2025-06-12 Thread Jason Gunthorpe
On Wed, Jun 11, 2025 at 02:06:53PM +0200, David Hildenbrand wrote: > Marking PMDs that map a "normal" refcounted folios as special is > against our rules documented for vm_normal_page(). > > Fortunately, there are not that many pmd_special() check that can be > mislead, and most vm_normal_page_pmd

Re: [PATCH v2 1/3] mm/huge_memory: don't ignore queried cachemode in vmf_insert_pfn_pud()

2025-06-12 Thread Jason Gunthorpe
On Wed, Jun 11, 2025 at 02:06:52PM +0200, David Hildenbrand wrote: > We setup the cache mode but ... don't forward the updated pgprot to > insert_pfn_pud(). > > Only a problem on x86-64 PAT when mapping PFNs using PUDs that > require a special cachemode. > > Fix it by using the proper pgprot wher

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Nicolin Chen
On Thu, Jun 12, 2025 at 12:42:42PM -0300, Jason Gunthorpe wrote: > On Thu, Jun 12, 2025 at 05:23:01PM +0200, Thomas Weißschuh wrote: > > On Thu, Jun 12, 2025 at 11:58:01AM -0300, Jason Gunthorpe wrote: > > > On Thu, Jun 12, 2025 at 04:27:41PM +0200, Thomas Weißschuh wrote: > > > > > > > If the ass

Re: [PATCH 1/3] rcu: Return early if callback is not specified

2025-06-12 Thread Uladzislau Rezki
On Thu, Jun 12, 2025 at 10:30:38AM -0700, Boqun Feng wrote: > > > On Tue, Jun 10, 2025, at 12:33 PM, Joel Fernandes wrote: > > On 6/10/2025 1:34 PM, Uladzislau Rezki (Sony) wrote: > >> Currently the call_rcu() API does not check whether a callback > >> pointer is NULL. If NULL is passed, rcu_core

Re: [PATCH v2 3/3] mm/huge_memory: don't mark refcounted folios special in vmf_insert_folio_pud()

2025-06-12 Thread David Hildenbrand
On 12.06.25 19:08, Lorenzo Stoakes wrote: On Thu, Jun 12, 2025 at 07:00:01PM +0200, David Hildenbrand wrote: On 12.06.25 18:49, Lorenzo Stoakes wrote: On Wed, Jun 11, 2025 at 02:06:54PM +0200, David Hildenbrand wrote: Marking PUDs that map a "normal" refcounted folios as special is against our

Re: [PATCH 1/3] rcu: Return early if callback is not specified

2025-06-12 Thread Boqun Feng
On Thu, Jun 12, 2025, at 10:30 AM, Boqun Feng wrote: > On Tue, Jun 10, 2025, at 12:33 PM, Joel Fernandes wrote: >> On 6/10/2025 1:34 PM, Uladzislau Rezki (Sony) wrote: >>> Currently the call_rcu() API does not check whether a callback >>> pointer is NULL. If NULL is passed, rcu_core() will try t

Re: [PATCH v4 1/3] pmdomain: core: introduce dev_pm_genpd_is_on

2025-06-12 Thread Hiago De Franco
On Wed, Jun 11, 2025 at 10:32:28AM -0500, Bjorn Andersson wrote: > On Mon, Jun 02, 2025 at 10:19:03AM -0300, Hiago De Franco wrote: > > From: Hiago De Franco > > > > This helper function returns the current power status of a given generic > > power domain. > > > > Please correct me if I'm wrong

Re: [PATCH 1/3] rcu: Return early if callback is not specified

2025-06-12 Thread Boqun Feng
On Tue, Jun 10, 2025, at 12:33 PM, Joel Fernandes wrote: > On 6/10/2025 1:34 PM, Uladzislau Rezki (Sony) wrote: >> Currently the call_rcu() API does not check whether a callback >> pointer is NULL. If NULL is passed, rcu_core() will try to invoke >> it, resulting in NULL pointer dereference and

Re: [PATCH bpf-next v2] selftests/bpf: fix signedness bug in redir_partial()

2025-06-12 Thread patchwork-bot+netdevbpf
Hello: This patch was applied to bpf/bpf-next.git (master) by Alexei Starovoitov : On Thu, 12 Jun 2025 16:42:08 +0800 you wrote: > When xsend() returns -1 (error), the check 'n < sizeof(buf)' incorrectly > treats it as success due to unsigned promotion. Explicitly check for -1 > first. > > Fixes

Re: [PATCH v2 3/3] mm/huge_memory: don't mark refcounted folios special in vmf_insert_folio_pud()

2025-06-12 Thread Lorenzo Stoakes
On Thu, Jun 12, 2025 at 07:00:01PM +0200, David Hildenbrand wrote: > On 12.06.25 18:49, Lorenzo Stoakes wrote: > > On Wed, Jun 11, 2025 at 02:06:54PM +0200, David Hildenbrand wrote: > > > Marking PUDs that map a "normal" refcounted folios as special is > > > against our rules documented for vm_norm

Re: [PATCH 2/2] arm64: dts: qcom: sa8775p: Correct the interrupt for remoteproc

2025-06-12 Thread Konrad Dybcio
On 6/12/25 4:39 AM, Lijuan Gao wrote: > Fix the incorrect IRQ numbers for ready and handover on sa8775p. > The correct values are as follows: > > Fatal interrupt - 0 > Ready interrupt - 1 > Handover interrupt - 2 > Stop acknowledge interrupt - 3 > > Fixes: df54dcb34ff2e ("arm64: dts: qcom: sa8775

Re: [PATCH v4 3/3] remoteproc: imx_rproc: detect and attach to pre-booted remote cores

2025-06-12 Thread Hiago De Franco
Hi Bjorn, On Wed, Jun 11, 2025 at 10:36:33AM -0500, Bjorn Andersson wrote: > On Wed, Jun 04, 2025 at 03:19:52AM +, Peng Fan wrote: > > > Subject: [PATCH v4 3/3] remoteproc: imx_rproc: detect and attach to > > > pre-booted remote cores > > > > > > From: Hiago De Franco > > > > > > When the r

Re: [PATCH v4 3/3] remoteproc: imx_rproc: detect and attach to pre-booted remote cores

2025-06-12 Thread Hiago De Franco
Hi Peng, On Wed, Jun 11, 2025 at 03:27:09AM +, Peng Fan wrote: > > > > Sorry for the delay. > > > > I tested it now and there must be something missing on my U-Boot: > > > > Disable imx8x-cm4 rsrc 278 not owned > > Disable imx8x-cm4 rsrc 297 not owned > > > > It removes my nodes from the D

Re: [PATCH v2 3/3] mm/huge_memory: don't mark refcounted folios special in vmf_insert_folio_pud()

2025-06-12 Thread David Hildenbrand
On 12.06.25 18:49, Lorenzo Stoakes wrote: On Wed, Jun 11, 2025 at 02:06:54PM +0200, David Hildenbrand wrote: Marking PUDs that map a "normal" refcounted folios as special is against our rules documented for vm_normal_page(). Might be worth referring to specifically which rule. I'm guessing it'

Re: [PATCH v2 0/3] mm/huge_memory: vmf_insert_folio_*() and vmf_insert_pfn_pud() fixes

2025-06-12 Thread Marc Herbert
> I spent too much time trying to get the ndctl tests mentioned by Dan > running (.config tweaks, memmap= setup, ... ), without getting them to > pass even without these patches. Some SKIP, some FAIL, some sometimes > suddenly SKIP on first invocation, ... instructions unclear or

[PATCH net-next RFC] selftests: net: add netpoll basic functionality test

2025-06-12 Thread Breno Leitao
_name) +do_netpoll_flush(cfg, netdevnl) +finally: +if traffic: +traffic.stop() + delete_netconsole_target(target_name) + + +def check_dependencies() -> None: +"""Check if the dependencies are met""" +if not os.path.exists(NETCONSOLE_CONFIGFS_PATH): +raise KsftSkipEx( +f"Directory {NETCONSOLE_CONFIGFS_PATH} does not exist. CONFIG_NETCONSOLE_DYNAMIC might not be set." +) + + +def main() -> None: +"""Main function to run the test""" +check_dependencies() +netdevnl = NetdevFamily() +with NetDrvEpEnv(__file__, nsim_test=True) as cfg: +ksft_run( +[test_netpoll], +args=( +cfg, +netdevnl, +), +) +ksft_exit() + + +if __name__ == "__main__": +main() --- base-commit: 5d6d67c4cb10a4b4d3ae35758d5eeed6239afdc8 change-id: 20250612-netpoll_test-a1324d2057c8 Best regards, -- Breno Leitao

Re: [PATCH v2 3/3] mm/huge_memory: don't mark refcounted folios special in vmf_insert_folio_pud()

2025-06-12 Thread Lorenzo Stoakes
On Wed, Jun 11, 2025 at 02:06:54PM +0200, David Hildenbrand wrote: > Marking PUDs that map a "normal" refcounted folios as special is > against our rules documented for vm_normal_page(). Might be worth referring to specifically which rule. I'm guessing it's the general one of special == don't touc

Re: [PATCH v2 0/3] mm/huge_memory: vmf_insert_folio_*() and vmf_insert_pfn_pud() fixes

2025-06-12 Thread Lorenzo Stoakes
On Thu, Jun 12, 2025 at 06:22:32PM +0200, David Hildenbrand wrote: > On 12.06.25 18:19, Lorenzo Stoakes wrote: > > FWIW I did a basic build/mm self tests run locally and all looking good! > > Thanks! I have another series based on this series coming up ... but > struggling to get !CONFIG_ARCH_HAS_P

Re: [PATCH v2 0/3] mm/huge_memory: vmf_insert_folio_*() and vmf_insert_pfn_pud() fixes

2025-06-12 Thread David Hildenbrand
On 12.06.25 18:19, Lorenzo Stoakes wrote: FWIW I did a basic build/mm self tests run locally and all looking good! Thanks! I have another series based on this series coming up ... but struggling to get !CONFIG_ARCH_HAS_PTE_SPECIAL tested "easily" :) -- Cheers, David / dhildenb

Re: [PATCH v2 0/3] mm/huge_memory: vmf_insert_folio_*() and vmf_insert_pfn_pud() fixes

2025-06-12 Thread Lorenzo Stoakes
FWIW I did a basic build/mm self tests run locally and all looking good! On Wed, Jun 11, 2025 at 02:06:51PM +0200, David Hildenbrand wrote: > This is v2 of > "[PATCH v1 0/2] mm/huge_memory: don't mark refcounted pages special >in vmf_insert_folio_*()" > Now with one additional fix, b

Re: [PATCH v2 2/3] mm/huge_memory: don't mark refcounted folios special in vmf_insert_folio_pmd()

2025-06-12 Thread Lorenzo Stoakes
On Wed, Jun 11, 2025 at 02:06:53PM +0200, David Hildenbrand wrote: > Marking PMDs that map a "normal" refcounted folios as special is > against our rules documented for vm_normal_page(). > > Fortunately, there are not that many pmd_special() check that can be > mislead, and most vm_normal_page_pmd(

Re: [PATCH v2 1/3] mm/huge_memory: don't ignore queried cachemode in vmf_insert_pfn_pud()

2025-06-12 Thread Lorenzo Stoakes
On Thu, Jun 12, 2025 at 05:36:35PM +0200, David Hildenbrand wrote: > On 12.06.25 17:28, Lorenzo Stoakes wrote: > > On Wed, Jun 11, 2025 at 02:06:52PM +0200, David Hildenbrand wrote: > > > We setup the cache mode but ... don't forward the updated pgprot to > > > insert_pfn_pud(). > > > > > > Only a

Re: [PATCH v2 1/3] mm/huge_memory: don't ignore queried cachemode in vmf_insert_pfn_pud()

2025-06-12 Thread David Hildenbrand
On 12.06.25 17:59, Lorenzo Stoakes wrote: On Thu, Jun 12, 2025 at 05:36:35PM +0200, David Hildenbrand wrote: On 12.06.25 17:28, Lorenzo Stoakes wrote: On Wed, Jun 11, 2025 at 02:06:52PM +0200, David Hildenbrand wrote: We setup the cache mode but ... don't forward the updated pgprot to insert_p

Re: [PATCH v2 1/3] mm/huge_memory: don't ignore queried cachemode in vmf_insert_pfn_pud()

2025-06-12 Thread Lorenzo Stoakes
On Wed, Jun 11, 2025 at 02:06:52PM +0200, David Hildenbrand wrote: > We setup the cache mode but ... don't forward the updated pgprot to > insert_pfn_pud(). > > Only a problem on x86-64 PAT when mapping PFNs using PUDs that > require a special cachemode. > > Fix it by using the proper pgprot where

Re: [PATCH 1/2] selftests: khugepaged: fix the shmem collapse failure

2025-06-12 Thread David Hildenbrand
On 12.06.25 17:46, Zi Yan wrote: On 11 Jun 2025, at 23:54, Baolin Wang wrote: When running the khugepaged selftest for shmem (./khugepaged all:shmem), I encountered the following test failures: " Run test: collapse_full (khugepaged:shmem) Collapse multiple fully populated PTE table Fail ...

Re: [PATCH 2/2] selftests: mm: add shmem collpase as a default test item

2025-06-12 Thread Zi Yan
On 11 Jun 2025, at 23:54, Baolin Wang wrote: > Currently, we only test anonymous memory collapse by default. We should also > add shmem collapse as a default test item to catch issues that could break > the test cases. > > Signed-off-by: Baolin Wang > --- > tools/testing/selftests/mm/run_vmtests

Re: [PATCH 1/2] selftests: khugepaged: fix the shmem collapse failure

2025-06-12 Thread Zi Yan
On 11 Jun 2025, at 23:54, Baolin Wang wrote: > When running the khugepaged selftest for shmem (./khugepaged all:shmem), > I encountered the following test failures: > " > Run test: collapse_full (khugepaged:shmem) > Collapse multiple fully populated PTE table Fail > ... > Run test: collapse_si

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Jason Gunthorpe
On Thu, Jun 12, 2025 at 05:23:01PM +0200, Thomas Weißschuh wrote: > On Thu, Jun 12, 2025 at 11:58:01AM -0300, Jason Gunthorpe wrote: > > On Thu, Jun 12, 2025 at 04:27:41PM +0200, Thomas Weißschuh wrote: > > > > > If the assumption is that this is most likely a kernel bug, > > > shouldn't it be fix

Re: [PATCH v2 1/3] mm/huge_memory: don't ignore queried cachemode in vmf_insert_pfn_pud()

2025-06-12 Thread David Hildenbrand
On 12.06.25 17:28, Lorenzo Stoakes wrote: On Wed, Jun 11, 2025 at 02:06:52PM +0200, David Hildenbrand wrote: We setup the cache mode but ... don't forward the updated pgprot to insert_pfn_pud(). Only a problem on x86-64 PAT when mapping PFNs using PUDs that require a special cachemode. Fix it

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Thomas Weißschuh
On Thu, Jun 12, 2025 at 11:58:01AM -0300, Jason Gunthorpe wrote: > On Thu, Jun 12, 2025 at 04:27:41PM +0200, Thomas Weißschuh wrote: > > > If the assumption is that this is most likely a kernel bug, > > shouldn't it be fixed properly rather than worked around? > > After all the job of a selftest i

[PATCH 3/3] kunit: test: Drop CONFIG_MODULE ifdeffery

2025-06-12 Thread Thomas Weißschuh
The function stubs exposed by module.h allow the code to compile properly without the ifdeffery. The generated object code stays the same, as the compiler can optimize away all the dead code. As the code is still typechecked developer errors can be detected faster. Signed-off-by: Thomas Weißschuh

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Jason Gunthorpe
On Thu, Jun 12, 2025 at 04:27:41PM +0200, Thomas Weißschuh wrote: > If the assumption is that this is most likely a kernel bug, > shouldn't it be fixed properly rather than worked around? > After all the job of a selftest is to detect bugs to be fixed. I investigated the history for a bit and it

[PATCH 1/3] module: move 'struct module_use' to internal.h

2025-06-12 Thread Thomas Weißschuh
The struct was moved to the public header file in commit c8e21ced08b3 ("module: fix kdb's illicit use of struct module_use."). Back then the structure was used outside of the module core. Nowadays this is not true anymore, so the structure can be made internal. Signed-off-by: Thomas Weißschuh ---

[PATCH 2/3] module: make structure definitions always visible

2025-06-12 Thread Thomas Weißschuh
To write code that works with both CONFIG_MODULES=y and CONFIG_MODULES=n it is convenient to use "if (IS_ENABLED(CONFIG_MODULES))" over raw #ifdef. The code will still fully typechecked but the unreachable parts are discarded by the compiler. This prevents accidental breakage when a certain kconfig

[PATCH 0/3] module: make structure definitions always visible

2025-06-12 Thread Thomas Weißschuh
Code using IS_ENABLED(CONFIG_MODULES) as a C expression may need access to the module structure definitions to compile. Make sure these structure definitions are always visible. Signed-off-by: Thomas Weißschuh --- Thomas Weißschuh (3): module: move 'struct module_use' to internal.h mo

Re: [PATCH net-next v3 1/4] udp_tunnel: remove rtnl_lock dependency

2025-06-12 Thread Jakub Kicinski
On Wed, 11 Jun 2025 19:47:54 -0700 Stanislav Fomichev wrote: > > There are multiple entry points to this code, basically each member of > > struct udp_tunnel_nic_ops and the netdev notifiers. In this patch only > > reset and work are locked. I'm a bit confused as to what is the new > > lock protect

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Thomas Weißschuh
On Thu, Jun 12, 2025 at 10:58:02AM -0300, Jason Gunthorpe wrote: > On Wed, Jun 11, 2025 at 11:59:00PM -0700, Nicolin Chen wrote: > > > We can see the 64MB was rounded up to 512MB by ksys_mmap_pgoff() > > when being passed in to hugetlb_file_setup() at: > > https://git.kernel.org/pub/scm/linux/kern

Re: [PATCH v4 09/14] selftests: harness: Move teardown conditional into test metadata

2025-06-12 Thread Jason Gunthorpe
On Wed, Jun 11, 2025 at 11:59:00PM -0700, Nicolin Chen wrote: > We can see the 64MB was rounded up to 512MB by ksys_mmap_pgoff() > when being passed in to hugetlb_file_setup() at: > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/mm/mmap.c?h=v6.16-rc1#n594 > " l

[PATCH v13 3/6] rust: module: use a reference in macros::module::module

2025-06-12 Thread Andreas Hindborg
When we add parameter support to the module macro, we want to be able to pass a reference to `ModuleInfo` to a helper function. That is not possible when we move out of the local `modinfo`. So change the function to access the local via reference rather than value. Signed-off-by: Andreas Hindborg

[PATCH v13 4/6] rust: module: update the module macro with module parameter support

2025-06-12 Thread Andreas Hindborg
Allow module parameters to be declared in the rust `module!` macro. Signed-off-by: Andreas Hindborg --- rust/macros/helpers.rs | 25 +++ rust/macros/lib.rs | 31 + rust/macros/module.rs | 175 ++--- 3 files changed, 221 insertions(+)

[PATCH v13 1/6] rust: str: add radix prefixed integer parsing functions

2025-06-12 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 Gomez Reviewed-by: Greg Kroah-Hartman Signed-off-by: Andreas Hindborg ---

[PATCH v13 2/6] rust: introduce module_param module

2025-06-12 Thread Andreas Hindborg
Add types and traits for interfacing the C moduleparam API. Signed-off-by: Andreas Hindborg --- rust/kernel/lib.rs | 1 + rust/kernel/module_param.rs | 201 2 files changed, 202 insertions(+) diff --git a/rust/kernel/lib.rs b/rust/kernel/l

[PATCH v13 5/6] rust: samples: add a module parameter to the rust_minimal sample

2025-06-12 Thread Andreas Hindborg
Showcase the rust module parameter support by adding a module parameter to the `rust_minimal` sample. Signed-off-by: Andreas Hindborg --- samples/rust/rust_minimal.rs | 10 ++ 1 file changed, 10 insertions(+) diff --git a/samples/rust/rust_minimal.rs b/samples/rust/rust_minimal.rs index

[PATCH v13 6/6] modules: add rust modules files to MAINTAINERS

2025-06-12 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 --- MA

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

2025-06-12 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

Re: [PATCH v3] mm/pagewalk: split walk_page_range_novma() into kernel/user parts

2025-06-12 Thread David Hildenbrand
On 05.06.25 15:51, Lorenzo Stoakes wrote: The walk_page_range_novma() function is rather confusing - it supports two modes, one used often, the other used only for debugging. The first mode is the common case of traversal of kernel page tables, which is what nearly all callers use this for. Sec

Re: [PATCH 1/2] selftests: khugepaged: fix the shmem collapse failure

2025-06-12 Thread Baolin Wang
On 2025/6/12 19:45, David Hildenbrand wrote: On 12.06.25 13:37, Baolin Wang wrote: On 2025/6/12 18:08, David Hildenbrand wrote: On 12.06.25 05:54, Baolin Wang wrote: When running the khugepaged selftest for shmem (./khugepaged all:shmem), Hmm, this combination is not run automatically t

Re: [PATCH 1/2] selftests: khugepaged: fix the shmem collapse failure

2025-06-12 Thread David Hildenbrand
On 12.06.25 13:37, Baolin Wang wrote: On 2025/6/12 18:08, David Hildenbrand wrote: On 12.06.25 05:54, Baolin Wang wrote: When running the khugepaged selftest for shmem (./khugepaged all:shmem), Hmm, this combination is not run automatically through run_tests.sh, right? IIUC, it only runs ".

Re: [PATCH 2/2] rcu: Fix lockup when RCU reader used while IRQ exiting

2025-06-12 Thread Frederic Weisbecker
Le Thu, Jun 12, 2025 at 11:06:07AM +0800, Xiongfeng Wang a écrit : > +cc (Qi, my colleague who helps testing the modification) > > On 2025/6/10 20:23, Frederic Weisbecker wrote: > > Le Mon, Jun 09, 2025 at 02:01:24PM -0400, Joel Fernandes a écrit : > >> During rcu_read_unlock_special(), if this ha

Re: [PATCH 1/2] selftests: khugepaged: fix the shmem collapse failure

2025-06-12 Thread Baolin Wang
On 2025/6/12 18:08, David Hildenbrand wrote: On 12.06.25 05:54, Baolin Wang wrote: When running the khugepaged selftest for shmem (./khugepaged all:shmem), Hmm, this combination is not run automatically through run_tests.sh, right? IIUC, it only runs "./khugepaged" which tests anon only ..

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

2025-06-12 Thread Andreas Hindborg
"Benno Lossin" writes: > On Wed Jun 11, 2025 at 12:31 PM CEST, Andreas Hindborg wrote: >> "Benno Lossin" writes: >>> On Tue May 6, 2025 at 3:02 PM CEST, Andreas Hindborg wrote: diff --git a/rust/macros/helpers.rs b/rust/macros/helpers.rs index a3ee27e29a6f..16d300ad3d3b 100644 ---

Re: [PATCH 1/2] module: Fix memory deallocation on error path in move_module()

2025-06-12 Thread Petr Pavlu
On 6/10/25 8:51 PM, Daniel Gomez wrote: > On 07/06/2025 18.16, Petr Pavlu wrote: >> The function move_module() uses the variable t to track how many memory >> types it has allocated and consequently how many should be freed if an >> error occurs. >> >> The variable is initially set to 0 and is upda

Re: [PATCH 2/2] selftests: mm: add shmem collpase as a default test item

2025-06-12 Thread David Hildenbrand
On 12.06.25 05:54, Baolin Wang wrote: Currently, we only test anonymous memory collapse by default. We should also add shmem collapse as a default test item to catch issues that could break the test cases. Signed-off-by: Baolin Wang --- tools/testing/selftests/mm/run_vmtests.sh | 4 1 f

Re: [PATCH 1/2] selftests: khugepaged: fix the shmem collapse failure

2025-06-12 Thread David Hildenbrand
On 12.06.25 05:54, Baolin Wang wrote: When running the khugepaged selftest for shmem (./khugepaged all:shmem), Hmm, this combination is not run automatically through run_tests.sh, right? IIUC, it only runs "./khugepaged" which tests anon only ... Should we add it there? Then I would probably

[PATCH v4] selftests: filesystems: Add functional test for the abort file in fusectl

2025-06-12 Thread Chen Linxuan
This patch add a simple functional test for the "abort" file in fusectlfs (/sys/fs/fuse/connections/ID/about). A simple fuse daemon is added for testing. Related discussion can be found in the link below. Link: https://lore.kernel.org/all/CAOQ4uxjKFXOKQxPpxtS6G_nR0tpw95w0GiO68UcWg_OBhmSY=q...@m

Re: [PATCH net] vsock/virtio: fix `rx_bytes` accounting for stream sockets

2025-06-12 Thread Stefano Garzarella
On Thu, Jun 12, 2025 at 04:55:14PM +0800, Xuewei Niu wrote: On Thu, 12 Jun 2025 at 10:21, Xuewei Niu wrote: > > > On Thu, 12 Jun 2025 at 08:50, Xuewei Niu wrote: > > > > > > > On Thu, Jun 12, 2025 at 01:32:01PM +0800, Xuewei Niu wrote: > > > > > No comments since last month. > > > > > > > > > >

Re: [PATCH v2 2/2] Documentation/kernel-parameters: Update rcu_normal_wake_from_gp doc

2025-06-12 Thread Uladzislau Rezki
On Wed, Jun 11, 2025 at 05:49:14PM -0400, Joel Fernandes wrote: > > > On 6/11/2025 1:56 PM, Uladzislau Rezki (Sony) wrote: > > Update the documentation about rcu_normal_wake_from_gp parameter. > > > > Signed-off-by: Uladzislau Rezki (Sony) > > Reviewed-by: Joel Fernandes > Thanks! -- Uladzi

Re: [PATCH v2 1/2] rcu: Enable rcu_normal_wake_from_gp on small systems

2025-06-12 Thread Uladzislau Rezki
On Wed, Jun 11, 2025 at 05:48:57PM -0400, Joel Fernandes wrote: > > > On 6/11/2025 1:56 PM, Uladzislau Rezki (Sony) wrote: > > Automatically enable the rcu_normal_wake_from_gp parameter on > > systems with a small number of CPUs. The activation threshold > > is set to 16 CPUs. > > > > This helps

Re: [PATCH v3 RESEND] selftests: filesystems: Add functional test for the abort file in fusectl

2025-06-12 Thread Miklos Szeredi
On Tue, 10 Jun 2025 at 04:10, Chen Linxuan wrote: > > This patch add a simple functional test for the "abort" file > in fusectlfs (/sys/fs/fuse/connections/ID/about). > > A simple fuse daemon is added for testing. > > Related discussion can be found in the link below. > > Link: > https://lore.ker

Re: [PATCH net] vsock/virtio: fix `rx_bytes` accounting for stream sockets

2025-06-12 Thread Xuewei Niu
> On Thu, 12 Jun 2025 at 10:21, Xuewei Niu wrote: > > > > > On Thu, 12 Jun 2025 at 08:50, Xuewei Niu wrote: > > > > > > > > > On Thu, Jun 12, 2025 at 01:32:01PM +0800, Xuewei Niu wrote: > > > > > > No comments since last month. > > > > > > > > > > > > The patch [1], which adds SIOCINQ ioctl suppo

Re: [PATCH net] vsock/virtio: fix `rx_bytes` accounting for stream sockets

2025-06-12 Thread Stefano Garzarella
On Thu, 12 Jun 2025 at 10:21, Xuewei Niu wrote: > > > On Thu, 12 Jun 2025 at 08:50, Xuewei Niu wrote: > > > > > > > On Thu, Jun 12, 2025 at 01:32:01PM +0800, Xuewei Niu wrote: > > > > > No comments since last month. > > > > > > > > > > The patch [1], which adds SIOCINQ ioctl support for vsock, de

[PATCH bpf-next v2] selftests/bpf: fix signedness bug in redir_partial()

2025-06-12 Thread Fushuai Wang
When xsend() returns -1 (error), the check 'n < sizeof(buf)' incorrectly treats it as success due to unsigned promotion. Explicitly check for -1 first. Fixes: a4b7193d8efd ("selftests/bpf: Add sockmap test for redirecting partial skb data") Signed-off-by: Fushuai Wang --- tools/testing/selftest

  1   2   >