summaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)Author
3 daysMerge branch 'pm-runtime' into linux-nextRafael J. Wysocki
* pm-runtime: PM: runtime: Clarify driver callback expectations and structure Section 2 PM: runtime: Clarify ->runtime_idle() callback return value handling PM: runtime: Add "Section" hyperlinks PM: runtime: Misc improvements to runtime_pm.rst PM: runtime: More kerneldoc formatting PM: runtime: Correct pm_runtime_autosuspend_expiration() doc PM: runtime: call pm_runtime_dont_use_autosuspend() on reinit() PM: core: Document struct dev_pm_info with kerneldoc PM: runtime: Pull API docs from kerneldoc PM: runtime: kerneldoc wording improvements PM: runtime: Improve set_{status,active,suspended} docs PM: runtime: kerneldoc fixes PM: runtime: Add kunit test for supplier idle/suspend PM: runtime: Only queue an idle check for RPM-linked suppliers
3 daysMerge branch 'pm-cpufreq' into linux-nextRafael J. Wysocki
* pm-cpufreq: cpufreq: amd-pstate-ut: Fix max_freq and EPP test failures on Zen6 cpufreq: amd-pstate: Propagate cppc_set_auto_sel() errors on mode change cpufreq: amd-pstate: Restore previous mode when changing driver mode fails cpufreq/amd-pstate: Get Highest Freq for a CPU cpufreq/acpi-cpufreq: Use amd_get_boost_ratio() ACPI: CPPC: Refactor boost ratio handling cpufreq: amd-pstate: Update Zen6 client EPP tuning values cpufreq/amd-pstate: Fix TOCTOU when changing driver mode via sysfs cpufreq/amd-pstate: Skip auto_sel write when it already matches the mode cpufreq/amd-pstate: Restore previous EPP if profile_name allocation fails cpufreq: conservative: Restrict deferred downscaling to low load cpufreq/amd-pstate: Remove obsolete amd_dynamic_epp documentation cpufreq/amd-pstate: Show a warning if missing EPP tunings cpufreq/amd-pstate: Add EPP tunings for Zen6 client platforms cpufreq/amd-pstate: Add per SoC and per core type EPP tuning values cpufreq/amd-pstate-ut: Fix amd_pstate_ut_check_freq failure with 'Requested CPU Min frequency' BIOS option
3 daysMerge tag 'amd-pstate-v7.4-2026-10-14' of ↵Rafael J. Wysocki
ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/superm1/linux Pull amd-pstate content for 7.4 (10/4/26) from Mario Limonciello: "* Fixups for a few bugs identified by Sashiko * Initial support for maximum frequency capacity handling on Zen6 / client * Updated EPP tunings for Zen6 / client"
3 daysMerge branch 'acpi-cppc' into linux-nextRafael J. Wysocki
* acpi-cppc: cpufreq: CPPC: Create the FIE worker before enabling PCC callbacks cpufreq: CPPC: Select the frequency-invariance callback per CPU ACPI: CPPC: Accept requests to retain immutable autonomous selection ACPI: CPPC: Propagate errors from cross-CPU FFH calls ACPI: CPPC: Validate FFH register fields before hardware access ACPI: CPPC: Keep Performance Limited clearable on NVIDIA T41 ACPI: CPPC: Clear Performance Limited without a stale read ACPI: CPPC: Validate SystemIO overlaps across processors ACPI: CPPC: Validate PCC overlaps across processors ACPI: CPPC: Validate SystemIO register layouts ACPI: CPPC: Validate and access PCC register layouts ACPI: CPPC: Reject direct reads of write-only controls ACPI: CPPC: Reject unsafe cross-CPU SystemMemory RMW ACPI: CPPC: Release PCC data after probe failures ACPI: CPPC: Release CPC descriptors through kobject ACPI: CPPC: Serialize PCC EPP payload updates ACPI: CPPC: Serialize PCC single-register payload updates ACPI: CPPC: Propagate performance-control write errors ACPI: CPPC: Validate _CPC entry and control semantics ACPI: CPPC: Validate the _CPC package header
3 daysMerge branch 'acpi-driver' into linux-nextRafael J. Wysocki
* acpi-driver: ACPI: bus: Drop acpi_get_first_physical_node() efi/dev-path-parser: Switch to use acpi_bus_get_primary_device() ALSA: hda: tas2781: Switch to use acpi_bus_get_primary_device() ALSA: hda: cs35l41: Switch to use acpi_bus_get_primary_device() iommu/arm-smmu-v3: Switch to use acpi_bus_get_primary_device() ACPI: Add stub for acpi_find_child_device() ACPI: bus: Provide !ACPI stub for acpi_device_uid() ALSA: hda: aw88399: Switch to use acpi_bus_get_primary_device() ASoC: loongson: Switch to use acpi_bus_get_primary_device() ASoC: intel: boards: Switch to use acpi_bus_get_primary_device() ASoC: amd: acp3x-es83xx: Switch to use acpi_bus_get_primary_device() ASoC: amd: acp-es8336: Switch to use acpi_bus_get_primary_device() thunderbolt: Switch to use acpi_bus_get_primary_device() platform/x86: apple-gmux: Switch to use acpi_bus_get_primary_device() platform/x86: x86-android-tablets: Use acpi_bus_get_primary_device() platform/x86: serdev_helpers: Switch to use acpi_bus_get_primary_device() platform/x86: yogabook: Switch to use acpi_bus_get_primary_device() ACPI: amba: Switch to use acpi_bus_get_primary_device() ACPI: bus: Use acpi/acpi_bus.h without CONFIG_ACPI
3 daysMerge branches 'acpi-fan', 'acpi-apei' and 'acpi-misc' into linux-nextRafael J. Wysocki
* acpi-fan: ACPI: fan: Use __free() to simplify AML error handling * acpi-apei: PCI/AER: Map a raw AER Capability image field by field Documentation: ACPI: EINJ: Update stale driver source reference cxl/ras: Make cxl_cper_handle_prot_err() static ACPI: APEI: GHES: Bound AER info copy and sanitize software metadata ACPI: APEI: GHES: Validate memory error section length before payload access efi/cper: Read only validated fields in cper_mem_err_pack() ACPI: APEI: GHES: Validate CXL protocol error section length before RAS cap copy ACPI: APEI: GHES: Bound CXL event record copy to the firmware section length ACPI: extlog: Fix CONFIG_ACPI_APEI_PCIEAER guard typo ACPI: extlog: Validate PCIe error section length before payload access ACPI: extlog: Avoid populating software AER metadata from raw hardware buffer ACPI: extlog: Defer CXL protocol error handling to avoid lock inversion ACPI: extlog: Validate elog record length before walking sections efi/cper: Reject an error status block length that wraps a u32 efi/cper: Reject CPER records with an out-of-range error_data_length * acpi-misc: ACPI: WMI: use IS_ENABLED() to simplify built-in or module check
3 daysMerge branches 'acpi-thermal', 'acpi-video' and 'pnp' into linux-nextRafael J. Wysocki
* acpi-thermal: ACPI: thermal: Fix acpi_thermal_guess_offset() for device with a 273.0°K offset ACPI: fan: Use more suitable cooling device data ACPI: fan: Store ACPI device pointer in struct acpi_fan ACPI: processor: thermal: Use more suitable cooling device data ACPI: thermal: Use cooling device parent for thermal zone binding ACPI: fan: Use thermal_cooling_device_create() ACPI: video: Use thermal_cooling_device_create() ACPI: processor: thermal: Use thermal_cooling_device_create() thermal: core: Introduce thermal_cooling_device_create() ACPI: video: Fix backlight unregistration ordering ACPI: fan: Fix memory leak due to leftover devm_kcalloc() argument * acpi-video: ACPI: video: add backlight=native DMI quirk on Acer Nitro AN515-58 * pnp: PNP: Detach device after resource transition failure
3 daysMerge branches 'acpi-tables', 'acpi-osl', 'acpi-utils' and 'acpi-pm' into ↵Rafael J. Wysocki
linux-next * acpi-tables: ACPI: HMAT: preserve hmat_adist_nb notifier block ACPI: tables: handle failed initrd override mappings ACPI: MRRM: Use for_each_populated_zone() in get_node_num() * acpi-osl: ACPI: OSL: Use vsnprintf() in acpi_os_vprintf() * acpi-utils: ACPI: utils: Ignore leading root scope prefix in string _UID match ACPI: utils: Adjust message printing macros for ACPI objects * acpi-pm: ACPI: PM: Add quirk for Acer Swift 3 SF314-56G (MX250) ACPI: PM: s2idle: Add _Ixx GPE wake indicator support
3 daysMerge branches 'acpi-scan', 'acpi-glue', 'acpi-bus' and 'acpi-sysfs' into ↵Rafael J. Wysocki
linux-next * acpi-scan: ACPI: scan: Combine two conditionals in acpi_bus_attach() ACPI: PM: Move acpi_bus_init_power() declaration to internal header file ACPI: scan: Stop calling acpi_bus_init_power() early ACPI: PM: Drop parent state update from acpi_device_get_power() ACPI: scan: Drop useless and noisy debug statement * acpi-glue: ACPI: glue: Skip devices with no type in acpi_device_notify() ACPI: glue: Fix up and adjust acpi_unbind_one() ACPI: glue: Rearrange acpi_bind_one() to avoid breakage ACPI: glue: Carry out companion lookup under bus_type_sem ACPI: glue: Rework the success message in acpi_device_notify() ACPI: glue: Reduce debug noise from acpi_device_notify() * acpi-bus: driver core/ACPI: Introduce companion_bus_register() ACPI: bus: Reduce runtime memory footprint of struct acpi_device * acpi-sysfs: ACPI: sysfs: use strscpy() instead of strcpy()
3 daysntfs: add named stream ioctls supportNamjae Jeon
NTFS supports multiple named $DATA attributes, commonly known as alternate data streams. Add NTFS-specific ioctls to list, read, write, and remove named streams through an opened base file or directory. The UAPI provides separate commands for each operation. - NTFS_IOC_STREAM_READ - NTFS_IOC_STREAM_WRITE - NTFS_IOC_STREAM_REMOVE - NTFS_IOC_LIST_STREAMS Read and write requests use struct ntfs_stream to specify the stream name, byte offset, and transfer length. Writes create the stream if it does not already exist. A write failure after creation may leave the new stream visible. It is not rolled back because another caller may already have opened it. Userspace can remove it with NTFS_IOC_STREAM_REMOVE. The list command returns variable-length entries containing each named stream's data size, allocated size, and name. If the buffer is too small, the command returns -ENOSPC without copying entries. bytes_returned reports the required buffer size, and stream_count reports the number of streams. Stream names use the mounted filesystem NLS by default. Set NTFS_STREAM_FL_UTF16 to pass or receive raw UTF-16LE names. In NLS mode, names that cannot be represented by the mounted character set are omitted from the list. Use UTF-16 mode for lossless enumeration. Read and write transfers are limited to 16 MiB per request. Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
3 daysfs: rename vfs_get_super() to get_tree_super() and export itGiuseppe Scrivano
Rename and export it so filesystems that need a custom superblock matching policy can reuse it directly instead of open-coding sget_fc() + fill_super(). No functional change. This is a preparatory fix for the next patch. Signed-off-by: Giuseppe Scrivano <giuseppe@scrivano.org> Link: https://patch.msgid.link/20261002163225.1258203-2-giuseppe@scrivano.org Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 daysmount: add OPEN_TREE_DROP_MNTNS_MOUNTSKir Kolyshkin
A recursive open_tree(OPEN_TREE_CLONE) copies the nsfs mounts of any mount namespaces pinned below the source. When the clone is attached inside a mount namespace younger than a pinned one, move_mount(2) fails with ELOOP from check_for_nsfs_mounts(), per the rule from commit 8823c079ba71 ("vfs: Add setns support for the mount namespace") that prevents mount namespace reference loops. This breaks container runtimes that use OPEN_TREE_NAMESPACE, such as crun [1]. The new namespace is younger than everything else, so bind mounting e.g. the host root fails on any host that pins a mount namespace (snapd does, under /run/snapd/ns). By the time it fails, setns() has already run and userspace cannot recover: the host tree is out of reach, and the offending mounts cannot be unmounted from the detached copy. copy_mnt_ns() and create_new_namespace() already leave these mounts behind; only get_detached_copy() copies them. Add an open_tree() flag to drop them from the clone, as suggested by Aleksa [2]. Locked nsfs mounts are dropped the same way copy_mnt_ns() does it, so nothing new is exposed. Keep it opt-in: open_tree(OPEN_TREE_CLONE) plus move_mount(2) is how mount --rbind works through a file descriptor, and in the caller's own or an older namespace such mounts remain usable. The flag requires AT_RECURSIVE, since a non-recursive clone has no submounts to drop, and OPEN_TREE_CLONE or OPEN_TREE_NAMESPACE. With the latter it is a no-op, so a runtime can pass it with any recursive open_tree() call. Link: https://github.com/containers/crun/issues/2262 [1] Link: https://lore.kernel.org/all/2026-01-07-oldest-grim-captions-spills-ywC2O3@cyphar.com/ [2] Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com> Link: https://patch.msgid.link/20261006-nsfs-prune-rfc-v3-1-adb97ea52868@gmail.com Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 dayspid: use READ_ONCE() in pid_alive()Babanpreet Singh
KCSAN reports pid_alive() reading task->thread_pid while it gets cleared under tasklist_lock. The check only cares about NULL, so READ_ONCE() and WRITE_ONCE() are enough. Reported-by: syzbot+c382ee653fd70f5cf1bb@syzkaller.appspotmail.com Closes: https://syzkaller.appspot.com/bug?extid=c382ee653fd70f5cf1bb Signed-off-by: Babanpreet Singh <bbnpreetsingh@gmail.com> Link: https://patch.msgid.link/20261002012141.7-1-bbnpreetsingh@gmail.com Acked-by: Oleg Nesterov <oleg@redhat.com> Reviewed-by: Bradley Morgan <brads@mainlining.org> Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 daysMerge branch 'soc/drivers' into for-nextArnd Bergmann
* soc/drivers: (26 commits) platform: cznic: turris-omnia-mcu: Add missing MODULE_DEVICE_TABLE() firmware: arm_scmi: Always create devices for standard protocols firmware: arm_scmi: Add SCMI device table alias support soc: mediatek: mt8167-mmsys: add routes for all display paths firmware: arm_scmi: Validate PCC shared memory signature firmware: arm_scmi: Initialise known ACPI protocol devices and channels firmware: arm_scmi: Add ACPI PCC transport firmware: arm_scmi: Refactor protocol device creation logic firmware: arm_scmi: Pass protocol ID to transport chan_available() firmware: arm_scmi: Fall back to ACPI HID when "compatible" is absent firmware: arm_scmi: Convert OF-only paths to generic fwnode in SCMI core firmware: arm_scmi: Extend transport driver macro to support ACPI firmware: arm_scmi: Set generated device fwnode with platform helpers firmware: arm_scmi: Merge scmi_reset_proto_ops.name_get() and .latency_get() firmware: arm_scmi: Fix error path leak in scmi_raw_message_send() firmware: arm_scmi: Don't reuse raw xfers with async_done still armed firmware: arm_scmi: Protect xfer->async_done with xfer->lock include: trace: Use string helpers in msg_dump trace events soc: mediatek: mtk-regulator-coupler: Add support for MT8189 soc: renesas: rcar-rst: Add support for RZ/G2M v3.0 ...
3 daysMerge branch 'soc/dt' into for-nextArnd Bergmann
* soc/dt: (236 commits) ARM: dts: gemini: Use a level-high interrupt for TVE200 ARM: dts: gemini: Rename power controller node to poweroff ARM: dts: ux500: Add Samsung phone audio graphs ARM: dts: ux500: Convert HREF audio to audio-graph-card2 ARM: dts: ux500: Add sound DAI provider cells ARM: dts: am335x-bonegreen-eco: Enable 1GHz OPP by increasing vdd_mpu voltage arm64: dts: mediatek: mt7988a-bpi-r4pro: label gpio-hogs arm64: dts: mediatek: mt7988a-bpi-r4pro: add names for i2c-to-gpio chip arm64: dts: qcom: Add device tree for Nord RRD board arm64: dts: qcom: Add device tree for Nord Ride board dt-bindings: arm: qcom: Document Nord reference boards arm64: dts: qcom: Add device tree for Nord Embedded variant arm64: dts: qcom: Add device tree for Nord GearVM variant arm64: dts: qcom: Add device tree for Nord SoC series arm64: dts: qcom: glymur: Mark USB controllers dma-coherent dt-bindings: mmc: sdhci-msm: Document the Glymur compatible arm64: dts: qcom: glymur-crd: Update VREG l2b_e0 and l9b_e0 voltage for SD-card arm64: dts: qcom: glymur-lenovo-yoga-slim7x: add the camera privacy switch arm64: dts: qcom: sc8280xp: Mark FastRPC context banks as dma-coherent arm64: dts: qcom: sm8350-sony-xperia-sagami: enable UFS ...
3 dayspidfs: record the coredump on the dumping thread's pid tooChristian Brauner
If a thread-group coredumps only the thread-group leader pidfd will return coredump information. A pidfd for the thread that took the fatal signal cannot be used to retrieve it. Record both the thread-group leader and the specific thread that took the signal and register both in pidfs. Mark both the thread-group leader and the specific thread with the coredump information so retrieval works for both pidfds. Now that both SO_PEERPIDFD and SO_PEERPIDFD_THREAD are available it's easy to get the coredump information for the specific thread. Reviewed-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@futurfusion.io> Signed-off-by: Andrew Halaney <andrew@amutable.com> Link: https://patch.msgid.link/20261005-work-unix-passpidfd-v4-9-350183b6e02a@amutable.com Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 daysnet: add SO_PEERPIDFD_THREAD to get a thread-specific pidfdChristian Brauner
SO_PEERPIDFD hands out a pidfd for the thread-group that called connect() or socketpair(). Enable workloads such as the coredump server or a broker to get a pidfd of the specific thread that connected to the socket. Reviewed-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@futurfusion.io> Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com> Signed-off-by: Andrew Halaney <andrew@amutable.com> Link: https://patch.msgid.link/20261005-work-unix-passpidfd-v4-7-350183b6e02a@amutable.com Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 daysnet: turn sk_peer_pid into an array indexed by pid typeChristian Brauner
Currently only the struct pid of the thread-group leader is recorded for a socket's peer. To make room for the struct pid of the thread that called connect(), listen() or socketpair() turn sk_peer_pid into an array indexed by pid type. All users, including bluetooth and the coredump socket, keep using the PIDTYPE_TGID slot. Nothing fills the PIDTYPE_PID slot yet. No functional changes. Reviewed-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@futurfusion.io> Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com> Signed-off-by: Andrew Halaney <andrew@amutable.com> Link: https://patch.msgid.link/20261005-work-unix-passpidfd-v4-5-350183b6e02a@amutable.com Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 daysnet: add SO_PASSPIDFD_THREAD to get a thread-specific SCM_PIDFDChristian Brauner
Currently, SCM_PIDFD carries a pidfd for the thread-group leader. A broker or the coredump server cannot learn the identity of the specific thread that sent a given message. Now that both struct pids are recorded a receiver can ask for the specific identity it needs. So add SO_PASSPIDFD_THREAD as a sibling of SO_PASSPIDFD. SO_PASSPIDFD_THREAD delivers an SCM_PIDFD_THREAD, i.e. scoped to the specific thread sending. This is completely independent of SO_PASSPIDFD, meaning you can use both options and get both cmsgs. On SOCK_STREAM sockets recvmsg() only stops merging data at a thread boundary when the receiver asked for a thread pidfd. For SO_PASSCRED and SO_PASSPIDFD receivers all threads of one process remain a single writer. Co-developed-by: Andrew Halaney <andrew@amutable.com> Signed-off-by: Andrew Halaney <andrew@amutable.com> Link: https://patch.msgid.link/20261005-work-unix-passpidfd-v4-3-350183b6e02a@amutable.com Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com> Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 daysaf_unix: record the pid of the sending threadChristian Brauner
Currently only the struct pid of the thread-group leader is recorded. The identity of the actual thread that sent the message or is connected to a given socket cannot be retrieved. Add the plumbing to make it possible to retrieve a pidfd for the sender. Nothing uses the thread-specific struct pid yet. No functional changes. Reviewed-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@futurfusion.io> Signed-off-by: Andrew Halaney <andrew@amutable.com> Link: https://patch.msgid.link/20261005-work-unix-passpidfd-v4-2-350183b6e02a@amutable.com Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com> Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 dayspid: add helpers to operate on a struct pid arrayChristian Brauner
We're about to extend af_unix sockets and coredump code with the ability to hand out thread-specific pidfds. Add a few simple helpers that allow to operate on multiple struct pids up to PIDTYPE_MAX with automatic bounds checking. Reviewed-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@futurfusion.io> Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com> Signed-off-by: Andrew Halaney <andrew@amutable.com> Link: https://patch.msgid.link/20261005-work-unix-passpidfd-v4-1-350183b6e02a@amutable.com Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 daysbpf: Reject BTF ids with the same address in tracing_multi linkAlexei Starovoitov
check_dup_ids() rejects equal BTF ids, but different ids can resolve to the same address. Aliases: ffffffff8161b6b0 t __do_sys_munlockall ffffffff8161b6b0 T __ia32_sys_munlockall ffffffff8161b6b0 T __x64_sys_munlockall or several BTF_KIND_FUNC with the same name that vmlinux BTF has when CONFIG_DEBUG_INFO_BTF_INLINE is set. Each id gets its own trampoline and register_fentry_multi() adds them to data->reg with the same ip. update_ftrace_direct_add() checks that new entries are not in direct_functions, but doesn't compare them with each other, so the attach succeeds. At detach update_ftrace_direct_del() sees that 'direct' of one of the entries doesn't match and returns -EINVAL: WARNING: kernel/bpf/trampoline.c:1845 at bpf_trampoline_multi_detach+0x24c/0x280 Call Trace: bpf_link_free+0x51/0x110 bpf_link_release+0x18/0x20 __fput+0x103/0x2d0 __x64_sys_close+0x3d/0x80 The images are freed anyway, while ftrace still calls them: Oops: int3: 0000 [#1] SMP NOPTI RIP: 0010:0xffffffffc042b201 Call Trace: ? __audit_syscall_exit+0x9/0x100 ? do_syscall_64+0x5ab/0x5e0 entry_SYSCALL_64_after_hwframe+0x77/0x7f Kernel panic - not syncing: Fatal exception in interrupt Return -EINVAL from register_fentry_multi() when ip is already in data->reg. When such ids are attached via different links the second attach already fails with -EINVAL in update_ftrace_direct_add(). Move the declaration of ftrace_lookup_ip() to include/linux/ftrace.h. The lookup adds 60 msec to the attach of 64480 functions in tracing_multi_bench_attach: 1.34 -> 1.40 sec. Fixes: aef4dfa790b2 ("bpf: Add bpf_trampoline_multi_attach/detach functions")a Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Leon Hwang <leon.hwang@linux.dev> Acked-by: Jiri Olsa <jolsa@kernel.org> Link: https://lore.kernel.org/bpf/20261011164836.2233874-2-alexei.starovoitov@gmail.com Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
3 daysxfrm: espintcp: reorder operations within espintcp_init_skSabrina Dubroca
When enabled on a socket, espintcp sets the socket callbacks to its own before it has finished setting up its context and published it as icsk_ulp_data. Any one of those callbacks that gets called before will dereference a NULL icsk_ulp_data. Fix this by reording the operations, and add memory barriers to ensure callers will have a struct espintcp_ctx available. Add a few WRITE_ONCE/READ_ONCE too while we're there. Fixes: e27cca96cd68 ("xfrm: add espintcp (RFC 8229)") Cc: stable@vger.kernel.org Reported-by: Yuan Tan <yuantan098@gmail.com> Reported-by: Yifan Wu <yifanwucs@gmail.com> Reported-by: Juefei Pu <tomapufckgml@gmail.com> Reported-by: Xin Liu <bird@lzu.edu.cn> Reported-by: Peihan Liu <ronbogo@outlook.com> Reported-by: Yilin Zhu <zylzyl2333@gmail.com> Reported-by: Ren Wei <n05ec@lzu.edu.cn> Reported-by: Eulgyu Kim <eulgyukim@snu.ac.kr> Reported-by: Jaeyoung Chung <jjy600901@snu.ac.kr> Link: https://lore.kernel.org/all/c30b645074a1b379e0f7fe297f917c66137d9964.1778464688.git.zylzyl2333@gmail.com/ Link: https://lore.kernel.org/all/20260819155349.3555804-1-jjy600901@snu.ac.kr Signed-off-by: Sabrina Dubroca <sd@queasysnail.net> Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
3 dayspid: document that do_each_pid_task() needs tasklist_lockOleg Nesterov
do_each_pid_task() looks "obviously rcu-safe". This confuses people and we already have 2 buggy users: send_sigio() and send_sigurg(). The reasons why it is not are not obvious at all, add the comment. Signed-off-by: Oleg Nesterov <oleg@redhat.com> Link: https://patch.msgid.link/asuaU8H_5MbO3-cW@redhat.com Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
3 daysMerge branch 'for-linus' into for-nextTakashi Iwai
Signed-off-by: Takashi Iwai <tiwai@suse.de>
4 daysrust: sync: add const constructor for raw_spinlock_tAlice Ryhl
The abstractions for pr_*_ratelimited! need to construct a global `struct ratelimit_state`, which contains a `raw_spinlock_t` field. Thus, add a const constructor for the `raw_spinlock_t` type. The SPINLOCK_OWNER_INIT constant isn't mirrored via a const helper because bindgen generates a 'static mut' instead of a constant from the pointer constant., The __ARCH_SPIN_LOCK_UNLOCKED constant cannot be translated by bindgen because it's a define for a struct without type annotations, so it's explicitly declared in Rust. Reviewed-by: Boqun Feng <boqun@kernel.org> Reviewed-by: Carlos Llamas <cmllamas@google.com> Acked-by: Miguel Ojeda <ojeda@kernel.org> Signed-off-by: Alice Ryhl <aliceryhl@google.com> Link: https://patch.msgid.link/20261007-pr-ratelimited-v6-2-f14accd4ea3b@google.com Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
4 daysdocs: core-api: Document the seq_buf APIKees Cook
The kernel-doc in include/linux/seq_buf.h and lib/seq_buf.c documents the seq_buf interface, but no .rst file pulls either of them in, so none of it reaches the generated documentation. Add the missing kernel-doc for seq_buf_clear() and seq_buf_init(), and a Sequence Buffers section to the kernel API documentation. The static internal helper seq_buf_can_fit() is left out. Additionally fix seq_buf_hex_dump() indentation to avoid the reported Sphinx error: ERROR: Unexpected indentation. WARNING: Block quote ends without a blank line; unexpected unindent. Verified with "make SPHINXDIRS=core-api htmldocs", which rendered happily into core-api/kernel-api.html. Assisted-by: LLM Co-developed-by: Bill Wendling <morbo@google.com> Signed-off-by: Bill Wendling <morbo@google.com> Tested-by: Randy Dunlap <rdunlap@infradead.org> Reviewed-by: Randy Dunlap <rdunlap@infradead.org> Link: https://patch.msgid.link/20261005155708.1471260-12-kees@kernel.org Signed-off-by: Kees Cook <kees@kernel.org>
4 daysseq_buf: Add seq_buf_init_append()Bill Wendling
Several strlcat() call sites being converted to seq_buf need behavior seq_buf doesn't currently provide. The normal seq_buf_init() always empties the buffer (sets its "len" to 0) via seq_buf_clear(). Code migrating from strlcat(buf, ...), which appends to whatever buf already contains, can't use seq_buf_init() without discarding that existing content. Add seq_buf_init_append(), which preserves the existing contents and positions the seq_buf to append after it. A buffer with no NUL within its size starts out overflowed, as strlcat() treats it as already truncated. Add KUnit tests for behavior coverage. Tests passed under qemu on ARCH=x86_64 with GCC 16.2.0 and CONFIG_KASAN=y, and on big-endian ARCH=s390 with GCC s390x-linux-gnu 16.2.0. Assisted-by: LLM Signed-off-by: Bill Wendling <morbo@google.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Co-developed-by: Kees Cook <kees@kernel.org> Link: https://patch.msgid.link/20261005155708.1471260-9-kees@kernel.org Signed-off-by: Kees Cook <kees@kernel.org>
4 daysseq_buf: Add seq_buf_terminate()Kees Cook
Seven callers call seq_buf_str() only to NUL-terminate the buffer, discarding the returned pointer. Two of them need a comment to say so. Add seq_buf_terminate(), wrapping the __seq_buf_terminate() helper that seq_buf_str() and seq_buf_strlen() already use, and convert those callers. It returns void: returning the offset would just be seq_buf_strlen() under another name. A zero-sized seq_buf is left untouched, as in the other accessors. Add tests for the three cases: room for the NUL after the data, an overflowed buffer where it lands in the last byte, and a zero-sized buffer that must not be written to. Build tested ARCH=x86_64 defconfig with GCC 16.2.0, plus CONFIG_HIST_TRIGGERS=y and CONFIG_BPF_SYSCALL=y to reach the converted call sites in kernel/trace/trace_events_hist.c and kernel/bpf/diagnostics.c. Tests run 24/24 passing on ARCH=um. Assisted-by: LLM Acked-by: Alexei Starovoitov <ast@kernel.org> Link: https://patch.msgid.link/20261005155708.1471260-7-kees@kernel.org Signed-off-by: Kees Cook <kees@kernel.org>
4 daysseq_buf: Add seq_buf_strlen()Kees Cook
Several strlcat() call sites being converted to seq_buf need behavior seq_buf doesn't currently provide. The return from seq_buf_used() is not the length of the string in a seq_buf. Once the buffer is full or has overflowed it returns the buffer size, which counts the byte that seq_buf_str() replaces with the NUL, so a caller that needs the string and its length has to call seq_buf_str() and then walk the string with strlen(). Move the termination out of seq_buf_str() into a helper that returns where it put the NUL, and add seq_buf_strlen(), which terminates the buffer in the same way and returns that offset. As discussed in review, don't add WARN_ON() for seq_buf_strlen() and drop it from seq_buf_str(). Add tests comparing seq_buf_strlen() against strlen() of seq_buf_str() for empty, appended, truncated, exactly full, and overflowed buffers, checking that seq_buf_strlen() alone terminates a full buffer, and checking that a zero-sized seq_buf reports an empty string from both accessors without touching the buffer. Tests passed under qemu on ARCH=x86_64 with GCC 16.2.0 and CONFIG_KASAN=y, and on big-endian ARCH=s390 with GCC s390x-linux-gnu 16.2.0. Assisted-by: LLM Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://patch.msgid.link/20261005155708.1471260-6-kees@kernel.org Signed-off-by: Kees Cook <kees@kernel.org>
4 daysseq_buf: Clear what a writer did not claim when a seq_buf overflowsKees Cook
Using seq_buf_set_overflow() would leave the bytes between "len" and "size" untouched, so if seq_buf_str() is used on an overflowed seq_buf, those bytes may be exposed. For any paths that don't claim partially written bytes, by setting "len = size" before calling seq_buf_set_overflow(), wipe the unclaimed bytes. The seq_buf_puts() and related APIs already claim those bytes now, so only the unclaimed cases remain. A specific example of this was seq_buf_path() which uses d_path() and would write to the tail before discovering it was out of space, and would correctly mark a seq_buf as overflowed, but the path fragment would be left over. Clear from len to the end of the buffer in seq_buf_set_overflow(), which every overflow goes through, including seq_buf_commit() with a negative count. Add a test that fills a seq_buf, leaves it too little room for a path, and checks that nothing of the path is left in the buffer. The tests run before anything writable is mounted, so it takes its file from shmem. seq_buf_path() was not exported, so the test failed to link as a module. Export it. Tests passed under qemu on ARCH=x86_64 with GCC 16.2.0 and CONFIG_KASAN=y, and on big-endian ARCH=s390 with GCC s390x-linux-gnu 16.2.0, and the test builds as a module (CONFIG_SEQ_BUF_KUNIT_TEST=m). Assisted-by: LLM Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://patch.msgid.link/20261005155708.1471260-5-kees@kernel.org Signed-off-by: Kees Cook <kees@kernel.org>
4 daysseq_buf: Copy what fits when seq_buf_puts() and seq_buf_putmem() overflowKees Cook
When seq_buf_puts() or seq_buf_putmem() is given more than fits, it copies nothing and only marks the seq_buf as overflowed. If seq_buf_str() is used, it will terminate the buffer in its last byte, so every byte between the end of the data and the end of the buffer becomes part of the string, though the seq_buf never wrote them. seq_buf_printf() does not have this problem, because vsnprintf() writes as much of the output as fits, followed by a NUL. Repeat this behavior in seq_buf_puts(), using strscpy(), and in seq_buf_putmem(), which also covers seq_buf_putmem_hex(). seq_buf_putc() needs no change, as it can only overflow when the buffer is already full. Each writer now records the buffer as full once it has copied what fits, so that what it wrote can be told apart from bytes nothing touched. Of the callers that check the return value or test for overflow afterward, only lpfc_rx_monitor_report() relied on a string that did not fit being left out, and the previous patch has it drop such a record itself. The others treat overflow as an error or report it. The callers that ignore overflow use whatever the buffer holds, which now ends with the part of the string that fit. Update seq_buf_putmem_hex_overflow_test, which expected a hex group that did not fit whole to be left out entirely, and add tests that overflow seq_buf_puts(), seq_buf_putmem() and seq_buf_putmem_hex() with stale bytes in the buffer. The three partial-overflow tests check the buffer itself rather than seq_buf_str(). Neither writer leaves the last byte of the buffer alone: seq_buf_putmem() copies raw bytes and writes no NUL, and seq_buf_puts() relies on strscpy() to write one. That byte is exactly where seq_buf_str() writes its terminator, so asserting only on the string would pass whether the copy stopped a byte early or dropped the NUL entirely. seq_buf_putmem() was not exported, so the test failed to link as a module. Export it. Tests passed under qemu on ARCH=x86_64 with GCC 16.2.0 and CONFIG_KASAN=y, and on big-endian ARCH=s390 with GCC s390x-linux-gnu 16.2.0, and the test builds as a module (CONFIG_SEQ_BUF_KUNIT_TEST=m). Assisted-by: LLM Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://patch.msgid.link/20261005155708.1471260-4-kees@kernel.org Signed-off-by: Kees Cook <kees@kernel.org>
4 daysseq_buf: Do not pop from an overflowed seq_bufKees Cook
When a seq_buf has overflowed, its len is size + 1, so seq_buf_pop() decrements len to size and reads buffer[size], one byte past the end of the buffer. It also leaves len equal to size, which no longer counts as overflowed, so a truncated seq_buf then looks like a complete, full one. An overflowed seq_buf logically has no last character to pop: the length of what was written has been lost, and the last byte of the buffer may be the NUL written by vsnprintf() or bytes that were never committed. Return -1 for an overflowed seq_buf, as for an empty one, and leave it overflowed, as the rest of the seq_buf API does until seq_buf_clear() or seq_buf_init(). The current callers do not reach this, e.g. trace_syscalls only calls trace_seq_pop() when the trace_seq it pops from has not overflowed, and kernel/bpf/diagnostics.c sets the length from strnlen() before popping. Add tests for the pop corner cases. Tests passed under qemu on ARCH=x86_64 with GCC 16.2.0 and CONFIG_KASAN=y, and on big-endian ARCH=s390 with GCC s390x-linux-gnu 16.1.0. Fixes: 32e0f607ac6a2 ("tracing: Add trace_seq_pop() and seq_buf_pop()") Assisted-by: LLM Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://patch.msgid.link/20261005155708.1471260-2-kees@kernel.org Signed-off-by: Kees Cook <kees@kernel.org>
4 daysNFSD: Use xdrgen XDR functions for NFSv2 READDIR resultsChuck Lever
READDIR is the last NFSv2 procedure whose reply is still produced by a hand-written encoder. Its entry list is the value-follows form of RFC 1094's "entry *entries" -- each entry prefixed by TRUE, the sequence closed by FALSE -- streamed straight from the directory as it is read rather than from a materialized array. The generated encoder could not drive that: the union encoder writes the reply status word before the entry list, yet a streamed read does not learn the status until the directory has been read, and the aggregate loop was bounded by a count the begin hook had to supply up front. The preceding patches remove both obstacles. The optional-data aggregate encoder now pulls entries until the hook signals end, so no count is needed, and the streaming directory reader yields one entry at a time during encode. Mark readdirok's entry list as an aggregate and regenerate; the struct definitions stay the verbatim RFC 1094 types, and the lone "pragma aggregate readdirok entries" selects the hook-driven codec. Split the read across the two phases so the generated encoder owns the framing. nfsd_proc_readdir() opens the directory, where an open error becomes the reply status the union encoder then writes, and the encode hooks stream the entries: each pull reserves a placeholder cookie and back-patches the preceding entry's cookie once the following entry's resume offset is known; the end hook back-patches the final cookie and reports eof. nfssvc_release_readdirres() closes the reader and releases the file handle. The decode hooks are stubs -- a server never decodes a READDIR result -- present only to satisfy the generated decoder's linkage. Retire struct nfsd_readdirres for an embedded struct readdirres so the RPC dispatch layer can cast the response to its xdrgen type. The directory's svc_fh moves into that wrapper and struct readdirargs_wrapper goes away. svc_process() zeroes the result buffer before decode but leaves the argument buffer as the previous request left it, and ->pc_release runs even when decoding fails. A file handle kept in the argument wrapper would reach fh_put() on that path uninitialized. The generated encoder reserves reply space through the xdr_stream, which does not advance rq_next_page as it moves onto the next page. svcrdma retains only the pages below rq_next_page across Send completion, so the end hook sets rq_next_page past the last page the reply uses, as nfsd4_encode_operation() does. A host error during the streamed read cannot retract entries already on the wire, so it ends the list as a truncated, non-eof reply rather than an error status; an error opening the directory is still reported as the reply status. The bytes on the wire are otherwise unchanged. Acked-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260916162859.2051-30-cel@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysNFSD: Use xdrgen XDR functions for NFSv2 SYMLINK procedureChuck Lever
A SYMLINK request's target pathname can extend from the head of the receive buffer into its page data; the decoder reassembles it from a head segment and a page via svc_fill_symlink_pathname(). Represent the pathname in place rather than materializing it inline: the "pages" directive expresses it as a struct xdr_buf and decodes it with svcxdr_decode_opaque_payload(), which subsegments the source stream instead of pulling the string inline through the bounded xdr scratch buffer. Annotate the to member of symlinkargs with "pragma pages" and replace the NFSPROC_SYMLINK entry in nfsd_procedures2 with the generated nfs_svc_decode_symlinkargs and nfs_svc_encode_nfsstat. A wrapper structure bridges the generated symlinkargs type and the svc_fh and iattr representations the NFSD VFS layer still uses. nfsd_proc_symlink() copies the pathname out of the xdr_buf with read_bytes_from_xdr_buf(), so a target that lands in the receive buffer's tail, or straddles its pages and tail, is handled the same way as one in the head. The pc_argzero field is now set to zero for the NFSv2 SYMLINK procedure. The generated decoder initializes every argument in the argp->xdrgen field, making the early defensive memset unnecessary. The hand-coded nfsd_proc_symlink() accepts a target of any length from the decoder and answers one longer than NFS_MAXPATHLEN with NFSERR_NAMETOOLONG. The generated decoder enforces the path typedef's bound itself, so such a request now fails decoding and nfsd_dispatch() returns RPC GARBAGE_ARGS instead. The Linux NFS client sends targets up to PAGE_SIZE on an NFSv2 mount, and in that case it reports EIO to the application rather than ENAMETOOLONG. nfssvc_decode_symlinkargs() no longer has any callers, so it is removed. Acked-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260916162859.2051-23-cel@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysNFSD: Use xdrgen XDR functions for NFSv2 WRITE procedureChuck Lever
The NFSv2 WRITE argument decoder could not be generated because the write payload must be directed into the server's page cache and decoded in place; a materializing decoder would copy every write. The "pages" directive now expresses this: it represents the payload as a struct xdr_buf and decodes it with svcxdr_decode_opaque_payload(), which subsegments the source stream in place rather than copying it. Annotate the data member of writeargs with "pragma pages" and replace the NFSPROC_WRITE entry in nfsd_procedures2 with the generated nfs_svc_decode_writeargs and nfs_svc_encode_attrstat. A wrapper structure bridges the generated writeargs type and the svc_fh the NFSD VFS layer still uses; the result reuses the attrstat wrapper from the GETATTR conversion. The pc_argzero field is now set to zero for the NFSv2 WRITE procedure. The generated decoder initializes every argument in the argp->xdrgen field, making the early defensive memset unnecessary. This refactor replaces the use of svcxdr_encode_fattr(), so the reference to the file handle can be released directly by nfsd_proc_write(). A separate ->pc_release callback is thus no longer needed. This makes it straightforward to confirm that the file handle is properly released during every error flow. Acked-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260916162859.2051-17-cel@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysNFSD: Use xdrgen XDR functions for NFSv2 READ procedureChuck Lever
Replace the hand-written NFSv2 READ codec pair with the xdrgen-generated functions. The NFSPROC_READ entry in the nfsd_procedures2 array now dispatches nfs_svc_decode_readargs and nfs_svc_encode_readres. A wrapper structure bridges the generated xdrgen readargs type and the legacy svc_fh representation the NFSD VFS layer still uses. The file's data does not reside at the data pointer of the readresok data member: nfsd_read() deposits it directly in the pages of the Reply buffer, so the generic encoder that copies an opaque from the member's data pointer cannot encode it. Mark the member with the "pragma pages" directive so the generated encoder calls svcxdr_encode_opaque_payload(), which encodes the length prefix and inserts the payload pages into the stream by reference. The page anchor that the result structure carried duplicated rq_res.pages -- svc_process() points rq_res.pages at the first Reply page before dispatch, and the readargs decoder consumes no pages -- so the helper locates the payload through the Reply buffer itself, and the wrapper collapses to the generated readres type. The pc_argzero field is now set to zero for the NFSv2 READ procedure. The xdrgen decoders are trusted to initialize all arguments in the argp->xdrgen field, making the early defensive memset unnecessary. The remaining argp fields are cleared as needed. Because the generated encoder no longer needs the svc_fh at encode time, nfsd_proc_read() releases the file handle directly and no separate ->pc_release callback is needed. This makes it straightforward to confirm that the file handle is properly released during every error flow. Acked-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260916162859.2051-15-cel@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysNFSD: Use xdrgen XDR functions for NFSv2 READLINK procedureChuck Lever
Replace the hand-written NFSv2 READLINK codec pair with the xdrgen-generated functions. The NFSPROC_READLINK entry in the nfsd_procedures2 array now dispatches nfs_svc_decode_fhandle and nfs_svc_encode_readlinkres. A wrapper structure bridges the generated xdrgen fhandle type and the legacy svc_fh representation the NFSD VFS layer still uses. The link target does not reside at the data pointer of the readlinkres union arm: nfsd_readlink() deposits it directly in a page of the Reply buffer, so the generic encoder that copies an opaque from the member's data pointer cannot encode it. Mark the arm with the "pragma pages" directive so the generated encoder calls svcxdr_encode_opaque_payload(), which encodes the length prefix and inserts the payload page into the stream by reference. The page anchor that the result structure carried duplicated rq_res.pages -- svc_process() points rq_res.pages at the first Reply page before dispatch, and the fhandle argument decoder consumes no pages -- so the helper locates the payload through the Reply buffer itself, and the wrapper collapses to the generated readlinkres type. The pc_argzero field is now set to zero for the NFSv2 READLINK procedure. The xdrgen decoders are trusted to initialize all arguments in the argp->xdrgen field, making the early defensive memset unnecessary. The remaining argp fields are cleared as needed. Acked-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260916162859.2051-14-cel@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysNFSD: Use xdrgen XDR functions for NFSv2 GETATTR procedureChuck Lever
Replace the NFSPROC_GETATTR entry in the nfsd_procedures2 array with an entry that dispatches the xdrgen-generated nfs_svc_decode_fhandle and nfs_svc_encode_attrstat. Wrapper structures bridge the generated xdrgen types and the legacy svc_fh and kstat representations the NFSD VFS layer still uses. A few helper functions are introduced which will be used here and in subsequent patches. The pc_argzero field is now set to zero for the NFSv2 GETATTR procedure. The xdrgen decoders are trusted to initialize all arguments in the argp->xdrgen field, making the early defensive memset unnecessary. The remaining argp fields are cleared as needed. This refactor replaces the use of svcxdr_encode_fattr(), so the reference to the file handle can be released directly by nfsd_proc_getattr(). A separate ->pc_release callback is thus no longer needed. This makes it straightforward to confirm that the file handle is properly released during every error flow. The new nfsd_mode_to_ftype() utility no longer maps socket and FIFO devices to non-standard values: NFSOCK=6 which is outside the ftype enum, and NFCHR for FIFOs which is semantically wrong. The Linux NFS client implementation does not seem to use or depend on these non-standard values. The new utility function returns NFNON for both, which is the RFC-compliant behavior. Acked-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260916162859.2051-10-cel@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysNFSD: Use xdrgen-generated NFSv2 protocol definitionsChuck Lever
Switch the server's NFSv2 implementation to use the machine- generated protocol definitions. Acked-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260916162859.2051-6-cel@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysNFSD: Add infrastructure for generating NFSv2 XDR encoders and decodersChuck Lever
NFSD's NFSv2 XDR codecs are hand-maintained; they are being converted to xdrgen-generated code one RPC procedure at a time. The first step is to generate and commit the xdrgen C code based on nfs2.x. The generated code can be refreshed any time nfs2.x is modified by running "(cd fs/nfsd && make xdrgen)". Acked-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260916162859.2051-4-cel@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysNFSD: add a userspace-rpcbind flag to listener_setJeff Layton
Describe the interface that lets a caller take over rpcbind registration. The request gains a userspace-rpcbind flag. The reply echoes the flag, lists the programs and versions that the caller should register, and names the listeners that came up. NLM is absent. lockd owns its own svc_serv and still registers itself. Assisted-by: LLM Signed-off-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260915-nfsd-norpcb-v3-2-3c60d49ade02@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysSUNRPC: allow a service to opt out of rpcbind registrationJeff Layton
svc_bind() creates the local rpcbind client, and svc_register() then makes one synchronous call for each program and version. Both run under the caller's mutex. A caller that registers from userland needs neither. Add sv_no_rpcbind to struct svc_serv, and fix up the code to honor it. No caller sets the flag yet, so behaviour does not change. Assisted-by: LLM Signed-off-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260915-nfsd-norpcb-v3-1-3c60d49ade02@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
4 daysMerge tag 'drm-msm-next-2026-10-11' of ↵Dave Airlie
https://gitlab.freedesktop.org/drm/msm into drm-next Changes for v7.4 CI: - Dropped sc7180 trogdor lazor from the CI Core: - Fixed msm_ioremap for resources without a name - Changed msm.separate_gpu_kms to default to auto selection GPU: - Enable CLX (Current Limit eXtension) for gen8 to avoid exceeding limits on CX/GX rails - New GPUs: a830 (Pakala), a845 (Maili), a850 (Hawi), x2-85 (Mahua) - Fix VBIF halt mask on a306, which was preventing runpm suspend - Enable THP support for GEM buffers - Add modparam to disable waiting on fences in shrinker - Drop use of drm_prime_sg_to_page_array() - a5xx: don't read the GPMU registers on GPUs without a GPMU - a2xx/a3xx/a5xx: hangcheck progress detection - a6xx: gmuwrapper runpm fix - Calculate reported GMEM size based on active slices - Split a6xx/a7xx/a8xx catalog DP: - Picked up some preparation patches for the MST support - Fixed reported status of the link training DPU: - Fixed CRTC bandwidth computation - Fixed DSC programming - Fixed encoder disablement path DSI: - Fixed VM leak in error path - Indention fix MDP5: - Added MSM8952 configuration - Dropped incorrect cursor pipe on MSM8976/56 HDMI: - Small fixes Notes: - Merged qcom-drivers-for-7.4 to pick up UBWC_7_0 support (needed for Hawi/Maili) which in turn depended on qcom-arm64-for-7.4 Signed-off-by: Dave Airlie <airlied@redhat.com> From: Rob Clark <rob.clark@oss.qualcomm.com> Link: https://patch.msgid.link/CACSVV02V-FOzGj71G0ZL7khkYEKWFW4q4biOZR8B8vyWy20PdQ@mail.gmail.com
4 daysbus: mhi: ep: Add mhi_ep_queue_buf() API for raw buffer queuingSumit Kumar
Some MHI endpoint clients do not use socket buffers and need a way to queue raw buffers for DL transfers. Add mhi_ep_queue_buf() to support this use case. Refactor mhi_ep_queue_skb() to delegate to a new internal mhi_ep_queue() helper shared by both APIs, and rename mhi_ep_skb_completion() to mhi_ep_buf_completion() to reflect its broader use. Signed-off-by: Sumit Kumar <sumit.kumar@oss.qualcomm.com> Link: https://patch.msgid.link/20261005-lb-v7-2-36a268b6386f@oss.qualcomm.com Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@oss.qualcomm.com>
4 daysMerge tag 'block-7.3-20261010' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux Pull block fixes from Jens Axboe: - NVMe fixes via Keith: - Fix swapped ZRASF zone state values for full and read only - nvme-multipath revalidate head zones after unfreezing the head queue - Revert "nvme: do not reset controllers in NVME_CTRL_NEW state", which broke things - nvmet fixes for invalid NSIDs on feature 82h and using the local P2P device on metadata allocation failure - zloop: zero out only the unread tail of a short read * tag 'block-7.3-20261010' of git://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux: Revert "nvme: do not reset controllers in NVME_CTRL_NEW state" zloop: zero out only the unread tail of short reads nvmet: use the local P2P device on metadata allocation failure nvme-multipath: revalidate head zones after unfreezing the head queue nvme: fix swapped ZRASF zone state values for full and read only nvmet: return Invalid Field for invalid NSIDs feature 82h
4 daysMerge tag 'io_uring-7.3-20261010' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux Pull io_uring fixes from Jens Axboe: - Don't spin on local work the exiting task can't run. For a ring still R_DISABLED when the task got its tctx node, the submitter is set later and may be another task, so DEFER_TASKRUN local work stays pending forever and the exiting task spins in do_exit(). - Don't charge the SQ/CQ rings or provided buffer rings to RLIMIT_MEMLOCK. The region API conversion started charging them, which the rings had been exempt from. - Don't exempt disabled rings from task restrictions on register - Populate the CONNECT filter fields for a 24-byte sockaddr_in6 * tag 'io_uring-7.3-20261010' of git://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux: io_uring/cancel: don't spin on local work the task can't run io_uring/net: populate CONNECT filter fields for 24-byte sockaddr_in6 io_uring/register: don't exempt disabled rings from task restrictions io_uring/kbuf: don't charge provided buffer rings to RLIMIT_MEMLOCK io_uring: do not charge the SQ/CQ rings to RLIMIT_MEMLOCK
4 daysbtf: Preserve string relocation maps for split BTFAlan Maguire
Make btf_relocate() optionally return the string-offset map it builds while relocating a BTF relative to a distilled base. A subsequent split BTF object can use that map to rebase references to base strings. Also account for the accumulated base string offset when assigning a new BTF base. This is required when the base is itself split. Signed-off-by: Alan Maguire <alan.maguire@oracle.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Link: https://patch.msgid.link/20261009112324.1442319-5-alan.maguire@oracle.com
4 dayskbuild, btf: Expose vmlinux inline BTF through sysfsAlan Maguire
Expose BTF inline-location information from vmlinux .BTF.inline sections in /sys/kernel/btf as vmlinux.inline. Embedded vmlinux inline BTF supports read-only mmap(). Provide runtime support for a module-delivered vmlinux inline BTF carrier. Its link record binds the carrier module name, BTF size, and SHA-256 digest to the running kernel before its data is made available through a lazy vmlinux.inline sysfs attribute. The carrier is handled before ordinary module BTF registration, so its incidental .BTF data is not exposed. Make CONFIG_DEBUG_INFO_BTF_INLINE tristate. When configured as a module, retain vmlinux final split inline BTF for btf_vmlinux_inline.ko instead of embedding it in vmlinux. Reserve .BTF.inline.link in vmlinux and extend the final resolve_btfids patch pass to bind btf_vmlinux_inline to the raw vmlinux.BTF.inline payload. This preserves the normal built-in configuration while allowing the large inline BTF payload to load on demand. Normal module inline BTF is handled separately, after its references have been relocated against the final module BTF. Signed-off-by: Alan Maguire <alan.maguire@oracle.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Link: https://patch.msgid.link/20261009112324.1442319-4-alan.maguire@oracle.com
4 daysusb: xhci-pci: Add TUSB73x0 definitionsFabio Estevam
Instead of hard-coding the TUSB73X0 PCI ID, USB_CTRL register address and the PWRON_POLARITY, introduce definitions for them to make the code easier to read. No functional change. Signed-off-by: Fabio Estevam <festevam@gmail.com> Acked-by: Bjorn Helgaas <bhelgaas@google.com> # pci_ids.h Link: https://patch.msgid.link/20261009125154.266435-1-festevam@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>