summaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)Author
2026-09-14ASoC: Add codec_ch_mask to snd_soc_dai_link_ch_mapRichard Fitzgerald
Add a codec_ch_mask member to snd_soc_dai_link_ch_map. The CPU and codec channel masks are not necessarily the same, and are quite likely different. SoundWire and I2S/TDM both support assigning different sample slots to each codec, so for example channel 0 on each codec could map to different channels at the CPU. It is also possible for one TX channel to map to multiple RX channels. So it isn't _always_ safe to assume that the total number of set bits in the CPU ch_mask is the same as the total number of enabled channels on the codec. For example consider this mapping on a capture stream: CPU0 CODEC0 cpu_ch_mask = 0x03 CPU1 CODEC0 cpu_ch_mask = 0x03 This could be either four TX channels on the codec split across two receiving CPUs, or two TX channels on the codec duplicated to two CPUs. Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260910114500.1586637-3-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-09-14ASoC: Rename snd_soc_dai_link_ch_map.ch_mask to cpu_ch_maskRichard Fitzgerald
Rename the ch_mask member of snd_soc_dai_link_ch_map to cpu_ch_mask, as that is what it is used for. The CPU and codec channel masks are not necessarily the same, and are quite likely different. SoundWire and I2S/TDM both support assigning different sample slots to each codec, so for example channel 0 on each codec could map to different channels at the CPU. So it's quite normal that the channel mask at the CPU end is different for each codec, but the codec channel masks are the same for each codec. Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://patch.msgid.link/20260910114500.1586637-2-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-09-13Merge tag 'trace-v7.3-rc2' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace Pull tracing fixes from Steven Rostedt: - Don't destroy user event fields when removal fails User event fields are destroyed before the event is removed from visibility. But that can fail leaving the still visible event with no fields. Move the destroying of the fields to after the event is successfully removed from visibility. - Initialize function graph state is fork before calling copy_exec_state() For non-CLONE_VM forks, copy_exec_state() allocates a new task_exec_state. If that allocation fails, ftrace_graph_exit_task() will free the tasks ret_stack pointer. Since that pointer is still using the parent's ret_stack, it mistakenly frees the parent's pointer too. Call ftrace_graph_init() on the task first which will NULL out the new tasks's ret_stack and if the copy fails, it will not free anything. - Remove FGRAPH_MAX_INDEX The macro FGRAPH_MAX_INDEX was added but never used. Remove it. - Save ent_size in function graph printing of nested functions The function graph tracer needs to look at the next event to see if the next event is the return of the current function entry. If it is, it prints a single line: ktime_get(); Otherwise it prints it like a nested function: tick_nohz_irq_exit() { ktime_get(); kcpustat_irq_exit(); } In order to look at the next event, it must save the current event so that it has the information to print from it. It saves the event in the iterator descriptor called "ent". What it doesn't save is the ent_size of the event which is now used to know if the function graph arguments are to be printed. The peek doesn't save the size so the size used happens to be that of the size of the last event that was seen. Save the entry event size in the iterator descriptor so that the correct size is used. - Fix several errors with freeing data in the histogram code The histogram code had a lot of leaked or or incorrect accounting when failures happen. Correct them. - Fix histogram regression of .percent and .graph modifiers Up until 6.3 histogram values could have "percent" or "graph" modifiers that changed how they were printed. But a change that added restricting histograms values from being strings, stack traces and other modifiers inadvertently prevented them from using the percent and graph modifiers, which were legal use cases for values. Put back the percent and graph modifiers. - Fix various typos in the comments - Set the trace_clock before initializing a histogram with clock argument The histogram API allows the user to specific which trace clock to use via a "clock=" string. The histogram is set up first before the clock is checked. If the passed in clock is not valid, it exits without fully fixing up the histogram leaving it on the list and a use-after-free can trigger. Update the clock argument first and if it fails then exit gracefully before the histogram trigger is placed on any lists. - Restore :mod: trailer after parsing in ftrace_set_clr_event The function ftrace_set_clr_event() modifies the parse string and needs to put it back to what was passed in. It searches for ":mod:" via a strsep() but fails to put back the first ':' in the string. Add back the ':' in the passed in string. - Take trace_array reference when opening a tracer options file The options files are dynamically created and some tracers add their own options. When a tracer adds their own list of options, the trace_array holding them has an array to hold the list of options for each tracer. This array increases in size via a krealloc(), and the new entry gets a newly allocated array to hold the options of the new tracer being added. The element in each entry of the tracer's option array holds a pointer back to the trace_array, a pointer to the tracer it is associated to, a pointer to the flags of the option. The issue is that these arrays are freed when the trace_array is freed when its instance it represents is removed from the instances directory. There's a race that an open of one of these options files can happen when the instance is being removed. Add a new helper function to be called by the open function of the options file to iterate all existing trace_arrays under a lock and find the one that has the given option element in one of it's tracer arrays. If found, then update the associated trace_array's reference counter to keep it from being freed. If not found, have the open call return -ENODEV. - Disable interrupts when acquiring the lock in rb_wake_up_waiters() The function rb_wake_up_waiters() assumes it will be called in interrupt context and does not disable irqs when taking cpu_buffer->reader_lock, which can be called in hard interrupt context. The issue is in PREEMPT_RT, this function is called in thread context leaving this lock open to a deadlock. Take the lock with interrupts disabled. - Use rcu_assign_pointer() for tmp_ops filter hash The tmp_ops used in update_ftrace_direct_mod() assigns its filter_hash field directly, but that field is annotated as __rcu and sparse complains. Assign it with rcu_assign_pointer() - Fix use-after-free in enable_trigger_private_data_free() The trace_event_call is accessed through the event_trigger_data's trace_event_file pointer to put the trace_event_call on freeing. The issue is that the trace_event_file data may have been freed already causing a use-after-free. Add a field to the event_trigger_data that points directly to the trace_event_call so that it can decrement its reference directly without needing to go through the trace_event_file. - Fix accounting of buffer data remote headers trace_buffer_desc_size() and trace_remote_alloc_buffer() undercount the number of pages is needed for the asked for size as it doesn't take into account the meta data on each page. Add a helper function to do the calculation properly and use that in these functions. - Catch nr_page_va overflow in ring_buffer_desc sizing The number of pages per remote ring buffer is capped by ring_buffer_desc::nr_page_va (32 bits). A buffer_size large enough to overflow that field would silently allocate a descriptor smaller than what was asked for. - Do not resize the subbuf order if any per_cpu buffer is disabled The mmapping of ring buffers disables resizing the subbuffers, but it is done per-cpu whereas the subbuf size change is done for all the per_cpu buffers under the buffer->mutex. It could change the size of some while the mapping is happening on others. Have the resize of the subbuf order check all the per_cpu buffers under the lock to see if any of them is disabled before starting and causing an inconsistency between buffers that are being mapped. * tag 'trace-v7.3-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace: (25 commits) ring-buffer: Check resize_disabled before publishing the new subbuf order tracing/remotes: Catch nr_page_va overflow in ring_buffer_desc sizing tracing/remotes: Account for ring buffer page header in size calculation tracing: Don't dereference trace_event_file in deferred trigger free ftrace: Use rcu_assign_pointer() for tmp_ops filter hash ring-buffer: Acquire the lock with irqsave in rb_wake_up_waiters() tracing: Take trace_array reference when opening a tracer options file tracing: Fix ring_buffer_read_page_size() kernel-doc tracing: Restore :mod: trailer after parsing in ftrace_set_clr_event() tracing: Fix memory corruption from a "STACKTRACE" histogram key tracing: Fix memory corruption from the histogram stacktrace modifier tracing: Undo the registration when enabling the histogram trigger fails tracing: Take the reference before publishing the named histogram trigger tracing: Set the trace clock before registering the histogram trigger tracing: Fix typo "preceeded" in comment tracing: Fix typo "availabe" in comment tracing: Let histogram values keep the percent and graph modifiers tracing: Keep the entry count when the histogram stats allocation fails tracing: Free histogram the field rejected for a bad modifier tracing: Free histogram the var ref when its initialization fails ...
2026-09-13tracing/remotes: Catch nr_page_va overflow in ring_buffer_desc sizingVincent Donnefort
The number of pages per remote ring buffer is capped by ring_buffer_desc::nr_page_va (32 bits). A buffer_size large enough to overflow that field would silently allocate a descriptor smaller than what was asked for. Return SIZE_MAX from trace_buffer_desc_size() on nr_page_va overflow. Link: https://patch.msgid.link/20260911193937.602202-3-vdonnefort@google.com Fixes: 2e67fabd8b77 ("ring-buffer: Introduce ring-buffer remotes") Signed-off-by: Vincent Donnefort <vdonnefort@google.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2026-09-13tracing/remotes: Account for ring buffer page header in size calculationVincent Donnefort
trace_buffer_desc_size() and trace_remote_alloc_buffer() undercount the required pages because every ring buffer page contains a header (BUF_PAGE_HDR_SIZE). Account for that header to ensure allocated remote ring buffers aren't smaller than requested by the user. The newly introduced helper __calc_nr_pages_ring_buffer_desc() can return a value that overflows the descriptor nr_pages field (32 bits). Link: https://patch.msgid.link/20260911193937.602202-2-vdonnefort@google.com Fixes: 2e67fabd8b77 ("ring-buffer: Introduce ring-buffer remotes") Signed-off-by: Vincent Donnefort <vdonnefort@google.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2026-09-13Merge tag 'sched-urgent-2026-09-13' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull scheduler fixes from Ingo Molnar: - Fix EEVDF se->max_slice value on enqueueing (Vincent Guittot) - Fix EEVDF augmented rb-trees re-balancing with multiple fields (Vincent Guittot) - In proxy scheduling, account cgroup CPU time to the execution context, not the scheduling context (Hui Su) - Likewise, call wq_worker_tick() for the execution context, not the scheduling context (Hui Su) * tag 'sched-urgent-2026-09-13' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: sched/core: Call wq_worker_tick() for the execution context sched: Account cgroup CPU time to the execution context sched/eevdf: Fix rb augmented with multi fields sched/eevdf: Fix augmented max_slice
2026-09-13Merge tag 'core-urgent-2026-09-13' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull entry code fix from Ingo Molnar: - Fix generic entry code cross-build failure on !CONFIG_AUDITSYSCALL kernels using older RISCV64 and S390 cross-compilers (Thomas Gleixner) * tag 'core-urgent-2026-09-13' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: entry: Guard syscall_enter_audit() invocation with CONFIG_AUDITSYSCALL
2026-09-12bpf: Prepare kfunc arguments for the JIT from an ABI descriptionYonghong Song
The previous patch refuses a kfunc argument of more than one eightbyte. This patch allows up to 16 byte kfunc arguments. But different architectures have different ways to map the BPF calling convention (no gap, no backfill) to the native one. Rather than have each arch open-code where it wants an argument, describe the convention with a register count and four booleans, and let each arch set what applies to it: struct bpf_jit_arg_abi { u8 nr_arg_regs; bool even_reg_align; bool even_stack_align; bool split_at_boundary; bool backfill_after_stack; }; The four booleans are meant to cover x86-64, arm64, RISC-V LP64 and PowerPC64 ELFv2, although only x86-64 and arm64 fill the struct in here. bpf_jit_place_args() and bpf_jit_plan_arg_moves() use that description to work out where each argument belongs and which slots the JIT then has to move, to be used in the JIT later on. Signed-off-by: Yonghong Song <yonghong.song@linux.dev> Link: https://lore.kernel.org/r/20260912195242.989416-1-yonghong.song@linux.dev Signed-off-by: Alexei Starovoitov <ast@kernel.org>
2026-09-12bpf: Rename bpf_call_summary::num_params to arg_slot_cntYonghong Song
The field 'num_params' counts the argument registers and outgoing stack slots a helper or kfunc call takes. The next patch gives a 16-byte parameter two slots, so the name stops describing what the field holds. Rename 'num_params' to 'arg_slot_cnt'. No functional change. Signed-off-by: Yonghong Song <yonghong.song@linux.dev> Link: https://lore.kernel.org/r/20260912195232.988528-1-yonghong.song@linux.dev Signed-off-by: Alexei Starovoitov <ast@kernel.org>
2026-09-12bpf: Rename bpf_subprog_info::arg_cnt to arg_slot_cntYonghong Song
Rename arg_cnt to arg_slot_cnt, as a later patch gives a parameter that takes two argument registers, an __int128 or a 16-byte aggregate, two slots. No functional change. Signed-off-by: Yonghong Song <yonghong.song@linux.dev> Link: https://lore.kernel.org/r/20260912195211.986081-1-yonghong.song@linux.dev Signed-off-by: Alexei Starovoitov <ast@kernel.org>
2026-09-12ACPI: processor: thermal: Use more suitable cooling device dataRafael J. Wysocki
Instead of passing an ACPI device object pointer as devdata to thermal_cooling_device_create(), make acpi_processor_thermal_init() pass a pointer to the struct acpi_processor representing the given CPU to it, which allows the callback functions in processor_cooling_ops to be simplified and the second argument of acpi_processor_thermal_init() and acpi_processor_thermal_exit() to be dropped. No intentional functional impact. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: Armin Wolf <W_Armin@gmx.de> Link: https://patch.msgid.link/6192780.MhkbZ0Pkbq@rafael.j.wysocki
2026-09-12ACPI: processor: thermal: Use thermal_cooling_device_create()Rafael J. Wysocki
Instead of using thermal_cooling_device_register() for registering a cooling device in the ACPI processor driver, make it use thermal_cooling_device_create() and pass a pointer to the processor device representing the given CPU to that function as the cooling device's parent. That will cause the cooling device's sysfs directory to be created under the parent's sysfs directory (among other things). Since creating a class device under a parent causes a "device" symbolic link from the sysfs directory of the class device to the sysfs directory of the parent to appear automatically, remove the code creating the "device" symbolic link from the sysfs directory of the cooling device in question to the sysfs directory of the parent's companion ACPI device. That ACPI device is reachable through the "firmware_node" symbolic link in the parent's sysfs directory regardless. Moreover, since the cooling device is now located in sysfs under its parent and it can be easily identified as a cooling device, there is no need to create a "thermal_cooling" symbolic link from its parent's ACPI companion to it. Accordingly, also remove the code creating that symbolic link. While at it, check for error pointer values in addition to checking for NULL in acpi_processor_thermal_exit() to avoid dereferencing them mistakenly. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: Armin Wolf <W_Armin@gmx.de> [ rjw: Corrected typo in the changelog ] Link: https://patch.msgid.link/2362345.iZASKD2KPV@rafael.j.wysocki Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2026-09-12thermal: core: Introduce thermal_cooling_device_create()Rafael J. Wysocki
Currently, thermal cooling devices have no parents, but it would be generally useful to be able to create them under specific parents in the device hierarchy (for instance, it may help to identify the device representing the actual cooling hardware). To make that possible, add thermal_cooling_device_create() that will work like thermal_cooling_device_register() except that it will take an additional parent argument (which may be NULL). Redefine thermal_cooling_device_register() as a static inline wrapper around thermal_cooling_device_create(). Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: Armin Wolf <W_Armin@gmx.de> Link: https://patch.msgid.link/8729484.T7Z3S40VBb@rafael.j.wysocki
2026-09-12ALSA: control: Fix virtual master creation reference in kernel-docKarl Mehltretter
The snd_ctl_add_follower() comment refers to snd_ctl_create_virtual_master(), but virtual master controls are created with snd_ctl_make_virtual_master(). Correct the helper name. Fixes: 79c7cdd5441f ("ALSA: Add kernel-doc comments to vmaster stuff") Assisted-by: LLM Signed-off-by: Karl Mehltretter <kmehltretter@gmail.com> Link: https://patch.msgid.link/20260912100548.86134-1-kmehltretter@gmail.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2026-09-11bpf: Resolve BTF ID of ARG_PTR_TO_BTF_ID in kfunc bpf_func_protoAmery Hung
check_kfunc_args() walks the kfunc's BTF on every verification of a call to work out which BTF ID an ARG_PTR_TO_BTF_ID argument expects. Helpers name theirs in bpf_func_proto::arg_btf_id[], as a pointer to a BTF ID that resolve_btfids fills in at build time. The ID of a kfunc argument's referent is already stored in the immutable BTF records that describe its pointer and modifier chain. Make arg_btf_id[] point to the BTF field containing the resolved ID. A __map argument instead uses the existing vmlinux BTF ID pointer. Produce this metadata alongside the argument classification in get_kfunc_arg_type(). Declare the argument BTF ID pointers const, since the verifier only reads through them. The BTF object owns their storage and remains alive while the generated prototype is used, so the pointers remain valid when the kfunc descriptor array is reallocated or sorted. Both helper and kfunc callers can now read the expected BTF ID through the same bpf_func_proto field, which lets check_func_arg() take over the ARG_PTR_TO_BTF_ID case. arg_btf_id[] shares a union with arg_size[], so an argument cannot store both. The scalar-struct memory fallback keeps resolving its byte size at verification time, as it does today. No functional change. Signed-off-by: Amery Hung <ameryhung@gmail.com> Link: https://lore.kernel.org/r/20260911220415.1396439-13-ameryhung@gmail.com Signed-off-by: Alexei Starovoitov <ast@kernel.org>
2026-09-11bpf: Align helper and kfunc ARG_PTR_TO_PROG_AUX handlingAmery Hung
The verifier supplies a bpf_prog_aux argument to both bpf_timer_set_callback() and kfuncs rather than reading it from the BPF program. The helper prototype leaves its third argument unused, while the kfunc path identifies the argument from BTF at every call. Add ARG_PTR_TO_PROG_AUX, record it in the helper prototype, and classify the kfunc argument when its prototype is generated. Because other ignored and implicit arguments are already represented by ARG_IGNORE, the generated prototype has no internal ARG_UNUSED gaps. Validate in one place that it contains at most one prog-aux argument and that the argument is register-passed, as required by the BPF_LD_IMM64 fixup. Record the argument register in the per-instruction metadata for both call kinds. Drive the helper fixup from that metadata instead of the helper ID and its hard-coded R3, matching the existing kfunc fixup. bpf_call_arg_meta::arg_prog is then no longer needed. No functional change beyond reporting invalid kfunc signatures when the call is added rather than when it is verified. Signed-off-by: Amery Hung <ameryhung@gmail.com> Link: https://lore.kernel.org/r/20260911220415.1396439-9-ameryhung@gmail.com Signed-off-by: Alexei Starovoitov <ast@kernel.org>
2026-09-11bpf: Classify kfunc arguments the verifier ignoresAmery Hung
The verifier does not inspect __ign arguments or implicit arguments, except that bpf_prog_aux is handled specially. get_kfunc_arg_type() leaves the ignored arguments unclassified, so gen_kfunc_arg_proto() skips them and check_kfunc_args() repeats the same BTF predicates for every call. Add ARG_IGNORE and classify ignored arguments in get_kfunc_arg_type(). The generated prototype can then record them, and the call site can consume the recorded type without deriving the classification again. Keep bpf_prog_aux on its existing BTF-based path for now. No functional change. Signed-off-by: Amery Hung <ameryhung@gmail.com> Link: https://lore.kernel.org/r/20260911220415.1396439-8-ameryhung@gmail.com Signed-off-by: Alexei Starovoitov <ast@kernel.org>
2026-09-11bpf: Unify kfunc argument kinds with enum bpf_arg_typeAmery Hung
check_kfunc_args() classifies arguments with enum kfunc_ptr_arg_type while check_func_arg() uses enum bpf_arg_type, yet both classifications are stored in bpf_func_proto::arg_type. The overlapping namespaces force the kfunc path to translate argument kinds before calling shared checks. Fold the kfunc kinds into enum bpf_arg_type. Reuse ARG_SCALAR and the existing pointer and memory kinds where their semantics match, map kfunc callbacks to ARG_PTR_TO_FUNC, and add enumerators for the remaining kfunc-only kinds. check_kfunc_args() can then carry one classification throughout verification. Preserving the original argument kind also lets check_func_arg_reg_off() derive the zero-offset requirement for ARG_PTR_TO_REFCOUNTED_KPTR directly. Remove its separate btf_id_fixed_off_ok parameter and wrapper, along with the now-empty translation switch in check_kfunc_args(). Keep the PTR_TO_CTX offset decision based on the base argument kind. The generated kind may carry flags such as PTR_MAYBE_NULL, while the removed translation discarded them. This retains the zero-offset requirement for context arguments regardless of such flags. No functional change. Signed-off-by: Amery Hung <ameryhung@gmail.com> Link: https://lore.kernel.org/r/20260911220415.1396439-7-ameryhung@gmail.com Signed-off-by: Alexei Starovoitov <ast@kernel.org>
2026-09-11bpf: Clarify unused and scalar function argument typesAmery Hung
ARG_DONTCARE is the zero-valued terminator for the fixed-size helper argument array rather than an argument whose value is ignored. Rename it to ARG_UNUSED and stop helper argument iteration explicitly when it is encountered. Commit c3fd8e5fd100 ("bpf: Reject non-scalar bpf_loop iteration counts") introduced ARG_SCALAR for arguments that must be scalars. Reuse it for integer and enum global subprogram arguments, which already require SCALAR_VALUE despite being classified as ARG_ANYTHING, and for exception callback arguments. This leaves ARG_ANYTHING with its legacy helper behavior of accepting pointers when pointer leaks are allowed. Also pass ARG_PTR_TO_MEM when checking a global subprogram memory argument instead of using the prototype terminator as a placeholder. No functional change. Signed-off-by: Amery Hung <ameryhung@gmail.com> Link: https://lore.kernel.org/r/20260911220415.1396439-6-ameryhung@gmail.com Signed-off-by: Alexei Starovoitov <ast@kernel.org>
2026-09-11net: dropreason: add SKB_DROP_REASON_IP_TTL_EXCEEDEDJunjie Cao
The forwarding paths report an expired TTL or hop limit as SKB_DROP_REASON_IP_INHDR, the reason otherwise used for a header that is malformed (ip_input.c, exthdrs.c, br_netfilter). Nothing else in the drop path separates the two: IPSTATS_MIB_INHDRERRORS covers both, and the TTL check runs before NF_INET_FORWARD, so netfilter tracing stops at PREROUTING and never sees the drop. The Fedora bug linked below shows how that reads in practice. The reporter took kfree_skb(reason=IP_INHDR, loc=ip_forward) to mean the software header checksum check had failed, and worked through RX checksum offload, tc csum actions and both libvirt firewall backends before the drops turned out to be replies arriving with TTL 1. ip_forward() never verifies the header checksum; that runs earlier, in ip_rcv_core(), and reports IP_CSUM. TTL expiry is not a corner case -- every traceroute through a Linux router goes through too_many_hops. The three loopback hop limit checks in exthdrs.c drop with no reason at all; give them the new one. IPSTATS_MIB_INHDRERRORS stays as it is: RFC 1213 counts time-to-live exceeded under ipInHdrErrors. The drop reason has no such constraint. Link: https://bugzilla.redhat.com/show_bug.cgi?id=2517131 Signed-off-by: Junjie Cao <junjie.cao@intel.com> Reviewed-by: Jiayuan Chen <jiayuan.chen@linux.dev> Reviewed-by: Fernando Fernandez Mancera <fmancera@suse.de> Reviewed-by: Hangbin Liu <liuhangbin@kylinos.cn> Link: https://patch.msgid.link/20260910094937.536150-1-junjie.cao@intel.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2026-09-11clk: tegra: fix typos in commentsHemanth Selam
Fix typos in comments, reported by scripts/checkpatch.pl using the misspelling list in scripts/spelling.txt. Only touches comments, no code changes. Assisted-by: Cursor:claude-opus-5 Signed-off-by: Hemanth Selam <hemanth.selam@gmail.com> Signed-off-by: Brian Masney <bmasney@redhat.com>
2026-09-12keys: translate request_key_auth pid for the reading procfs instanceMaoyi Xie
request_key_auth_describe() prints rka->pid into /proc/keys as a raw pid_t in the initial pid namespace. A reader can open /proc/keys through a mount in another pid namespace. That reader sees a number with no meaning there. The number can even name an unrelated task. The line needs VIEW on the key. So the reader either shares the key owner's uid or possesses the key. The fix keeps a struct pid. Commit 4f82f45730c6 ("net ip6 flowlabel: Make owner a union of struct pid * and kuid_t") gave /proc/net/ip6_flowlabel the same storage. The print goes through pid_nr_ns(). It renders against the pid namespace of the procfs instance the line is read through. Commit ad08978ab41c ("ipv6/flowlabel: simplify pid namespace lookup") moved that print to the same anchor. Output through an initial namespace /proc does not change. The line shows 0 for a requestor with no number in that namespace. Translating at read time was the alternative. find_pid_ns() can resolve a recycled number. The line would then name a live task with no connection to the key. A stored struct pid gives 0 instead when the requestor has no number there. Link: https://lore.kernel.org/keyrings/20260809110202.2180410-1-maoyixie.tju@gmail.com/ Fixes: 78b7280cce23 ("KEYS: Improve /proc/keys") Cc: stable@vger.kernel.org # v5.10+ Assisted-by: Claude:claude-opus-5 codeql Signed-off-by: Maoyi Xie <maoyixie.tju@gmail.com> Link: https://lore.kernel.org/r/20260821095935.1864998-1-maoyixie.tju@gmail.com Reviewed-by: Jarkko Sakkinen <jarkko@kernel.org> Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
2026-09-11Merge tag 'riscv-for-linus-7.3-rc3' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux Pull RISC-V fixes from Paul Walmsley: "From a RISC-V point of view, there's one notable fix here, reverting an earlier bogus fix to the pointer masking code. Fortunately the practical impact appears to be small. - Revert a bad fix, likely LLM-generated, in the pointer masking code that confused the RISC-V hardware pointer masking implementation with the Linux kernel tagged address feature - Fix unexpected faults caused by kprobe instruction slot writes when !CONFIG_STRICT_MODULE_RWX - Fix unexpected faults on minimal configurations during runtime code patching on !CONFIG_STRICT_MODULE_RWX systems - Fix a misplaced variable clear causing incorrect reuse of previous values in the RISC-V hardware feature probing code - Fix two bugs in the PMU SBI perf code on rv32: use BIT_ULL rather than BIT on 64-bit masks; and use a bitmap rather than an unsigned long on a quantity that can exceed 32 bits And a few miscellaneous cleanups: - Avoid a potential dereference-before-NULL-pointer-check bug in the PMU SBI perf driver - Use CONFIG_GENERIC_BUG_RELATIVE_POINTERS to simplify the rv32 bug table code (like x86 and PPC) - Report the RISC-V standard ISA extensions Z[v]fhmin when support is claimed for the superset RISC-V standard ISA extensions Z[v]fh; and simplify our FPU test code to only check for the presence of the D extension - Use an existing kernel string helper in place of some open-coded code in kernel/usercfi.c - Fix some yamllint issues in the RISC-V DT bindings for CPUs - Convert one use of __ASSEMBLY__ to __ASSEMBLER__ that snuck into the RISC-V CFI selftest code - Update the translation for the simplified Chinese translation of the RISC-V kernel patch acceptance policy" * tag 'riscv-for-linus-7.3-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux: riscv: skip software algning code for HAVE_EFFICIENT_UNALIGNED_ACCESS kselftest/riscv: Replace __ASSEMBLY__ with __ASSEMBLER__ docs/zh_CN: Update arch/riscv/patch-acceptance.rst translation dt-bindings: riscv: cpus: Fix yamllint style issues riscv: hwprobe: simplify has_fpu() to check D extension only perf: RISC-V: check cpu_hw_evt before dereference in overflow IRQ riscv: report Zfhmin/Zvfhmin when Zfh/Zvfh are present perf: RISC-V: store available counter mask as bitmap perf: RISC-V: use BIT_ULL for u64 overflow masks riscv: bug: Make RV32 use GENERIC_BUG_RELATIVE_POINTERS riscv: hwprobe: initialize pair->value in hwprobe_one_pair() riscv: use string helper in setup_global_riscv_enable() Revert "riscv: Reset pmm when PR_TAGGED_ADDR_ENABLE is not set" riscv: patch: skip fixmap mapping when kernel text is already writable riscv: mm: make EXECMEM_KPROBES writable without CONFIG_STRICT_MODULE_RWX
2026-09-11KVM: Never clear KVM_REQ_VM_DEAD from a vCPU's requestsSean Christopherson
Use kvm_test_request() instead of kvm_check_request() when querying KVM_REQ_VM_DEAD, i.e. don't clear KVM_REQ_VM_DEAD, as the entire purpose of KVM_REQ_VM_DEAD is to prevent the vCPU from enterring the guest ever again, even if userspace insists on redoing KVM_RUN. Ensuring KVM_REQ_VM_DEAD is never cleared will allow relaxing KVM's rule that ioctls can't be invoked on dead VMs, to only disallow ioctls if the VM is bugged, i.e. if KVM hit a KVM_BUG_ON(). Opportunistically add compile-time assertions to guard against clearing KVM_REQ_VM_DEAD through the standard APIs. Reviewed-by: Kai Huang <kai.huang@intel.com> Acked-by: Marc Zyngier <maz@kernel.org> Link: https://patch.msgid.link/20260806214618.82180-1-seanjc@google.com Signed-off-by: Sean Christopherson <seanjc@google.com>
2026-09-11lsm: expose mount idmaps to inode hooksDaan De Meyer
OverlayFS performs upper-layer operations through inode-based security hooks. Those hooks receive the upper inode and dentry, but not the mount idmap used by the VFS operation. The security layer cannot distinguish an identity-mapped upper from an idmapped one or make the same ownership decision as the VFS. The VFS layer already passes the idmap down into all relevant inode operations so this just brings the security hooks to parity. So pass the mount idmap through the create, link, symlink, mkdir, mknod, and permission hooks. Update the in-tree security implementations and non-VFS callers accordingly. Signed-off-by: Daan De Meyer <daan@amutable.com> Reviewed-by: Christian Brauner (Amutable) <brauner@kernel.org> [PM: updated the commit description as discussed on-list] Signed-off-by: Paul Moore <paul@paul-moore.com>
2026-09-11tracing: Fix typo "preceeded" in commentHemanth Selam
Correct "preceeded" to "Preceded", reported by scripts/checkpatch.pl using the misspelling list in scripts/spelling.txt. Only touches comments, no code changes. Link: https://patch.msgid.link/20260907065607.36615-1-hemanth.selam@gmail.com Assisted-by: Cursor:claude-opus-5 Signed-off-by: Hemanth Selam <hemanth.selam@gmail.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2026-09-11media: ipu-bridge: Request non-continuous clock for ov5693 on IPU6Fernando Rimoli
The ov5693 (INT33BE / OVTI5693) needs its MIPI clock lane gated while idle for the IPU6 CSI-2 receiver to lock onto the link, which the sensor driver does when the endpoint requests a non-continuous clock. The same sensor works with a free-running clock on the IPU3, so request it only for the IPU6 variants where it has been confirmed on hardware: Tiger Lake, Alder Lake-P and Alder Lake-N. Signed-off-by: Fernando Rimoli <fernandorimoli11@gmail.com> Tested-by: Jakob Berg Jespersen <dev@berg.pm> # Surface Pro 7+, IPU6 Tiger Lake Tested-by: Fil Dunsky <filipp.dunsky@gmail.com> # Surface Pro 8, IPU6 Tiger Lake (8086:9a19) Tested-by: Lucas Lis <lucaseze.lis@gmail.com> # Surface Pro 7+, IPU6 Tiger Lake (0x9a19) Tested-by: Kengo Oki <dev.kengo.fugu0141@gmail.com> # Surface Go 4, IPU6 Alder Lake-N 8086:462e Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
2026-09-11media: ipu-bridge: Match sensor configs per IPU and add config flagsFernando Rimoli
Some sensors need different treatment depending on which IPU they are connected to, so the ACPI HID alone is not enough. Match on an optional list of IPU PCI product IDs. Entries for one HID must be adjacent, IPU-specific ones first, so the generic entry is skipped once a specific one has matched. Signed-off-by: Fernando Rimoli <fernandorimoli11@gmail.com> Tested-by: Jakob Berg Jespersen <dev@berg.pm> # Surface Pro 7+, IPU6 Tiger Lake Tested-by: Fil Dunsky <filipp.dunsky@gmail.com> # Surface Pro 8, IPU6 Tiger Lake (8086:9a19) Tested-by: Lucas Lis <lucaseze.lis@gmail.com> # Surface Pro 7+, IPU6 Tiger Lake (0x9a19) Tested-by: Kengo Oki <dev.kengo.fugu0141@gmail.com> # Surface Go 4, IPU6 Alder Lake-N 8086:462e Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
2026-09-11media: ipu-bridge: Assign endpoint property indices dynamicallyFernando Rimoli
Index the ep_properties array dynamically instead of plain numerical values as is done in mipi-disco-img.c. Signed-off-by: Fernando Rimoli <fernandorimoli11@gmail.com> Tested-by: Jakob Berg Jespersen <dev@berg.pm> # Surface Pro 7+, IPU6 Tiger Lake Tested-by: Fil Dunsky <filipp.dunsky@gmail.com> # Surface Pro 8, IPU6 Tiger Lake (8086:9a19) Tested-by: Lucas Lis <lucaseze.lis@gmail.com> # Surface Pro 7+, IPU6 Tiger Lake (0x9a19) Tested-by: Kengo Oki <dev.kengo.fugu0141@gmail.com> # Surface Go 4, IPU6 Alder Lake-N 8086:462e Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
2026-09-11media: ipu-bridge: Add ipu_bridge_get_ipu6()Sakari Ailus
Add ipu_bridge_get_ipu6() for obtaining the IPU 6 (or soon later) PCI device. This isn't technically a job of the IPU bridge, but the functionality is required in conjunction with the firmware definitions that necessitate the use of the IPU bridge on many systems. Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Reviewed-by: Antti Laakso <antti.laakso@linux.intel.com> Reviewed-by: Daniel Scally <dan.scally@ideasonboard.com>
2026-09-11Merge tag 'media/v7.3-2' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media Pull media fixes from Mauro Carvalho Chehab: "Core: - add bounded tile-count helpers for HEVC stateless decoders - validate AV1 tile counts fits in array size - validate HEVC tile counts fits in array size - fix memcmp() size in B1 reference list comparison mediatek: - bound AV1 tile-start copy to fit in array size rockchip: - reject AV1 frames exceeding the tile size - guard VPU981 AV1 divisor and tile buffer hantro and rkvdec: - bound G2 HEVC tile loops and PPS id to the buffer size rppx1: - read the raw pattern from the PRE2 acquisition module - describe the MAIN_POST white balance gains block" * tag 'media/v7.3-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: media: mediatek: vcodec: bound AV1 tile-start copy to the array capacity media: verisilicon: rockchip: reject AV1 frames exceeding the tile capacity media: verisilicon: rockchip: guard VPU981 AV1 divisor and tile buffer media: verisilicon: hantro: bound G2 HEVC tile loop to the buffer capacity media: rkvdec: bound HEVC tile loops and PPS id to the array capacity media: hevc: add bounded tile-count helpers media: v4l2-ctrls: validate AV1 tile counts media: v4l2-ctrls: validate HEVC tile counts media: v4l2-h264: Fix memcmp() size in B1 reference list comparison media: rppx1: bls: read the raw pattern from the PRE2 acquisition module media: rppx1: describe the MAIN_POST white balance gains block
2026-09-11iommufd: Iterate the cache invalidation array in the coreNicolin Chen
The cache invalidation ops, cache_invalidate_user() for a nested HWPT and the cache_invalidate() for a vIOMMU, are each handed the full user request array and report how many of the array entries they handled by setting the array->entry_num. Every driver therefore implements its own loop over the array, and a driver wanting to process that array in fixed-size chunks (e.g. to issue commands out of a fixed-size on-stack buffer) has to carry the loop and its sub-array bookkeeping all on its own. Move the iteration into the iommufd core instead. Invoke the op with a sub-array that starts at the first not-yet-handled entry, let it handle a prefix of that sub-array and report the count via array->entry_num, then advance the base pointer and re-invoke the op until the entire array has been consumed or until the op returns an error along the way. A driver that handles the entire window in one single call, as all of the current drivers happen to do, finishes the loop in just one pass, so this does not change any of the existing behavior. It instead lets each of the drivers convert to bounded chunk processing on its own, done by each of the subsequent changes. Suggested-by: Jason Gunthorpe <jgg@nvidia.com> Reviewed-by: Kevin Tian <kevin.tian@intel.com> Reviewed-by: Lu Baolu <baolu.lu@linux.intel.com> Reviewed-by: Pranjal Shrivastava <praan@google.com> Reviewed-by: Jason Gunthorpe <jgg@nvidia.com> Assisted-by: Claude:claude-opus-4-8 Signed-off-by: Nicolin Chen <nicolinc@nvidia.com> Link: https://patch.msgid.link/e1896d79382392f8a0bf0ae736aa295f11c45ef0.1788127877.git.nicolinc@nvidia.com Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
2026-09-11iommu/arm-smmu-v3-iommufd: Reject unsupported bits in invalidation commandsNicolin Chen
The arm_vsmmu_cache_invalidate() op hands a guest's invalidation commands to the trusted main command queue after enforcing only the VMID or the SID, and passes the rest of the command through to the queue unchanged. That lets a guest set bits the host never meant to forward: a reserved or undefined bit makes a command malformed; per the Arm SMMUv3 specification, in its section 4.1.3 "Command errors", a CERROR_ILL is raised, among other cases, when: A valid command opcode is used and a Reserved or undefined field is optionally detected as non-zero, which results in the command being treated as malformed. Restrict each opcode to the fields that the driver supports and reject the command with -EIO if it sets any other bit, before the command reaches the queue. This stops the host from forwarding any bit whose meaning it does not control. Document this contract in the uAPI header, so user space must take the responsibility to forward valid commands only. Some fields and whole opcodes are legal only on an SMMU that implements the matching feature, so accept them conditionally: - NUM, SCALE, TG and TTL need FEAT_RANGE_INV. - SCALE bit 25, for values above 31, and TTL == 0b01 with a 16KB TG need SMMU_IDR5.DS, gated on ARM_SMMU_FEAT_DS so that a VMM exposing DS from the reported IDR5 register keeps working. - ASID is limited to asid_bits, since its upper 8 bits are RES0 on an SMMU that only supports 8-bit ASIDs. - ATC_INV needs FEAT_ATS. Per the specification's section 4.5 "ATS and PRI", CMD_ATC_INV is ILLEGAL when: SMMU_IDR0.ATS == 0 and this command is issued on a Non-secure or Secure Command queue. - SSV, SSID and Global need a non-zero ssid_bits. Without it, setting them is not illegal but CONSTRAINED UNPREDICTABLE, which a guest should not be able to provoke. Global also takes effect only when SSV == 1, broadening the invalidation from the one SSID to all the PASIDs of the single device that the SID field addresses. Some values inside the accepted fields are Reserved too: - NUM == 0, SCALE == 0 and TTL == 0 together are a Reserved combination and cause a CERROR_ILL. - NUM, SCALE and TTL turn RES0 when TG == 0. - An ATC_INV Size above 52, the invalidate-all span, is permitted to raise a CERROR_ILL. Reject these Reserved values the same way. In contrast, an out-of-range address or ID value is defined as CONSTRAINED UNPREDICTABLE that would be scoped to the guest itself, so it does not deserve a check. Fixes: d68beb276ba2 ("iommu/arm-smmu-v3: Support IOMMU_HWPT_INVALIDATE using a VIOMMU object") Cc: stable@vger.kernel.org Reviewed-by: Jason Gunthorpe <jgg@nvidia.com> Reviewed-by: Pranjal Shrivastava <praan@google.com> Assisted-by: Claude:claude-fable-5 Signed-off-by: Nicolin Chen <nicolinc@nvidia.com> Link: https://patch.msgid.link/40f4aabf98e434d6ac9f42a8d278b92200f202ca.1788127877.git.nicolinc@nvidia.com Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
2026-09-11HID: hiddev: keep state alive through disconnect unlockYousef Alhouseen
mutex_unlock() clears the mutex owner before taking its wait lock. A thread spinning in the final hiddev file release can acquire existancelock after hiddev_disconnect() clears the owner, then free hiddev before the disconnecting thread reaches the mutex wait lock. This causes a use-after-free in the mutex slow unlock path. Give the connection and each open file an explicit reference. Drop each reference only after its existancelock critical section has completed, so neither unlock path can free the mutex while the other is still using it. Fixes: 079034073faf ("HID: hiddev cleanup -- handle all error conditions properly") Reported-by: syzbot+563191a4939ddbfe73d4@syzkaller.appspotmail.com Closes: https://syzkaller.appspot.com/bug?extid=563191a4939ddbfe73d4 Cc: stable@vger.kernel.org Signed-off-by: Yousef Alhouseen <alhouseenyousef@gmail.com> Link: https://syzkaller.appspot.com/bug?extid=563191a4939ddbfe73d4 Signed-off-by: Jiri Kosina <jkosina@suse.com>
2026-09-11vga-switcheroo: Remove unused interfacesThomas Zimmermann
Remove all unused interfaces that used to implement the functionality of pre_switch and post_switch. For pre_switch, remove vga_switcheroo_client_fb_set(). This further allows for removing all symbols and data structures that refer to fbdev; such as fb_info and fb_switch_outputs(). For post_switch, remove the reprobe callback from the client ops. v2: - move changes to fbcon and drivers into other patches Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Maxime Ripard <mripard@kernel.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patch.msgid.link/20260709092215.168172-8-tzimmermann@suse.de
2026-09-11vga_switcheroo: Add post_switch callback to client opsThomas Zimmermann
Add post_switch to struct vga_switcheroo_client_ops to inform the switcheroo client about a completed switch of the output. This callback is intended to replace the reprobe client op. It is a rename of reprobe for consistency with pre_switch. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Maxime Ripard <mripard@kernel.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patch.msgid.link/20260709092215.168172-5-tzimmermann@suse.de
2026-09-11vga_switcheroo: Add pre_switch callback to client opsThomas Zimmermann
Add pre_switch to struct vga_switcheroo_client_ops to inform the switcheroo client about upcoming switches of the outputs. This callback is intended to replace the hard-coded call to fbdev's fb_switch_outputs(). With DRM supporting more clients than just fbdev emulation, something more flexible is required. v2: - remove non-sensical gpu_bound documentation (Sashiko) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Maxime Ripard <mripard@kernel.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patch.msgid.link/20260709092215.168172-4-tzimmermann@suse.de
2026-09-11drm/client: Add acquire_outputs callback; implement for fbdev emulationThomas Zimmermann
Add the callback acquire_outputs to drm_client_funcs to inform an internal DRM client that vga-switcheroo is about to switch the physical outputs to the client's device. Allows the client to prepare its internal state for the upcoming switch. Wire up the DRM client helpers to invoke the helper for a device's clients. Implement acquire_outputs for fbdev emulation. Invoke fb_switch_outputs(), which remaps framebuffers to virtual terminals in fbcon. Currently this is still being done by vga-switcheroo. With more DRM clients becoming available, vga-switcheroo needs to become client agonostic. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Maxime Ripard <mripard@kernel.org> Acked-by: Helge Deller <deller@gmx.de> Link: https://patch.msgid.link/20260709092215.168172-3-tzimmermann@suse.de
2026-09-11bootconfig: merge _xbc_exit() into xbc_exit()Sang-Heon Jeon
Since commit 87ce9e83ab8b ("memblock, treewide: make memblock_free() handle late freeing"), both branches of xbc_free_mem() call memblock_free(), and the early argument has no effect. memblock_free() also does nothing if addr is NULL, so the check before the call is redundant. So remove the argument and the NULL check, and merge _xbc_exit() into xbc_exit(). No functional change. Link: https://lore.kernel.org/all/20260908165712.1703439-1-ekffu200098@gmail.com/ Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com> Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
2026-09-11firewire: core: remove unused link field in fw_packet structureTakashi Sakamoto
The link field in fw_packet structure has never been used since it was added. Fixes: 3038e353cfaf ("firewire: Add core firewire stack.") Link: https://lore.kernel.org/r/20260911141602.3288806-1-o-takashi@sakamocchi.jp Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
2026-09-12firewire: cdev: Fix FW_CDEV_IOC_CREATE_ISO_CONTEXT references in kernel-docKarl Mehltretter
The fw_cdev_event_iso_interrupt and fw_cdev_event_iso_interrupt_mc comments refer to FW_CDEV_CREATE_ISO_CONTEXT, but the ioctl is named FW_CDEV_IOC_CREATE_ISO_CONTEXT. Correct both references. The misspellings were introduced separately with the userspace interface documentation and multichannel reception support. Fixes: 7ada60e36764 ("firewire: Document userspace ioctl interface.") Fixes: 872e330e3880 ("firewire: add isochronous multichannel reception") Assisted-by: LLM Signed-off-by: Karl Mehltretter <kmehltretter@gmail.com> Link: https://lore.kernel.org/r/20260911222807.7673-1-kmehltretter@gmail.com Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
2026-09-11ACPI: glue: Fix up and adjust acpi_unbind_one()Rafael J. Wysocki
Since none of the acpi_unbind_one() callers check its return value and it always returns 0 anyway, make it void. Also notice that unlocking physical_node_lock for the given ACPI device should be carried out before dropping the reference to it in case that reference is the last one (highly unlikely), so rearrange the code to make that happen. Fixes: 3e3327837c18 ("ACPI: Use list_for_each_entry() in acpi_unbind_one()") Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Link: https://patch.msgid.link/10940500.nUPlyArG6x@rafael.j.wysocki
2026-09-11drm/atomic: colorop: Rename state to state_to_destroyMaxime Ripard
The atomic state tracking structures used to have a generic state field to track the state to free when tearing down the drm_atomic_commit. It has since been renamed to state_to_destroy in __drm_planes_state, __drm_crtcs_state, __drm_connnectors_state, and __drm_private_objs_state to better describe its purpose. The colorop support has been added after that rename, but __drm_colorops_state still uses the old state name. Rename it to state_to_destroy for consistency, and add the matching kerneldoc. Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Link: https://patch.msgid.link/20260908-drm-reset-state-flag-v3-1-905570f387a4@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-09-11block: add a bio_prepare_reissue helperChristoph Hellwig
Add a helper to a clear a bio for reissue without a lot of the pointless clearing and reinitializing done by bio_reset and bio_reuse, and keeping the page pinning flag intact. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: "Darrick J. Wong" <djwong@kernel.org> Link: https://patch.msgid.link/20260909060924.1102037-4-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
2026-09-11block: split bio_iov_iter_bounce_writeChristoph Hellwig
Factor out a bio_alloc_bounce_folios helper that we'll use for a different take on read-side bounce buffering soon. For that make it and also bio_free_folios available to callers outside of bio.c. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: "Darrick J. Wong" <djwong@kernel.org> Link: https://patch.msgid.link/20260909060924.1102037-2-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
2026-09-11block: avoid integer overflows in max_integrity_io_sizeChristoph Hellwig
Sashiko reports that the calculation in max_integrity_io_size could overflow a u32 when using 16kiB or larger LBA sizes. Fix this by evaluating the maximum size as a 64-bit integer. Fixes: ec7f31b2a2d3 ("block: make bio auto-integrity deadlock safe") Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Martin K. Petersen <mkp@kernel.org> Link: https://patch.msgid.link/20260907074111.721054-2-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
2026-09-11drm/crtc: Introduce hw_reset helper hookMaxime Ripard
The CRTC reset hook conflates initial software state allocation with hardware reset. The atomic_create_state hook addresses the software state side, but drivers may still need to reset hardware to a known good state during drm_mode_config_reset(), for example during suspend/resume. Separating hardware reset from state allocation is also useful for the pending atomic state readout and userspace atomic reset flag series, which need to create pristine software state without affecting the hardware. Introduce a hw_reset hook in struct drm_crtc_helper_funcs that only resets the hardware, without touching the software state at all. Call it from drm_mode_config_crtc_reset_with_create_state() after the state has been successfully created. Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Javier Martinez Canillas <javierm@redhat.com> Link: https://lore.kernel.org/r/20260904-drm-no-more-crtc-reset-v3-1-27d9891512ce@kernel.org Signed-off-by: Maxime Ripard <mripard@kernel.org>
2026-09-11userns: declare the KUnit-visible helpers whenever KUnit is enabledChristian Brauner
VISIBLE_IF_KUNIT drops the static qualifier whenever CONFIG_KUNIT is enabled but the prototypes for the two helpers it exposes are only declared when CONFIG_USER_NS_MAP_KUNIT_TEST is set. kernel/user_namespace.c:787:22: warning: no previous prototype for 'insert_extent' [-Wmissing-prototypes] kernel/user_namespace.c:860:22: warning: no previous prototype for 'sort_idmaps' [-Wmissing-prototypes] Guard the declarations on CONFIG_KUNIT so they match the definitions. Fixes: f6f1a2496ba5 ("userns: Add KUnit test suite for uid_gid_map") Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202609111048.yhHILE11-lkp@intel.com/ Closes: https://lore.kernel.org/oe-kbuild-all/202609111305.ta3EOA2x-lkp@intel.com/ Link: https://patch.msgid.link/20260911-zyklisch-stuhl-zweit-d61b18a17838@brauner Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
2026-09-11userns: rename insert_extent() and sort_idmaps()Christian Brauner
The KUnit test suite turned insert_extent() and sort_idmaps() into global symbols and declared them in include/linux/user_namespace.h. That header is pulled in nearly everywhere through linux/cgroup.h and the btrfs self-tests carry a static insert_extent() of their own, so any config with both test suites enabled fails to build: fs/btrfs/tests/inode-tests.c:16:13: error: conflicting types for 'insert_extent' include/linux/user_namespace.h:212:12: note: previous declaration of 'insert_extent' A global symbol needs a prefix. Rename them to uid_gid_map_insert_extent() and uid_gid_map_sort(). It's the better name anyway. No functional changes. Fixes: f6f1a2496ba5 ("userns: Add KUnit test suite for uid_gid_map") Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202609110843.okbPe7GM-lkp@intel.com/ Closes: https://lore.kernel.org/oe-kbuild-all/202609110937.zHKPPXJk-lkp@intel.com/ Link: https://patch.msgid.link/20260911-suggerieren-suchaktion-fliehen-87b9cdf1d169@brauner Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
2026-09-11firmware: arm_scmi: Merge scmi_reset_proto_ops.name_get() and .latency_get()Geert Uytterhoeven
The SCMI reset domain protocol operations structure does not provide a .info_get() method, unlike most other protocols. Instead, it provides two separate methods to get a domain's name and reset latency. Merge the .name_get() and .latency_get() methods into a single .info_get() method, to increase uniformity. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://patch.msgid.link/77c9651a11715013c0eaa8a56dbbc7dc3d9ddeec.1788429130.git.geert+renesas@glider.be Signed-off-by: Sudeep Holla <sudeep.holla@kernel.org>