6.12.117-rc1 review
Subsystems (5)
Greg Kroah-Hartman
maintainerPATCH 1/1536 net: skbuff: propagate shared-frag marker in skb_zerocopy()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Zizhen Liu <[email protected]>
commit 79dc34beb1fdb3da79753e51e15c68591a2561fe upstream.
skb_zerocopy() moves frag descriptors from @from into @to and takes a reference on each frag, but it does not copy skb_shinfo(from)->flags into skb_shinfo(to)->flags. A destination skb holding the same page-cache backed frags as the source therefore reports skb_has_shared_frag() as false.
That breaks the invariant relied on by later in-place writers. ESP input checks skb_has_shared_frag() before deciding whether an uncloned nonlinear skb can skip skb_cow_data(); with the marker lost, an skb that skb_zerocopy() built for nfnetlink_queue or for an openvswitch upcall is decrypted in place, letting an unprivileged user write into the page cache of a root-owned read-only file.
Propagate SKBFL_SHARED_FRAG when frag descriptors are copied, as done for the other frag-transfer helpers.
--- net/core/skbuff.c | 2 ++ 1 file changed, 2 insertions(+)
net/core/skbuff.c +2 -0
@@ -3871,6 +3871,8 @@ skb_zerocopy(struct sk_buff *to, struct }skb_shinfo (to)->nr_frags = j; +skb_shinfo (to)->flags |=skb_shinfo (from)->flags &SKBFL_SHARED_FRAG ; +return 0 ; }EXPORT_SYMBOL_GPL (skb_zerocopy);
Greg Kroah-Hartman
maintainerPATCH 2/1536 ksmbd: wait for negotiation before receiving another PDU
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Namjae Jeon <[email protected]>
[ Upstream commit 68f410faedaf6ee74d81e574733c50ebcc1bd8ed ]
The receive thread queues a request and can read the next PDU before the negotiation worker finishes. While need_neg is set, the next PDU can cause ksmbd_init_smb_server() to replace conn->ops. A pipelined SMB2 request can therefore make the worker handle an earlier, shorter SMB1 request with SMB2 operations and read beyond its buffer.
An SMB1 multi-protocol negotiate may be followed by an SMB2 NEGOTIATE that changes conn->ops again. Wait for work queued while the connection is new or needs negotiation to complete before reading another PDU. This keeps the operations stable for both stages of negotiation without changing when need_neg is cleared.
--- fs/smb/server/server.c | 5 +++++ 1 file changed, 5 insertions(+)
fs/smb/server/server.c +5 -0
@@ -291,6 +291,7 @@ static void handle_ksmbd_work(struct work_struct *wk)static int queue_ksmbd_work (struct ksmbd_conn *conn) {struct ksmbd_work *work; +bool wait_for_neg =ksmbd_conn_new (conn) ||ksmbd_conn_need_negotiate (conn);int err; err =ksmbd_init_smb_server (conn);
@@ -313,6 +314,10 @@ static int queue_ksmbd_work(struct ksmbd_conn *conn) conn->last_active = jiffies;INIT_WORK (&work->work, handle_ksmbd_work);ksmbd_queue_work (work); +/* Negotiation can change conn->ops, finish it before reading another PDU. */ +if (wait_for_neg) +wait_event (conn->req_running_q, +atomic_read (&conn->req_running) ==0 );return 0 ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainercover 6.12.117-rc1 review
This is the start of the stable review cycle for the 6.12.117 release. There are 1536 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know.
Responses should be made by Mon, 09 Nov 2026 13:46:08 +0000. Anything received after that time might be too late.
The whole patch series can be found in one patch at:
https://www.kernel.org/pub/linux/kernel/v6.x/stable-review/patch-6.12.117-rc1.gz
or in the git tree and branch at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-6.12.y
and the diffstat can be found below.
thanks,
greg k-h
-------------
Pseudo-Shortlog of commits:
Greg Kroah-Hartman <[email protected]>
Linux 6.12.117-rc1
John Johansen <[email protected]>
apparmor: on failed load ensure profile files are removed before parent
Joseph Qi <[email protected]>
ocfs2: read the xattr entry hash before defragmenting the bucket
Scott Gauche <[email protected]>
ALSA: hda/realtek: Fix audio after Windows reboot on ASUS Q423SA
Jason Perlow <[email protected]>
wifi: brcmfmac: map msgbuf RX packet IDs bidirectional
Avi Weiss <[email protected]>
init/bootconfig: pass init arguments in documented order
Amir Goldstein <[email protected]>
fs: don't fail __d_obtain_alias() for unlinked inodes
Hungyu Lin <[email protected]>
fs: skip copy_file_range write limits when there is no data
Daehyeon Ko <[email protected]>
splice: avoid stale f_pos writeback on error
Chris Mason <[email protected]>
aio: fix NULL deref when a fault races ring truncation
Georgia Garcia <[email protected]>
apparmor: remove fs entries created by a failed policy load
Kyle Zeng <[email protected]>
tcp: fix reordering addition overflow in MTU probing
Kyle Zeng <[email protected]>
net/packet: check TX_RING fragments before memory accounting
John Johansen <[email protected]>
apparmor: fix refcount leak in aa_get_newest_profile()
Zhiling Zou <[email protected]>
tcp: check congestion control restriction first
Kunhai Dai <[email protected]>
blk-iocost: abort weight transfer on invalid donation weights
Josef Bacik <[email protected]>
mount: refuse setns() with a shared fs_struct again
Avi Weiss <[email protected]>
irqchip/irq-msi-lib: Free wired MSI descriptors
Avi Weiss <[email protected]>
irqchip/riscv-imsic: Report successful hardware retrigger
Eric Biggers <[email protected]>
fsverity: Be more careful with return value of ->get_verity_descriptor()
Fang Xieyan <[email protected]>
kgdb: Fix buffer overflow in the qRcmd packet handler
Fang Xieyan <[email protected]>
kgdb: Fix buffer overflow in the 'M' and 'X' packet handlers
Fang Xieyan <[email protected]>
kgdb: Fix buffer overflow in the 'm' packet handler
Guixin Liu <[email protected]>
nvmet: Free the old negotiation state when restarting authentication
Guixin Liu <[email protected]>
nvmet: Finish the blk plug when integrity allocation fails
Martin Belanger <[email protected]>
nvme-tcp: start error recovery when read_sock fails
Guixin Liu <[email protected]>
nvmet-fc: Tear down the association when the admin queue allocation fails
Shao Mingyin <[email protected]>
nvmet-auth: fix error handling on CHALLENGE failure
Andrea Parri <[email protected]>
nvmet-fc: only send read data for successful commands
Weiming Shi <[email protected]>
nvmet-rdma: reject short connection requests
Tristan Madani <[email protected]>
ppp: fix stale pointer access after pskb_may_pull in ppp_ccp_peek
Peter Ujfalusi <[email protected]>
ASoC: hdac_hda: Keep runtime PM state in sync across codec remove/probe
Hongling Zeng <[email protected]>
ntfs3: fix mapping pairs bounds check for alignment
Hyeontae Lee <[email protected]>
fs/ntfs3: bound DeleteAttribute asize against rec->used in do_action
Hyeontae Lee <[email protected]>
fs/ntfs3: bound CreateAttribute asize against record_size in do_action
David Yang <[email protected]>
net: hisilicon: hisi_femac: Stop the receiver before releasing the RX ring
Xia Yan <[email protected]>
macvlan: fix passthru promiscuity accounting while down
Jesse Zhang <[email protected]>
drm/amdkfd: evict the queues only once for CRIU PROCESS_INFO
Jiale Yao <[email protected]>
drm/amdkfd: validate SRAT subtables before parsing
Avi Weiss <[email protected]>
drm/amd/display: Initialize missing TD-LUT programming inputs
Jesse Zhang <[email protected]>
drm/amdkfd: split vram_pages of SVM ranges prefetched without a GPU mapping
Luigi Lauro <[email protected]>
drm/amd/display: take a runtime PM reference only when a CRTC turns on
Olivier Kaloudoff <[email protected]>
drm/amdkfd: stop restore retries on device unplug
Zhao Gongyi <[email protected]>
arm64/mm: restrict transparent contpte mappings to valid PTEs
Zhongqiu Han <[email protected]>
cpufreq: stats: Fix potential out-of-bounds access in deferred reset
Tiezhu Yang <[email protected]>
LoongArch: Fix perf hardware breakpoint failure via installation
Tiezhu Yang <[email protected]>
LoongArch: Only send SIGTRAP signal if necessary in do_watch()
Tiezhu Yang <[email protected]>
LoongArch: Fix architectural naming typo for CSR_FWPS_SKIP
Tiezhu Yang <[email protected]>
LoongArch: Fix bitmask corruption in update_bp_registers()
Tiezhu Yang <[email protected]>
LoongArch: Remove redundant call in update_bp_registers()
Tiezhu Yang <[email protected]>
LoongArch: Remove arch-specific __smp_mb__{before,after}_atomic()
Huacai Chen <[email protected]>
LoongArch: Use pa_to_nid()/nid_to_addrbase() rather than hard-code
Peter Ujfalusi <[email protected]>
ASoC: hdac_hda: Balance the runtime PM disable in codec remove
Eric Dumazet <[email protected]>
ixgbe: reserve TX timestamp after skb preparation
Peter Ujfalusi <[email protected]>
ALSA: hda: Reject codec reset on ASoC (ext_ops) buses
Dominik Maier <[email protected]>
loop: check for read-write open mode on LOOP_SET_STATUS in lo_compat_ioctl()
Paul Moses <[email protected]>
xsk: restore UMEM flags after failed pool assignment
Yingjie Wang <[email protected]>
tcp: limit tcp_tso_rtt_log to a valid shift count
Miquel Raynal <[email protected]>
dt-bindings: clock: ma35d1: Document the missing crystal inputs
Ido Schimmel <[email protected]>
ipmr: fully initialize the synthetic IP header in ipmr_get_route()
Jiayuan Chen <[email protected]>
bonding: fix out-of-bounds read of arp_ip_target
Wei Jie Law <[email protected]>
net: usb: pegasus: check rx pkt_len against the received length
Srinivas Kandagatla <[email protected]>
ASoC: codecs: wsa884x: Accept temperatures across the full trim range
Val Packett <[email protected]>
ASoC: qcom: qdsp6: q6afe: fix clk vote response type mismatch
Alex Markuze <[email protected]>
ceph: fix uninitialized err in ceph_netfs_issue_read()
sung byeongchan <[email protected]>
ceph: validate encoded xattr name lengths
sung byeongchan <[email protected]>
ceph: validate MDS reply fragtree split array length
sung byeongchan <[email protected]>
ceph: bound name skips in ceph_mdsmap_decode() by the message end
sung byeongchan <[email protected]>
ceph: validate fscrypt auth blob length
Venky Shankar <[email protected]>
ceph: don't fail write_begin with -EAGAIN after flushing old snapc
Yuanfu Xie <[email protected]>
ceph: clamp MDS reply result code to the errno range
Jérémy Jean <[email protected]>
libceph: fix out-of-bounds reads from repeated CRUSH bucket entries
Jérémy Jean <[email protected]>
ceph: fix 32-bit overflow in readdir reply count check
Wentao Liang <[email protected]>
ceph: Fix mds session leak in __open_export_target_session()
Wentao Liang <[email protected]>
ceph: Fix xattr buffer leak in __send_cap()
Xiang Mei <[email protected]>
ceph: fix integer overflow in the snap trace bounds check
Yogesh Gaur <[email protected]>
libceph: reject an initial monmap with no monitors
Felix Hoffmann <[email protected]>
libceph: reject mismatched CRUSH weight-set sizes
Raphael Zimmer <[email protected]>
libceph: Fix multiple unsafe decodes in ceph_oloc_decode()
Raphael Zimmer <[email protected]>
libceph: Fix unsafe decode in ceph_redirect_decode()
Xiubo Li <[email protected]>
libceph: only set read_from_replica on read requests
Xiang Mei <[email protected]>
ceph: require the dentry lease record to cover struct ceph_mds_reply_lease
Xiang Mei <[email protected]>
ceph: reject mdsmaps that claim more than CEPH_MAX_MDS ranks
Guanglei Zhu <[email protected]>
ceph: fix out-of-bounds read in ceph_netfs_issue_op_inline()
Max Kellermann <[email protected]>
ceph: avoid pending truncate during nonblocking cap acquire
Hungyu Lin <[email protected]>
time/namespace: Fix overflow when converting absolute deadlines
Hungyu Lin <[email protected]>
timers/itimer: Keep a nonzero value at CPU timer expiry
Wang Haoran <[email protected]>
fbdev: atmel_lcdfb: fix list_first_entry() on possibly empty modelist in probe
Baokun Li <[email protected]>
fscrypt: Fix missing barrier in fscrypt_find_mode_key()
Siddharth Chintamaneni <[email protected]>
mm: multi-gen LRU: fix NULL lruvec->pgdat deref with memcg disabled on cmdline
Yunhui Cui <[email protected]>
riscv: mm: exclude invalid THP PMDs from page table check
Gregory Price (Meta) <[email protected]>
mm/mempolicy: apply bind policies against the scoped allocation zone
Rik van Riel <[email protected]>
mm/page_alloc: count guard pages as free again when their buddy merges
Weilin Tong <[email protected]>
ipc/shm: fix RSS accounting for hugetlb shared memory
Pedro Falcato <[email protected]>
mm/madvise: atomically clear the young bit on THP MADV_COLD
Harry Yoo (Meta) <[email protected]>
mm/percpu: account full object size for percpu memory allocations
Nickolai Zeldovich <[email protected]>
mm/mlock: use a long for the page count in mlock_fixup()
Wei Yang <[email protected]>
mm/madvise: add cond_resched() in THP branch of madvise_cold_or_pageout_pte_range()
Cen Zhang <[email protected]>
ocfs2/cluster: remove zero-address nodes from IP tree on teardown
Cen Zhang <[email protected]>
ocfs2: snapshot the dentry name while tracing file release
Hungyu Lin <[email protected]>
compat: avoid double rounding in times()
Stanley Jhu <[email protected]>
scsi: ufs: core: Remove completed-without-interrupt path in ufshcd_abort()
Stanley Jhu <[email protected]>
scsi: ufs: core: Remove an always-false WARN_ONCE()
Ratnaker Gautam <[email protected]>
scsi: libiscsi_tcp: Prevent R2T range check overflow
Stanley Jhu <[email protected]>
scsi: ufs: core: Clear stale UIC result byte before peer DME retries
Stanley Jhu <[email protected]>
scsi: ufs: bsg: Clear the reply buffer before use
Stanley Jhu <[email protected]>
scsi: ufs: bsg: Complete the job on error
yanxia <[email protected]>
veth: fix stale peer max_mtu on XDP program replacement
Aamir Ahmed <[email protected]>
gve: fix out-of-bounds read in gve_get_flow_rule_entry()
Sasha Levin <[email protected]>
cgroup: don't kill migrated processes through their exiting threads
Thomas Weißschuh (Schneider Electric) <[email protected]>
timekeeping: Update offsets on sequence counter retry in ktime_get_update_offsets_now()
Cen Zhang (Microsoft) <[email protected]>
posix-cpu-timers: Fix pid refcount leak in do_cpu_nanosleep() signal path
Pufan Jin <[email protected]>
spi: zynq-qspi: fix address buffer corruption and support 4-byte address
Christian Marangi <[email protected]>
i2c: mt7621: fix copying uninitialized kernel stack with reduced page_len
Alex Kazinsky <[email protected]>
ASoC: tlv320aic32x4: Prevent division by zero in divider callbacks
Jean Delu <[email protected]>
parisc: eisa_enumerator: Fix out-of-bounds reads of the EEPROM buffer
Adrian Ambrozewicz <[email protected]>
gpiolib: don't report -ENOMEM for a requested line without a label
Pei Xiao <[email protected]>
tpm: fix zero-length read discarding the pending response
Pei Xiao <[email protected]>
tpm: tpm_nsc: stop using the cleanup callback as dev.release
Pei Xiao <[email protected]>
tpm: tpm_nsc: fix NULL pointer dereference on init failure
Navon John Lukose <[email protected]>
i2c: designware: queue only one read command for block reads
Ma Ke <[email protected]>
i2c: acpi: Fix adapter reference leak in i2c_acpi_new_device_by_fwnode()
Tristan Madani <[email protected]>
cpufreq: intel_pstate: cancel HWP notify work in driver cleanup
Nickolai Zeldovich <[email protected]>
ucount: take the rlimit reference before checking the limit
Christian Brauner <[email protected]>
listmount: don't wrap around with a U64_MAX cursor
Christian Brauner <[email protected]>
statmount: don't copy the reserved empty string past the buffer
Chuck Lever <[email protected]>
exportfs: Release the get_name() directory file synchronously
Henry Martin <[email protected]>
tipc: fix broadcast sender hang on last acker departure
Liu Chao <[email protected]>
net: wwan: iosm: validate msg_head before indexing msg_ring
Yu Zhang <[email protected]>
nvmet: take subsys->lock while force-reconnecting in nvmet_subsys_attr_qid_max_store()
Runyu Xiao <[email protected]>
sh: maple: Use the matching IRQ cookie when invoking free_irq()
Henrik Enquist <[email protected]>
ALSA: aloop: Update the PCM Slave controls for a matching playback
Julian Sun <[email protected]>
writeback: clear old wb dirty state after inode switches
Julian Sun <[email protected]>
writeback: reset dirtied_when when switching wbs
Bartu Alev <[email protected]>
platform/x86: asus-wmi: fix TUF keyboard power state shutdown naming
Michael Kelley <[email protected]>
Documentation: hyperv: Update documentation for sending VMBus packets
Cen Zhang <[email protected]>
ocfs2/cluster: initialize heartbeat regions before publishing them
Joseph Qi <[email protected]>
ocfs2: deal with legacy signed xattr name hash values
Joseph Qi <[email protected]>
ocfs2: use the stored hash when checking xattr bucket collision
Joseph Qi <[email protected]>
ocfs2: deal with legacy signed dir index name hash values
Joseph Qi <[email protected]>
ocfs2: reserve value tree metadata when moving an xattr into the inode
Joseph Qi <[email protected]>
ocfs2: reserve metadata for a new xattr block and its value tree
Matt Turner <[email protected]>
alpha: determine tininess after rounding in the FP emulation
Bryam Vargas <[email protected]>
net/smc: queue the copied chunk when smc_tx_sendmsg() faults
Yingjie Wang <[email protected]>
net: unix: reject negative max_dgram_qlen values
Nguyen Ngoc Thang <[email protected]>
net/rds: ib: don't enable IRQs in rds_ib_conn_free()
Guangshuo Li <[email protected]>
PCI: qcom-ep: Deinitialize endpoint on remove
Tingjie Zhong <[email protected]>
fbdev: bitblit: Fix glyph clipping when fbcon pans
Daehyeon Ko <[email protected]>
ipv6: do not restart DAD for a dead ifaddr
Daehyeon Ko <[email protected]>
ipv6: initialize temporary ifaddr before publication
Daehyeon Ko <[email protected]>
ipv6: serialize address publication with device teardown
Daehyeon Ko <[email protected]>
ipv6: remove ifaddr from hash during ifdown list cleanup
William Palacek <[email protected]>
drm/amdkfd: wait for a GPU reset before freeing a BO
Keita Morisaki <[email protected]>
drm/amd/display: Fix swap in median3() for DSC rate control
Jesse Zhang <[email protected]>
drm/amdkfd: don't drop an SVM CWSR reference that was never taken
Jesse Zhang <[email protected]>
drm/amdgpu: reject ANONONLY userptrs that span multiple VMAs
Mario Limonciello <[email protected]>
drm/amd/display: don't WARN when removing an unallocated MST payload
Henry Martin <[email protected]>
drm/amdkfd: fix doorbell allocation race creating duplicate allocations
Maciej Kucharek <[email protected]>
drm/amdgpu: reset VI ASIC on Apple boards with VRAM at 0
Maciej Kucharek <[email protected]>
drm/amdgpu: reset CIK ASIC on Apple boards with VRAM at 0
Luigi Lauro <[email protected]>
drm/amdgpu: require _PR3 for BOCO
Nirmoy Das <[email protected]>
blk-mq: clear stale inactive flag on hctx reuse
Sahaj Chaudhari <[email protected]>
gpio: pca953x: Handle direction register read errors in IRQ paths
Sahaj Chaudhari <[email protected]>
gpio: davinci: Clear interrupt status in every bank on suspend
Baek Kyu, Kim <[email protected]>
gpiolib: Free chip resources when allocating the label fails
Takashi Iwai <[email protected]>
ALSA: emux: Stop voices before freeing zones in all cases
Peter Ujfalusi <[email protected]>
ALSA: compress: add missing OPEN-state gate to SET_METADATA
Peter Ujfalusi <[email protected]>
ALSA: compress: reject buffer geometry change on gapless next_track
Peter Ujfalusi <[email protected]>
ALSA: compress: fix buffer leak on failed SET_PARAMS
Sorah Fukumori <[email protected]>
net: gro: don't chain linear parts larger than gso_size into frag_list
Jamal Hadi Salim <[email protected]>
netdevsim: reject cls_bpf programs bound to another device
Kir Kolyshkin <[email protected]>
cgroup: fix cgroup.kill for exited thread group leader
Alexander Kochetkov <[email protected]>
Revert "Input: matrix_keypad - force switch rows to input mode"
Baek Kyu, Kim <[email protected]>
hwmon: (sht3x) Return the consumed count for heater writes
Ma Ke <[email protected]>
platform/x86/amd/pmc: Fix RTC reference leak in amd_pmc_verify_czn_rtc()
Gregory Price <[email protected]>
rtc: cmos: Disable ACPI RTC event before handling it
Seongjae Jeong <[email protected]>
f2fs: fix submit accounting for IPU writeback
Wenjie Qi <[email protected]>
f2fs: flush SIT journal during filesystem resize
Jiale Yao <[email protected]>
hwmon: (gigabyte_waterforce) reject short input reports
Ximing Zhang <[email protected]>
hwmon: (coretemp) Fix handling of isolated SMT siblings
Kyle Zeng <[email protected]>
netfilter: nf_reject: initialize IPCB at inet ingress
Nickolai Zeldovich <[email protected]>
lib/buildid: reject file offsets that do not fit in pgoff_t
Sanan Hasanov <[email protected]>
hwmon: (corsair-cpro) Make wait_input_report_lock IRQ safe
Weibin Liu <[email protected]>
spi: ch341: handle transfers without a TX or RX buffer
Vasiliy Kovalev <[email protected]>
ALSA: hda/via: Apply runtime PM workaround for ASUS X55A
Magnus Lindholm <[email protected]>
alpha: do not skip TLB shootdown IPIs for kthread-borrowed mms
Magnus Lindholm <[email protected]>
alpha: do not clear remote MMU contexts in migrate_flush_tlb_page()
Magnus Lindholm <[email protected]>
alpha: invalidate the local context in flush_icache_user_page()
Magnus Lindholm <[email protected]>
alpha: invalidate the local context in flush_tlb_mm()
Magnus Lindholm <[email protected]>
alpha: fix the local TLB invalidate in the UP flush_tlb_page()
Magnus Lindholm <[email protected]>
alpha: fix the local TLB invalidate in flush_tlb_page()
Magnus Lindholm <[email protected]>
alpha: invalidate the local context in flush_tlb_page()
Magnus Lindholm <[email protected]>
alpha: only use a targeted tbi() when the target mm is really current
Magnus Lindholm <[email protected]>
alpha: run check_mmu_context() from finish_arch_post_lock_switch()
Magnus Lindholm <[email protected]>
alpha: load the MMU context when switch_mm() switches the current task
Matt Turner <[email protected]>
alpha: handle VM_FAULT_HWPOISON in do_page_fault()
Tim Douglas <[email protected]>
power: supply: generic-adc-battery: fix status with no supplier
Luis Gerardo Lopez Hernandez <[email protected]>
ALSA: hda/realtek: Fix internal speakers on Acer Aspire AL16-31P
Takashi Iwai <[email protected]>
ALSA: seq: oss: Skip events until fully initialized
Quanye Yang <[email protected]>
mptcp: reset msk state on early connect failure
Kees Cook <[email protected]>
ipc, msg: Account msg_msg allocations with GFP_KERNEL_ACCOUNT again
Fan Wu <[email protected]>
virtio_fs: read the vring size under virtio_fs_mutex in ->get_tree
Huacai Chen <[email protected]>
cpufreq: loongson3: Replace IOCSR read/write with MMIO ones
Huacai Chen <[email protected]>
cpufreq: loongson3: Use global physical CPU ID in get/target callbacks
Huacai Chen <[email protected]>
cpufreq: loongson3: Replace per-package mutex with per-node
Huacai Chen <[email protected]>
cpufreq: loongson3: Adjust the width of id and val in smc_message
Huacai Chen <[email protected]>
cpufreq: loongson3: Make this driver depend on MACH_LOONGSON64
Shubham Antil <[email protected]>
RDS/IB: validate receive fragment completions
Seung Min Shin <[email protected]>
sctp: hold transport reference across connect wait
Zixuan Chai <[email protected]>
ipv6: defrag: orphan skb before queuing
Josef Bacik <[email protected]>
net: skbuff: don't BUG() on a bad csum_start in skb_copy_and_csum_dev()
Jianyun Gao <[email protected]>
dax: fix dax_range_compare_iter() to use correct size and address offset
Jianyun Gao <[email protected]>
dax: Return errors from dax_core_init()
David Carlier <[email protected]>
ring-buffer: Take cpus_read_lock() when changing the subbuf order
Gyokhan Kochmarla <[email protected]>
erofs: use on-disk blkszbits for lz4 max pcluster bound
Weibin Liu <[email protected]>
spi: amd: fix len==0 underflow and FIFO overflow
Weibin Liu <[email protected]>
spi: bcm-qspi: reject oversized dummy bytes in mspi exec_mem_op
Vladyslav Tymoshchuk <[email protected]>
ASoC: qcom: q6apm: reset the hw pointer with the fragment queue
Radiy Zhambakiev <[email protected]>
mfd: tps65217: Use devres for IRQ domain and wake teardown
Radiy Zhambakiev <[email protected]>
mfd: tps65217: Check return value when masking interrupt sources
Radiy Zhambakiev <[email protected]>
mfd: tps65217: Fix NULL pointer dereference on IRQ init failure
Weibin Liu <[email protected]>
spi: npcm-fiu: limit UMA data_size to the 16-byte staging buffer
Marc Zyngier <[email protected]>
KVM: arm64: Turn vcpu->arch.pause into a counter
Marc Zyngier <[email protected]>
KVM: arm64: Move OUTSIDE_GUEST_MODE publication past context being saved
Ard Biesheuvel <[email protected]>
efi/libstub: Don't replace an existing LINUX_EFI_MEMRESERVE table
Weibin Liu <[email protected]>
spi: jcore: fix divide-by-zero when speed_hz is zero
Tal Zussman <[email protected]>
gfs2: fix the escaped block copy in gfs2_before_commit()
Takashi Iwai <[email protected]>
ALSA: ump: Correct return size of fill_rpn()
Wentao Liang <[email protected]>
irqchip/mchp-eic: Fix clock reference leak in mchp_eic_probe()
Guangshuo Li <[email protected]>
irqchip/imx-intmux: Fix runtime PM teardown on remove
Fuad Tabba <[email protected]>
irqchip/gic-v3-its: Don't clamp nvecs to zero when id_bits is 32
Ahsan Atta <[email protected]>
crypto: qat - fix use of destroyed vf2pf_lock on VF restart
Ahsan Atta <[email protected]>
crypto: qat - initialise state_lock on every path in adf_devmgr_add_dev()
Andrea Parri <[email protected]>
iommufd: Reject a zero-length dirty bitmap request
Wentao Liang <[email protected]>
PCI: xilinx-xdma: Fix device node reference leak in xilinx_pl_dma_pcie_init_irq_domain()
Hui Su <[email protected]>
cpufreq: schedutil: Serialize sugov_start() against rate limit updates
Siwei Zhang <[email protected]>
Bluetooth: L2CAP: Use default TxWindow for zero socket option
Siwei Zhang <[email protected]>
Bluetooth: L2CAP: Reject invalid TxWindow in configuration requests
Siwei Zhang <[email protected]>
Bluetooth: L2CAP: Reject mode changes on connected channels
Bui Viet Dung <[email protected]>
Bluetooth: hci_debugfs: Pin module for debugfs file operations
Bui Viet Dung <[email protected]>
Bluetooth: 6lowpan: Pin module for 6lowpan_control debugfs file
Nikolaj Klitlund Børty <[email protected]>
Bluetooth: btusb: Add device ID for Realtek RTL8761BUE (StarTech AV53C1)
Stian Halseth <[email protected]>
PCI: Set supported_speeds in set_pcie_port_type()
Karl Mehltretter <[email protected]>
ARM: 9491/1: alignment: restore uaccess state on emulation fault
Karl Mehltretter <[email protected]>
ARM: 9488/1: smp: set current pointer in assembly before jumping into C
Weibin Liu <[email protected]>
spi: cadence-xspi: fix stack buffer overflow in the Marvell b0 path
Martin Belanger <[email protected]>
nvme: make the DH-HMAC-CHAP secret attributes readable by root only
Tim Douglas <[email protected]>
serial: pmac_zilog: push received data to the port that received it
Jiri Slaby (SUSE) <[email protected]>
serial: 8250_lpss: do not touch uninitialized line in ehl_serial_exit()
Muhammad Bilal <[email protected]>
platform/x86: hp-bioscfg: NUL-terminate the SPM auth token
Muhammad Bilal <[email protected]>
platform/x86: hp-bioscfg: allow clearing current_password
Muhammad Bilal <[email protected]>
platform/x86: hp-bioscfg: return -E2BIG from validate_password_input()
Muhammad Bilal <[email protected]>
platform/x86: hp-bioscfg: fix non-ASCII truncation in hp_get_string_from_buffer()
Muhammad Bilal <[email protected]>
platform/x86: hp-bioscfg: fix OOB reads in hp_get_string_from_buffer()
Denis Arefev <[email protected]>
ALSA: cs46xx: fix unit mismatch in DSP code area bounds check
Aamir Ahmed <[email protected]>
lib: decompress_bunzip2: fix integer overflow in run-length decoding
Matt Turner <[email protected]>
lib/decompress_bunzip2: fix off-by-one in run-length bounds check
Ma Ke <[email protected]>
pinctrl: stm32: Fix fwnode reference leak in stm32_gpiolib_register_bank()
Weibin Liu <[email protected]>
spi: ljca: validate the response length before copying the data
Daeho Jeong <[email protected]>
f2fs: disallow mmap write and data-modifying fallocate on atomic files
Zhan Xusheng <[email protected]>
f2fs: fix defragment writeback range truncation on 32-bit
Kaixuan Li <[email protected]>
f2fs: check every cur_*_segno[] entry on readonly images
Nanzhe Zhao <[email protected]>
f2fs: read i_size once in f2fs_vm_page_mkwrite
Joanne Chang <[email protected]>
f2fs: allow pinning empty compressed files
Nanzhe Zhao <[email protected]>
f2fs: remove mappedtodisk flag usage in mmap write path
Karl Mehltretter <[email protected]>
sh: intc: Sort the prio and sense lists after filling them
Geraldo Nascimento <[email protected]>
PCI: rockchip-host: Do not attempt 5.0 GT/s retraining
Daeho Jeong <[email protected]>
f2fs: convert inline quota files when turning quota on
Andrea Parri <[email protected]>
nvmet: zns: don't leak stale memory in zone management receive
Jérémy Jean <[email protected]>
nvmet: free the bvec on file namespace range errors
Yehyeong Lee <[email protected]>
nvme-auth: fail when the controller does not authenticate itself
Yehyeong Lee <[email protected]>
nvme-rdma: don't complete a request after a bogus remote invalidation
Andrea Parri <[email protected]>
iomap: don't lose a fiemap iteration error when emitting the last extent
Kathiravan Thirumoorthy <[email protected]>
clk: qcom: ipq5332: add 24MHz rate for USB UTMI clock
Kathiravan Thirumoorthy <[email protected]>
clk: qcom: ipq5018: add 24MHz rate for USB UTMI clock
Samuel Thibault <[email protected]>
speakup: Fix NULL pointer dereference on VT switch + selection
Wentao Guan <[email protected]>
mei: vsc: Fix packet CRC computed over pointer size
Mikulas Patocka <[email protected]>
dm-bufio: fix a race leading to an unsigned integer underflow
Jiri Slaby (SUSE) <[email protected]>
serial: 8250_exar: store the GPIO platform device in struct exar8250
Lorenzo Stoakes (ARM) <[email protected]>
fbdev: sh_mobile_lcdc: check for fb_deferred_io_init() error
Lorenzo Stoakes (ARM) <[email protected]>
fbdev: smscufx: check for fb_deferred_io_init() error
Lorenzo Stoakes (ARM) <[email protected]>
fbdev: udlfb: check for fb_deferred_io_init() error
Lorenzo Stoakes (ARM) <[email protected]>
fbdev: xen-fbfront: check for fb_deferred_io_init() error
Lorenzo Stoakes (ARM) <[email protected]>
fbdev: ssd1307fb: check for fb_deferred_io_init() error
Guixiong Wei <[email protected]>
platform/x86/intel-uncore-freq: Continue restoring limits on resume
Guangshuo Li <[email protected]>
platform/x86: simatic-ipc: fix platform device leak on registration failure
Jack Boykin <[email protected]>
platform/x86/amd/pmf: Fix power_supply refcount leak in amd_pmf_get_battery_prop()
Muhammad Bilal <[email protected]>
platform/x86: hp-wmi: fix heap OOB read and memory corruption in hp_wmi_perform_query()
Muhammad Bilal <[email protected]>
platform/x86: hp-bioscfg: fix 16-byte heap overflow for empty auth token
Denis Benato <[email protected]>
platform/x86: asus-wmi: fix screenpad power state detection
Denis Benato <[email protected]>
platform/x86: asus-wmi: fix unclear usage of bd->props.power
Mario Limonciello <[email protected]>
platform/x86/amd/pmf: Validate the APTS state index
Donggeun Yoo <[email protected]>
mm/damon/tests/core-kunit: test the size charged for a filter-trimmed region
Donggeun Yoo <[email protected]>
mm/damon/core: charge only the part of a region the filter left
Breno Leitao <[email protected]>
mm/shmem: report RCU-tasks quiescent states while undoing a range
Hongfu Li <[email protected]>
mm/hugetlb_cgroup: move per-node usage on cgroup reparenting
Hongfu Li <[email protected]>
mm/hugetlb_cgroup: move per-node usage on cross node migration
Yuanhe Shu <[email protected]>
mm/page_alloc: do not boost watermarks in kdump capture kernels
Gregory Price <[email protected]>
mm/madvise: use folio_trylock() in the cold/pageout PMD split
Gregory Price <[email protected]>
mm/madvise: reclaim isolated folios if PTE restart fails
SJ Park <[email protected]>
mm/damon/sysfs-schemes: read sysfs_filter->addr_range only once
Imre Kaloz <[email protected]>
PCI: Avoid D3 on PLX PEX 8532/8533/8548 downstream ports
Yongjian Mu <[email protected]>
xprtrdma: trim head iovec when the payload arrives via a Write chunk
Tim Menninger <[email protected]>
xprtrdma: prevent disconnect feedback during endpoint teardown
Weigang He <[email protected]>
mtd: parsers: qcom: fix offset/size overflow on large partitions
Hengyu Liang <[email protected]>
btrfs: return -ENOTTY for unknown ioctls on the control device
Wentao Liang <[email protected]>
btrfs: zoned: fix block group reference leak in btrfs_repair_one_zone()
Ard Biesheuvel <[email protected]>
arm64/efi: Clear PTE_WRITE when applying EFI_MEMORY_RO
Mikulas Patocka <[email protected]>
dm-snapshot: fix crash if dm_io_client_create fails
Johan Hovold <[email protected]>
USB: serial: sierra: fix urb leak on write completion
Anup Vishwakarma <[email protected]>
mailbox: qcom-ipcc: Guard against NULL con_priv in send_data()
Wentao Liang <[email protected]>
mailbox: mtk-cmdq: Fix runtime PM leak in cmdq_mbox_flush()
Wayne Chang <[email protected]>
usb: typec: ucsi_ccg: Add retry mechanism in ccg_read
Drobyshev Vladimir <[email protected]>
USB: cdc-acm: add VeriFone VX820 device ID
Koichiro Den <[email protected]>
cxl/acpi: Convert QTG _DSM latencies to picoseconds
Koichiro Den <[email protected]>
cxl: Account for link width in latency calculation
Koichiro Den <[email protected]>
cxl/port: Convert PCIe link latency to nanoseconds
Seongjun Hong <[email protected]>
vfio/mlx5: Fix boundary check in set_report_output()
Xiaofeng Yuan <[email protected]>
RISC-V: KVM: Fix IPI delivery for out-of-order vcpu_id
Ross Lagerwall <[email protected]>
xen-blkfront: Fix IO race during unplug
Zongmin Zhou <[email protected]>
slimbus: messaging: fix leaked PM vote on tid allocation failure
Johan Hovold <[email protected]>
USB: serial: usb_wwan: fix urb leak on disconnect
Michael Wyraz <[email protected]>
USB: serial: option: add support for ASR 1286:4e3c modem
Reinhard Speyerer <[email protected]>
USB: serial: option: add Rolling Wireless RN947R
Johan Hovold <[email protected]>
USB: cdc-acm: fix urb leak on disconnect
Jesse Zhang <[email protected]>
drm/ttm: return an error when kmapping a BO without pages
Krzysztof Karas <[email protected]>
iommu/dma: Catch scatterlist length overflows
Wentao Liang <[email protected]>
xen-pciback: Fix pcistub_device ref leak in pcistub_get_gsi_from_sbdf()
Yehyeong Lee <[email protected]>
xen/pcifront: check that an AER callback exists before calling it
Koichiro Den <[email protected]>
xen/privcmd: Only claim ioreqs matching an ioeventfd
Myeonghun Pak <[email protected]>
soc: fsl: dpio: Free the IRQ before releasing the I/O object
Myeonghun Pak <[email protected]>
soc: fsl: dpio: Fix cleanup on IRQ registration failure
Wentao Liang <[email protected]>
soc: fsl: cpm1: tsa: Fix clock leak in tsa_of_parse_tdms()
Abdifatah Suruur <[email protected]>
xen/gntdev: prevent private mappings from becoming writable
Wentao Liang <[email protected]>
clk: imx: Fix clock reference leak in imx_obtain_fixed_clock_hw()
Wentao Liang <[email protected]>
clk: imx: Fix clock reference leak in imx_get_clk_hw_by_name()
Longlong Xia <[email protected]>
mm/zswap: enable zswap_ever_enabled in zswap_pool_create()
Anastasios Papagiannis <[email protected]>
mm/nommu: reject wrapping ranges in access_remote_vm()
Yogesh Gaur <[email protected]>
md: don't hand out the array before md_alloc() has added mddev->kobj
Jake Labelle <[email protected]>
nilfs2: validate directory position after llseek in readdir
Jinjie Ruan <[email protected]>
ext4: fix out-of-bounds read in ext4_get_group_info()
Sergey Senozhatsky <[email protected]>
ext4: fix ABBA deadlock in ext4_rmdir()
Daejun Park <[email protected]>
ext4: don't report delalloc data as a hole on indirect-mapped inodes
Hemanth Selam <[email protected]>
ext4: skip extra isize expansion while unmounting
Daejun Park <[email protected]>
jbd2: don't advance j_fc_off before the buffer is recorded
Hsiu-Hsien Lee <[email protected]>
ext4: fix fast commit replay failing on a read-only mount
Matthias Goergens <[email protected]>
fanotify: report names longer than NAME_MAX
Daehyeon Ko <[email protected]>
crypto: algif_skcipher - rewind rounded output bytes
Tristan Madani <[email protected]>
wifi: rtw89: fix IE length passed to cfg80211_find_ie() in WoW AKM
Krzysztof Wilczyński <[email protected]>
PCI/sysfs: Pass the device name length in UTF-16 code units
Josef Bacik <[email protected]>
aoe: pull in the headers each received packet type reads
Wentao Liang <[email protected]>
clocksource/drivers/digicolor: Fix clk reference leak on request_irq failure
Wentao Liang <[email protected]>
clocksource/drivers/fttmr010: Fix clk reference leak in error paths
Wentao Liang <[email protected]>
wifi: mt76: Fix of_node reference leak in mt76_get_rate_power_limits()
Jiale Yao <[email protected]>
wifi: mt76: mt7615: cancel reset work during unregister
Myeonghun Pak <[email protected]>
wifi: mt76: mt7615: restore DBDC state after ext PHY failure
Eason Lai <[email protected]>
wifi: mt76: fix memory leak in USB TX path
Eason Lai <[email protected]>
wifi: mt76: mt792x: fix UAF in SDIO TX path when out of memory
Mark Anthony Agarro <[email protected]>
wifi: mt76: mt7615: do not tear down BSS/STA state for monitor vifs
Mark Anthony Agarro <[email protected]>
wifi: mt76: mt76x02: validate TX-status rate index before mac80211 handoff
Joseph Qi <[email protected]>
ocfs2: skip uninitialized lockres in ocfs2_mark_lockres_freeing()
Konstantin Khorenko <[email protected]>
selftests/core: fix unshare_test with large fs.nr_open
Joseph Qi <[email protected]>
ocfs2: free replay slots in ocfs2_recovery_exit()
Joseph Qi <[email protected]>
ocfs2: exit recovery thread on mount error path
Thorsten Blum <[email protected]>
init: fix early boot crash with bare hostname parameter
Zi Yan <[email protected]>
USB: gadgetfs: do not WARN about excessively large memory allocations
Michael Liang <[email protected]>
fault-inject: fix dentry leak
OGAWA Hirofumi <[email protected]>
fat: fix fat_ent_write() for reverting the value
DAI RENJIE <[email protected]>
resource: fix lost wakeup when waiting for a muxed region
Gregory Price <[email protected]>
mm/mempolicy: take a cpuset cookie for the interleave node count
Nathan Chancellor <[email protected]>
wifi: brcmsmac: Adjust txpwrindex value in nphy_ipa_rxcal_gaintbl_2GHz
Darrick J. Wong <[email protected]>
xfs: cross-reference the primary superblock
Priyank Rathod <[email protected]>
PCI/AER: Fix memory leak in aer_recover_queue() on kfifo buffer overflow
Eric Dumazet <[email protected]>
dlm: fix send buffer backpressure handling
Denis Efremov (Oracle) <[email protected]>
floppy: return the drive state flags from the 32-bit FDGETDRVSTAT
Denis Efremov (Oracle) <[email protected]>
floppy: don't store a stack buffer in timeout_message
Myeonghun Pak <[email protected]>
ASoC: codecs: rt5682s: disable jack detection work on shutdown
Chuck Lever <[email protected]>
svcrdma: Grant credits from the clamped sc_max_requests
Runyu Xiao <[email protected]>
perf: xgene: initialize lock before requesting IRQ
Linus Walleij <[email protected]>
power: supply: ab8500_fg: Report sub-percent charge changes
Linus Walleij <[email protected]>
power: supply: ab8500_fg: Accept status from supplied power
Andrey Albershteyn <[email protected]>
fsverity: hoist statx reporting of fs-verity flag
Tharit Tangkijwanichakul <[email protected]>
media: hantro: disable runtime PM before hardware teardown
Jiawen Liu <[email protected]>
media: amphion: fix runtime PM imbalance on probe failure
Tharit Tangkijwanichakul <[email protected]>
media: hantro: Harden MPEG-2 control access against NULL
Junrui Luo <[email protected]>
media: vicodec: fix NULL deref on oversized frame
Pengpeng Hou <[email protected]>
media: mediatek: jpeg: retry HW selection after successful wait
Michail Tatas <[email protected]>
media: verisilicon: rockchip: Fix leaks in init
Guangshuo Li <[email protected]>
media: mediatek: vpu: release reserved memory on remove
Guangshuo Li <[email protected]>
media: mediatek: vcodec: destroy core workqueue on remove
Wentao Liang <[email protected]>
media: mtk-jpeg: Fix runtime PM leak in mtk_jpegenc_worker()
Wentao Liang <[email protected]>
media: mtk-jpeg: Fix runtime PM leak in mtk_jpegdec_worker()
Wentao Liang <[email protected]>
media: platform: mtk-mdp3: Fix device reference leak in mdp_comp_init()
Fan Wu <[email protected]>
media: mediatek: vpu: free IRQ before destroying watchdog workqueue
Myeonghun Pak <[email protected]>
media: amphion: prevent unbind while video instances are open
Myeonghun Pak <[email protected]>
media: amphion: drain message work before releasing core state
Michael Freidkin <[email protected]>
media: meson: vdec: size capture planes from the aligned canvas
Runyu Xiao <[email protected]>
media: sti: delta: use unaligned accessors for MJPEG SOF fields
Nas Chung <[email protected]>
media: v4l2-common: Fix P010 format info
Thorsten Blum <[email protected]>
media: imagination: Fix value clamping in calculate_qp_tables
Karl Mehltretter <[email protected]>
KVM: arm64: vgic-v3: Roll back assignments from the new region
Karl Mehltretter <[email protected]>
KVM: arm64: vgic-v3: Undo assignment on iodev registration failure
Aldo Ariel Panzardo <[email protected]>
crypto: nx - validate 'ignore' before subtracting in decompress
Thorsten Blum <[email protected]>
hwrng: core - reject unknown RNG names
Thorsten Blum <[email protected]>
hwrng: ba431 - fix reported byte count
Thorsten Blum <[email protected]>
hwrng: amd - report partial reads in non-blocking mode
ZhaoJinming <[email protected]>
crypto: caam - fix double-free in caam_rsa_set_priv_key_form()
Wei Jie Law <[email protected]>
media: uvcvideo: Fix NULL deref on events for uninitialized controls
Imre Kaloz <[email protected]>
PCI: Disable MSI for ULi M1575 EHCI controller
Vasileios Almpanis <[email protected]>
block: drop the cached plug time when blk_add_rq_to_plug() flushes
Mikulas Patocka <[email protected]>
dm-writecache: fix REQ_FUA processing
Mikulas Patocka <[email protected]>
dm-writecache: fix uncommitted_blocks underflow
Mikulas Patocka <[email protected]>
dm-writecache: fix a crash if we attempt to use non-dax device
Mikulas Patocka <[email protected]>
dm-writecache: fix a quirk in statistics
Mikulas Patocka <[email protected]>
dm-writecache: report I/O error if flush failed
Mikulas Patocka <[email protected]>
dm: fix a bug in dm_accept_partial_bio
Kaho Jiang <[email protected]>
media: em28xx: fix double free in em28xx_alloc_urbs
Ginger Li <[email protected]>
media: exynos4-is: Fix a race between s_stream(0) and the interrupt handler
Guangshuo Li <[email protected]>
media: rtl28xxu: fix SDR platform device leak
Wentao Liang <[email protected]>
media: pvrusb2: Fix USB parent device leak in class_dev_create()
Guangshuo Li <[email protected]>
media: tw686x: fix V4L2 device lifetime on probe failure
Tianchu Chen <[email protected]>
staging: rtl8723bs: fix RX buffer OOB write from device-reported length
Johan Hovold <[email protected]>
staging: greybus: uart: fix racy TIOCMIWAIT implementation
Krzysztof Kozlowski <[email protected]>
drm/msm/hdmi_bridge: Correct poweroff/audio cleanup order in post_disable
Krzysztof Kozlowski <[email protected]>
drm/msm/hdmi_phy: Cleanup after msm_hdmi_phy_resource_enable() failure
Alexander Sverdlin <[email protected]>
pwm: tiehrpwm: Clear period on disable to allow reconfiguration
Ryusuke Konishi <[email protected]>
nilfs2: clear dirty flag on bdev buffers on log write failure
Runyu Xiao <[email protected]>
ASoC: pcm6240: do not free an unrequested IRQ
Srish Srinivasan <[email protected]>
pseries/plpks: clear SED key data after use
Srish Srinivasan <[email protected]>
pseries/plpks: clear signed update authentication buffer
Srish Srinivasan <[email protected]>
pseries/plpks: clear sensitive PLPKS buffers
Srish Srinivasan <[email protected]>
pseries/plpks: validate input to plpks_signed_update_var()
Srish Srinivasan <[email protected]>
pseries/plpks: fix error handling in plpks_read_var()
Wentao Liang <[email protected]>
clk: starfive: jh7110-isp: fix refcount leak in jh7110_ispcrg_probe()
Takashi Iwai <[email protected]>
ALSA: core: Check shutdown flag at D0 power-state, too
Runyu Xiao <[email protected]>
m68k: dmasound: Keep the Q40 IRQ handler registered
Runyu Xiao <[email protected]>
ALSA: sgio2audio: Only free successfully requested IRQs
Hitesh Patel <[email protected]>
media: qcom: camss: vfe: Fix VFE reset while another line is streaming
Hitesh Patel <[email protected]>
media: qcom: camss: vfe-17x: Fix write master buffer done being dropped
Jiale Yao <[email protected]>
cxl/acpi: Check ACPI companion before use
Ibrahim Hashimov <[email protected]>
fs/ntfs3: fix integer overflow in find_log_rec() causing OOB read
Lucas Costa <[email protected]>
spi: bcm2835: fix device_node reference leak in bcm2835_spi_setup()
Cheick Traore <[email protected]>
iio: adc: stm32: fix minimum sampling time values
Jiale Yao <[email protected]>
iio: accel: adxl380: reject devices without match data
Jiale Yao <[email protected]>
iio: accel: adxl313: reject devices without match data
Jiale Yao <[email protected]>
iio: adc: ti-adc128s052: validate SPI match data
Jiale Yao <[email protected]>
iio: adc: mcp3911: reject devices without match data
Jiale Yao <[email protected]>
iio: adc: max11205: reject devices without match data
Jiale Yao <[email protected]>
iio: pressure: bmp280: validate SPI match data
Jiale Yao <[email protected]>
iio: potentiometer: x9250: reject devices without match data
Jiale Yao <[email protected]>
iio: frequency: adf4377: reject devices without match data
Jiale Yao <[email protected]>
iio: dac: ad5755: validate SPI match data
Wentao Liang <[email protected]>
ASoC: codecs: wcd9335: Fix SLIM interface device leak in wcd9335_slim_status()
Lu Baolu <[email protected]>
iommu/vt-d: Avoid out-of-range shift in qi_desc_dev_iotlb_pasid()
David Heidelberg <[email protected]>
arm64: dts: qcom: sdm845-xiaomi-polaris: Extend the xbl_mem region
David Heidelberg <[email protected]>
arm64: dts: qcom: sdm845-xiaomi-beryllium: Extend the xbl_mem region
Piotr Kubik <[email protected]>
netfilter: ctnetlink: fix inverted IPv6 address match in dump filter
Orgad Shaneh <[email protected]>
MIPS: mm: do not write a huge TLB entry when the probe misses
Runyu Xiao <[email protected]>
peci: npcm: Initialize state before requesting IRQ
Runyu Xiao <[email protected]>
peci: aspeed: Initialize state before requesting IRQ
Ma Ke <[email protected]>
ASoC: wcd9335: Fix device reference leak in wcd9335_slim_status()
David Cemin <[email protected]>
ASoC: sdw_utils: clear stale RT711 device reference on exit
Breno Leitao <[email protected]>
dcache: report a Tasks-RCU quiescent state in dentry_kill()
Ricardo Neri <[email protected]>
hwmon: (coretemp) Refresh the temperature on the first read
Richard Weinberger <[email protected]>
mtd: Call get_wunit() on the master partition
Wentao Liang <[email protected]>
mtd: mtdsuper: Fix MTD device reference leak in mtd_get_sb()
Wentao Liang <[email protected]>
mtd: maps: l440gx: Fix double put of the PM device in init_l440gx()
Wentao Liang <[email protected]>
mtd: maps: l440gx: Fix double put of the ISA bridge in init_l440gx()
Wentao Liang <[email protected]>
mtd: amd76xrom: Fix PCI device reference leak in amd76xrom_init_one()
Orgad Shaneh <[email protected]>
mtd: cfi_cmdset_0002: cap the write-buffer chunk at 256 bytes on an x8 device
Myeonghun Pak <[email protected]>
mtd: maps: pci: balance PCI enable on cleanup
Wentao Liang <[email protected]>
mtd: rawnand: atmel: Fix MCK clock leak in atmel_nand_controller_init()
Michael J. Ruhl <[email protected]>
platform/x86/intel/pmt: Block mmap when callback is present
Ridham Khurana <[email protected]>
hwmon: (lm95245) Fix negative temperature conversion
Wentao Liang <[email protected]>
regulator: core: Fix coupled regulators reference leak on removal
Aamir Ahmed <[email protected]>
clk: mvebu: ap-cpu-clk: Assign .num before accessing .hws
Junjie Cao <[email protected]>
ASoC: rt712-sdca-dmic: fix drvdata type in the gain controls
Guangshuo Li <[email protected]>
ASoC: Intel: atom: Fix platform device leak on probe failure
Jiacheng Xu <[email protected]>
kobject: fix out-of-bounds access in kobject_action_type()
Ryusuke Konishi <[email protected]>
nilfs2: fix deadlock between nilfs_evict_inode() and find_inode()
Tiezhu Yang <[email protected]>
perf loongarch: Fix discarded const qualifier in _get_field()
Lin Wang <[email protected]>
hwmon: (k10temp) Stop matching Hygon devices
David Heidelberg <[email protected]>
mfd: wcd934x: Fix NULL pointer dereference on IRQ probe deferral
David Heidelberg <[email protected]>
mfd: wcd934x: set DMA mask on parent to silence "DMA mask not set"
Hongyan Xu <[email protected]>
mfd: da903x: Cancel IRQ work during teardown
Gabor Juhos <[email protected]>
clk: qcom: gcc-ipq5018: mark 'gpll0_main' clock as critical
Francesco Dolcini <[email protected]>
arm64: dts: freescale: imx8mp-verdin-yavia: fix external GPIOs
Guangshuo Li <[email protected]>
media: atmel-isi: release unregistered video device on remove
Wentao Liang <[email protected]>
media: vpif_display: Fix i2c adapter reference leak in vpif_probe()
Wentao Liang <[email protected]>
media: vpif_capture: Fix i2c adapter reference leak in vpif_probe()
Wentao Liang <[email protected]>
media: au0828: Fix media device leak in au0828_usb_probe()
Runyu Xiao <[email protected]>
media: adv7180: Initialize mutex before ancillary clients
Myeonghun Pak <[email protected]>
media: tw68: balance PCI enable on cleanup
Myeonghun Pak <[email protected]>
media: cx18: Disable PCI device on probe failure
Myeonghun Pak <[email protected]>
media: go7007: unregister the I2C adapter on USB probe failure
Myeonghun Pak <[email protected]>
media: marvell: manage the MMP camera clock provider
Rohinthan P <[email protected]>
media: v4l2-ctrls: do nothing if controls[0] == NULL in cluster functions
Pengpeng Hou <[email protected]>
media: cec: extron: clear response tail before dispatch
Karl Mehltretter <[email protected]>
crypto: qat - zero the VF migration state buffer on save
Weili Qian <[email protected]>
crypto: hisilicon/hpre - fix GFP flags for dma_alloc_coherent
Weili Qian <[email protected]>
crypto: hisilicon/hpre - fix ECDH destination DMA mapping
Weili Qian <[email protected]>
crypto: hisilicon/hpre - return -EOVERFLOW for small ECDH output buffer
Weili Qian <[email protected]>
crypto: hisilicon/hpre - fix pointer dereference before length check
Mohamad Raizudeen <[email protected]>
crypto: amlogic - Fix IRQ handler return value and fallthrough logic
Yuchao Zhang <[email protected]>
md: validate bblog_size when loading v1.x badblocks metadata
Wentao Liang <[email protected]>
EDAC/i10nm: Fix mdev reference leak in i10nm_get_ddr_munits()
Aldo Ariel Panzardo <[email protected]>
nilfs2: fix checkpoint root lifetime on sysfs errors
Wentao Guan <[email protected]>
cpufreq/amd-pstate: Skip auto_sel write when it already matches the mode
Wentao Liang <[email protected]>
drm/mali-dp: Fix runtime PM leak in malidp_crtc_atomic_enable()
Judith Mendez <[email protected]>
arm64: dts: ti: k3-am62x-phyboard-lyra: Set SD clock pin as OUTPUT
Judith Mendez <[email protected]>
arm64: dts: ti: k3-am62-phycore-som: Set eMMC clock pin as OUTPUT
Judith Mendez <[email protected]>
arm64: dts: ti: k3-am62x-sk-common: Set SD clock pin as OUTPUT
Judith Mendez <[email protected]>
arm64: dts: ti: k3-am625-beagleplay: Set MMC clock pins as OUTPUT
Judith Mendez <[email protected]>
arm64: dts: ti: k3-am62-lp-sk: Set eMMC clock pins as OUTPUT
Judith Mendez <[email protected]>
arm64: dts: ti: k3-am62a-phycore-som: Set eMMC clock pin as OUTPUT
Judith Mendez <[email protected]>
arm64: dts: ti: k3-am62a7-sk: Set SD clock pin as OUTPUT
Judith Mendez <[email protected]>
arm64: dts: ti: k3-am62a7-sk: Set eMMC clock pin as OUTPUT
Judith Mendez <[email protected]>
arm64: dts: ti: k3-am62a: Fix MMC0_CLK register address
Wentao Liang <[email protected]>
ASoC: ti: davinci-mcasp: Fix runtime PM imbalance in __davinci_mcasp_set_clkdiv()
Sean Young <[email protected]>
media: meson-ir-tx: Prevent divide by zero in meson_irtx_prepare_pulse()
Sean Young <[email protected]>
media: ir_toy: Validate the maximum tx carrier
Myeonghun Pak <[email protected]>
leds: ktd2692: Pass context to regulator cleanup
Cong Nguyen <[email protected]>
staging: media: imx: csc-scaler: fix ipu_image_convert_run leak on queue error
Hui Peng <[email protected]>
seccomp: restore knotif->state when SECCOMP_ADDFD_FLAG_SEND is interrupted
Oleg Nesterov <[email protected]>
signalfd: don't dequeue the forced fatal signals
Runyu Xiao <[email protected]>
PCI: pciehp: Make 'pciehp_poll_mode' parameter read-only
Hui Peng <[email protected]>
ata: libata-scsi: abort multi-sector pass-through commands when multi_count is 0
Tsz Shan Chan <[email protected]>
iio: light: apds9306: fix default sampling frequency definition
Jean-Baptiste Maneyrol <[email protected]>
iio: imu: inv_icm42600: force accel odr change when switching power mode
Shehryar Ahmad <[email protected]>
iio: accel: adis16201: fix channel order for buffer mode
Wentao Liang <[email protected]>
regulator: rt6190: Fix runtime PM imbalance in rt6190_out_enable()
Karl Mehltretter <[email protected]>
fpga: Fix of_fpga_mgr_get() reference in fpga_mgr_lock() docs
Wentao Liang <[email protected]>
ASoC: codecs: wm8994: Fix runtime PM leak in wm8994_mic_detect()
Wentao Liang <[email protected]>
regulator: core: Fix rdev reference leak in regulator_resolve_supply()
Wentao Liang <[email protected]>
regulator: core: Fix c_rdev reference leak in regulator_resolve_coupling()
Shengming Hu <[email protected]>
cpufreq: conservative: Restrict deferred downscaling to low load
Martin Wilck <[email protected]>
md/raid5: validate payload size before calculating payload_len
Cao Guanghui <[email protected]>
md/raid5: fix NULL pointer dereference in raid5_free_percpu
Cao Guanghui <[email protected]>
md/raid5: track disks array size to fix extra_page leak on error paths
Guangshuo Li <[email protected]>
iio: adc: at91-sama5d2: disable autosuspend on remove
Guangshuo Li <[email protected]>
iio: accel: mma9553: disable autosuspend on remove
Guangshuo Li <[email protected]>
iio: accel: mma9551: disable autosuspend on remove
Guangshuo Li <[email protected]>
iio: accel: kxcjk-1013: Disable autosuspend on remove
Wentao Liang <[email protected]>
ASoC: arizona-jack: Fix runtime PM imbalance in arizona_start_hpdet_acc_id()
Wentao Liang <[email protected]>
ASoC: wm8994: Fix runtime PM imbalance in wm8994_component_probe()
Liu Chao <[email protected]>
usb: fotg210: validate endpoint index in ep0 handlers
Karl Mehltretter <[email protected]>
crypto: atmel-tdes - sync output bounce buffer before DMA
Yousef Alhouseen <[email protected]>
ntfs3: bound index head insertions by buffer capacity
Muhammad Bilal <[email protected]>
platform/x86: hp-bioscfg: fix slab-out-of-bounds write in hp_convert_hexstr_to_str()
Guangshuo Li <[email protected]>
media: i2c: alvium-csi2: balance runtime PM usage count on remove
Niklas Cassel <[email protected]>
ata: libata: Do not leave ata_host_stop() registered when activation fails
Niklas Cassel <[email protected]>
ata: libahci: Free the IRQs when activating a multi-IRQ host fails
Niklas Cassel <[email protected]>
ata: ahci_st: Assert the power down reset in the probe() error path
Niklas Cassel <[email protected]>
ata: ahci_st: Do not ignore errors when getting the reset controls
Chao Yu <[email protected]>
f2fs: compress: fix to handle race between truncate and writeback
Jiucheng Xu <[email protected]>
f2fs: force out-place update for all writes on compressed file
Matthew Sakai <[email protected]>
dm vdo indexer: validate record page numbers better
Matthew Sakai <[email protected]>
dm vdo indexer: prevent delta list overflow on load
Kyle Zeng <[email protected]>
affs: validate blocks before freeing them
Bradley Morgan <[email protected]>
PM: CPU: Restore synchronize_rcu() to cpu_pm_unregister_notifier()
Runyu Xiao <[email protected]>
crypto: ccp - Initialize DBC ioctl mutex before registering device
Karl Mehltretter <[email protected]>
lib/842: require a complete history block for repeat templates
Karl Mehltretter <[email protected]>
lib/842: reject output overflows from index and short data
Karl Mehltretter <[email protected]>
crypto: atmel-aes - fix AADLENR for standalone GHASH
Karl Mehltretter <[email protected]>
crypto: atmel-tdes - zero-initialize device state
Junrui Luo <[email protected]>
media: vicodec: zero-initialize stateful decoder heap buffers
Fan Wu <[email protected]>
media: vivid: cancel svid ctrl work on release
Juan Perdomo <[email protected]>
media: cx231xx: preserve I2C transfer length
Maxim Skokov <[email protected]>
media: vivid: round the height down to the vertical subsampling factor
Eric Kim <[email protected]>
sched/fair: Reset NUMA fault locality after scan period update
Jean-Baptiste Maneyrol <[email protected]>
iio: imu: inv_icm42600: fix odr change not caught in certain cases
Shengzhuo Wei <[email protected]>
power: supply: bq27xxx: synchronize work cancellation on suspend
Robin Snyders <[email protected]>
power: supply: qcom_smbx: notify battery overvoltage recovery
Robin Snyders <[email protected]>
power: supply: qcom_smbx: fix float voltage selector
Robin Snyders <[email protected]>
power: supply: qcom_smbx: test battery health status bits
Robin Snyders <[email protected]>
power: supply: qcom_smbx: include base when petting watchdog
Karl Mehltretter <[email protected]>
ACPI: pfr_update: zero-initialize capability query result
Runyu Xiao <[email protected]>
dmaengine: altera-msgdma: initialize state before requesting IRQ
Damon Ding <[email protected]>
drm/bridge: analogix_dp: Restore mandatory samsung DP DT properties
Fan Wu <[email protected]>
media: nuvoton: npcm-video: quiesce VCD IRQ before teardown
Greg Kroah-Hartman <[email protected]>
media: stv0900: bound DiSEqC reply length to msg[] size
Greg Kroah-Hartman <[email protected]>
media: stv090x: bound DiSEqC reply length to msg[] size
Greg Kroah-Hartman <[email protected]>
media: adv7604: avoid negative array index in log_status when cp_read fails
James Hilliard <[email protected]>
mtd: rawnand: sunxi: reject ECC maximization on small pages
Balakrishnan Sambath <[email protected]>
media: microchip-isc: don't sleep in the clk .is_enabled callback
Balakrishnan Sambath <[email protected]>
media: microchip-isc: fix PM runtime leak in AWB work handler
Balakrishnan Sambath <[email protected]>
media: microchip-isc: do not touch WB registers when not streaming
Balakrishnan Sambath <[email protected]>
media: microchip-isc: disable histogram and flush AWB work on teardown
Balakrishnan Sambath <[email protected]>
media: microchip-isc: synchronize the IRQ before disabling clocks on stop
Balakrishnan Sambath <[email protected]>
media: microchip-isc: fix awb_mutex and lock lifecycle
Srinivas Kandagatla <[email protected]>
ASoC: codecs: lpass-wsa-macro: use v2.5 Compander1 addresses on v2.5+
Xu Rao <[email protected]>
media: m2m-deinterlace: fix default capture field
Punnay Sharma <[email protected]>
staging: media: av7110: fix sp8870 initialization failure state
Punnay Sharma <[email protected]>
staging: media: av7110: fix corrupted BER reporting in sp8870
Julian Braha <[email protected]>
media: marvell-cam: fix unmet dependency for VIDEO_MMP_CAMERA
Jeffin Philip <[email protected]>
media: vidtv: fix uaf in vidtv_bridge_on_new_pkts_avail
Piyush Patle <[email protected]>
media: vidtv: fix frontend reference leak on unbind
Junrui Luo <[email protected]>
media: vicodec: make encoder CAPTURE dimensions read-only
Junrui Luo <[email protected]>
media: vicodec: fix out-of-bounds write on under-rounded coded dimensions
Younho Choi <[email protected]>
media: vim2m: keep transaction buffer count stable while streaming
Runyu Xiao <[email protected]>
media: saa7146: Initialize interrupt lock before requesting IRQ
Shengzhuo Wei <[email protected]>
media: go7007: bound EZ-USB I2C transfers to the usb_buf size
Linkai Gong <[email protected]>
media: i2c: tc358743: add missing color-space strings
Ruoyu Wang <[email protected]>
media: au0828: Free URBs when starting DVB streaming fails
Takashi Sakamoto <[email protected]>
firewire: core: fix source bus ID detection for AT context in big-endian systems
Andi Shyti <[email protected]>
media: cx231xx: Fix cleanup path on failure
Fan Wu <[email protected]>
media: cx231xx-audio: drain wq_trigger before audio fini
Andrea Pesaresi <[email protected]>
arm64: dts: mediatek: mt7986: correct timer frequency
Baolin Liu <[email protected]>
isofs: fix Rock Ridge CE extent validation on multisession media
Thorsten Blum <[email protected]>
thermal: intel: int340x: Fix temperature selection around 0 C
Thorsten Blum <[email protected]>
thermal: intel: powerclamp: Reject invalid window_size values
Francesco Dolcini <[email protected]>
arm64: dts: ti: k3-am62-verdin: Set MMC clock pins as OUTPUT
Amir Goldstein <[email protected]>
fs: make sure to call fsnotify_inoderemove() only once when inode is dead
Karl Mehltretter <[email protected]>
fs_pin: publish pins with RCU list helpers
Miquel Raynal <[email protected]>
mtd: spi-nor: Unprepare legacy controllers upon RWW wait interruption
HyeongJun An <[email protected]>
mtd: spi-nor: sfdp: check the length of the SCCR map
HyeongJun An <[email protected]>
mtd: spi-nor: sfdp: check the length of the xSPI Profile 1.0 table
Serin Yeh <[email protected]>
media: i2c: ov8856: fix debug message to report actual CSI-2 lane count
Abdun Nihaal <[email protected]>
wifi: ath11k: Fix possible memory leak in ath11k_dp_srng_setup()
Runyu Xiao <[email protected]>
hte: tegra194: Initialize slice locks before registering chip
Yuan Chen <[email protected]>
bpf: Fix queue/stack map u32 index overflow
Yo'av Moshe <[email protected]>
ARM: imx: Fix suspend/resume crash with Clang CFI
hanzhijian <[email protected]>
clk: mstar: msc313-mpll: fix off-by-one in clock array allocation
Laxman Acharya Padhya <[email protected]>
wifi: rtw89: cap firmware section_num before parsing
Yi Cong <[email protected]>
wifi: rtw89: 8851b: fix swapped DPK channel/bandwidth backup fields
イムティヤズ <[email protected]>
wifi: rtw88: fix out-of-bounds CAM write when key table is full
Justin Chen <[email protected]>
memory: brcmstb_dpfe: Bounds check DCPU-supplied MSG_ARG_COUNT
Justin Chen <[email protected]>
memory: brcmstb_dpfe: Fix out-of-bounds access due to DCPU offset
Sam Price <[email protected]>
microblaze: preserve the MSR carry flags across signals
Ramin Moussavi <[email protected]>
microblaze: don't clobber r3/r4 restored by rt_sigreturn
Ramin Moussavi <[email protected]>
microblaze: reserve the ABI argument-home area in the signal frame
HyeongJun An <[email protected]>
remoteproc: elf_loader: Bound the section header table
Daehyeon Ko <[email protected]>
ipc/mqueue: release notification resources during inode eviction
Daehyeon Ko <[email protected]>
aio: prevent eventfd/epoll recursion on poll
Jan Kara <[email protected]>
udf: Make sure there's enough space for LVID implementation use field
Karl Mehltretter <[email protected]>
microblaze: Fix MB_MANAGER build with older binutils
Fan Wu <[email protected]>
media: imx-jpeg: finish the job on device_run() error paths
Sean Young <[email protected]>
media: ir-hix5hd2: Ensure rdev is setup before interrupts are enabled
Sean Young <[email protected]>
media: meson-ir-tx: Ensure probe error is propagated
Sean Young <[email protected]>
media: meson-ir-tx: Ensure rc_free_device() is called on unbind
Sean Young <[email protected]>
media: meson-ir-tx: Ensure clock is disabled on unbind
Sean Young <[email protected]>
media: sunxi-cir: Ensure no more interrupts can occur before free
Sean Young <[email protected]>
media: redrat3: Ensure all urbs are suspended
Sean Young <[email protected]>
media: redrat3: Ensure we don't read beyond the end of the packet
Sean Young <[email protected]>
media: streamzap: Add missing rc_unregister_device()
Harry Wentland <[email protected]>
drm/amd/display: Force GAMCOR for subsampled surfaces with PQ/Gamma22/HLG
YuBiao Wang <[email protected]>
drm/amdgpu: recompute the dw estimate after allocating a new VM update job
Marek Czernohous <[email protected]>
drm/nouveau: don't dereference outp before checking it in nouveau_dp_irq
Marek Czernohous <[email protected]>
drm/nouveau: cancel the DP IRQ work before freeing the connector
Marek Czernohous <[email protected]>
drm/nouveau: disable the fence uevent work instead of just cancelling it
Zhenhao Wan <[email protected]>
drm/nouveau/svm: drain fault handler before freeing svmm
Zhenhao Wan <[email protected]>
drm/nouveau: reject zero-size notifier object allocation
Sean Young <[email protected]>
media: rc: Fix race between bpf(BPG_PROG_ATTACH) and device unregister
Fan Wu <[email protected]>
scsi: dc395x: sync the waiting_timer before freeing the host
Fan Wu <[email protected]>
media: s5p-mfc: use timer_shutdown_sync() for the self-rearming watchdog
Vernon Yang <[email protected]>
mm: khugepaged: fix swap entry value to folio_pfn()
Fan Wu <[email protected]>
ASoC: amd: ps: fix snd_acp63_remove() teardown ordering
Yibo Tan <[email protected]>
media: ipu-bridge: Fix use-after-free in IVSC error path
Jérémy Jean <[email protected]>
nvmet-auth: serialize access to DH-HMAC-CHAP state to fix UAF
Marco Crivellari <[email protected]>
nvmet: replace use of system_wq with system_percpu_wq
Weiming Shi <[email protected]>
virtio_net: atomically disable rx mode work
Ruide Cao <[email protected]>
mptcp: hold MP_JOIN msk ref when cloning reqsk
Zhao Li <[email protected]>
wifi: mt76: mt7996: unlink TWT flow if the MCU rejects the agreement
Tianchu Chen <[email protected]>
staging: rtl8723bs: fix protected RX frame validation in decrypt path
Khasar Munkh-Erdene <[email protected]>
staging: rtl8723bs: fix spacing around operators in rtw_recv.c
Sean Christopherson <[email protected]>
KVM: guest_memfd: Gracefully handle xarray errors when binding a memslot
Josef Bacik <[email protected]>
mm/hugetlb: fix use-after-free of a new anon folio
Oscar Salvador <[email protected]>
mm,hugetlb: sort out folio locking in the faulting path
Oscar Salvador <[email protected]>
mm,hugetlb: change mechanism to detect a COW on private mapping
Peter Xu <[email protected]>
mm/hugetlb: rename avoid_reserve to cow_from_owner
Peter Xu <[email protected]>
mm/hugetlb: stop using avoid_reserve flag in fork()
Nirmoy Das <[email protected]>
iommufd: Fix event queue release use-after-free
Honglei Huang <[email protected]>
drm/amdgpu: drop retry loop in amdgpu_hmm_range_get_pages
Stefan Metzmacher <[email protected]>
smb: smbdirect: fix buffer length underflow in RDMA transfers
Chris Mason <[email protected]>
ovl: do not copy up a dentry that was removed
Chris Mason <[email protected]>
ovl: hold a reference on the parent in readdir
Chris Mason <[email protected]>
ovl: check that the parents of volatile/dirty are dirs
Hyunwoo Kim <[email protected]>
inet: reject unhashed sockets during established lookups
Mike Rapoport (Microsoft) <[email protected]>
x86/mm/pat: Use pr_warn() for early W^X warnings
Sean Christopherson <[email protected]>
KVM: VMX: Formally define KVM's "0xdead" exit reason used for failed VM-Enter
DaeMyung Kang <[email protected]>
ksmbd: fix named stream write and EOF handling
DaeMyung Kang <[email protected]>
ksmbd: use the existing xattr name for a named stream
Henry Hu <[email protected]>
ksmbd: fix invalid pointer dereference when get_inode_acl() fails
Ian Bridges <[email protected]>
ksmbd: fix session reference leak on compounded SESSION_SETUP
Mario Peter <[email protected]>
driver core: take parent lock in async device attach
Vincent Liu <[email protected]>
driver core: Check drivers_autoprobe for all added devices
Xiaoyao Li <[email protected]>
KVM: VMX: Preserve negative return value in vmx_handle_exit() with bus lock detected
Ian Bridges <[email protected]>
ksmbd: fix use-after-free after a failed durable reconnect
Dairui Zhang <[email protected]>
ksmbd: verify transform SessionId matches the decrypted header
Ian Bridges <[email protected]>
ksmbd: fix out-of-bounds read when padding the final compound response
Namjae Jeon <[email protected]>
ksmbd: prevent share root removal through empty paths
Namjae Jeon <[email protected]>
ksmbd: prevent stale data from being written by SMB2 WRITE requests
Aamir Ahmed <[email protected]>
ksmbd: deny access for an empty DACL instead of granting the request
Zikang Gao <[email protected]>
smb: client: do not pass a NULL buf to is_oplock_break()
Fredric Cover <[email protected]>
smb: client: fix early procfs exposure race
Zi Yan <[email protected]>
mm/rmap: don't discard lazyfree THPs at PMD level
David Woodhouse <[email protected]>
tun: Require CAP_NET_ADMIN to attach to an ownerless device
Peter Griffin <[email protected]>
opp: fix use after free in _update_opp_table_clk()
Pablo Neira Ayuso <[email protected]>
netfilter: conntrack: always lower timeout for non-closing RST packets
Srinivasan Shanmugam <[email protected]>
drm/amdgpu/powerplay: Align get_tonga_state_array() header with prototype
Sean Young <[email protected]>
media: rc: Fix build failure with CONFIG_LIRC disabled
Cheng Yongkang <[email protected]>
io_uring/timeout: count cancelled timeouts in cq_timeouts
Chris Mason <[email protected]>
io_uring/sqpoll: don't wait for the thread to exit
Chris Mason <[email protected]>
io_uring: free XArray nodes left by a failed store
Chris Mason <[email protected]>
io_uring: charge tctx nodes and personalities
Chris Mason <[email protected]>
io_uring/rsrc: charge buffer arrays and nodes to memcg
Josef Bacik <[email protected]>
io_uring/io-wq: no new workers once the exit has begun
Daan De Meyer <[email protected]>
io_uring/net: don't retry a non-blocking connect() that fails with -EAGAIN
Yichong Chen <[email protected]>
io_uring/net: keep recvmsg buffer select length within MAX_RW_COUNT
Yichong Chen <[email protected]>
io_uring/kbuf: advance head when a pickup empties the buffer ring
Chris Mason <[email protected]>
ovl: set OVL_WHITEOUTS before publishing the upper dir
Jiale Yao <[email protected]>
HID: roccat: savu: reject short special reports
Jiale Yao <[email protected]>
HID: roccat: ryos: reject short special reports
Jiale Yao <[email protected]>
HID: roccat: pyra: reject short button reports
Jiale Yao <[email protected]>
HID: roccat: kovaplus: reject short button reports
Jiale Yao <[email protected]>
HID: roccat: konepure: reject short button reports
Jiale Yao <[email protected]>
HID: roccat: koneplus: reject short button reports
Jiale Yao <[email protected]>
HID: roccat: isku: reject short button reports
Gabor Tanz <[email protected]>
HID: quirks: Always poll the Anne Pro 2 with product ID a292
Jiale Yao <[email protected]>
HID: pxrc: reject short input reports
Jiale Yao <[email protected]>
HID: prodikeys: validate fixed-format MIDI reports
Lorenzo Stoakes (ARM) <[email protected]>
HID: picoLCD: check for fb_deferred_io_init() error
Jiale Yao <[email protected]>
HID: mcp2221: validate response report length
Jiale Yao <[email protected]>
HID: mcp2200: validate READ_ALL response length
Jiale Yao <[email protected]>
HID: logitech-dj: validate unnumbered keyboard reports
Jiale Yao <[email protected]>
HID: elo: reject short touchscreen reports
Jiale Yao <[email protected]>
HID: cp2112: validate response report lengths
Jiale Yao <[email protected]>
HID: cougar: reject short special-key reports
Alan Stern <[email protected]>
HID: core: Fix out-of-bounds left shift by 32 in s32ton()
Basavaraj Natikar <[email protected]>
HID: amd_sfh: Use report type from request node
Basavaraj Natikar <[email protected]>
HID: amd_sfh: Remove unsupported motion-state field from accelerometer report
Jiale Yao <[email protected]>
HID: zydacron: validate key report length
Amit Machhiwal <[email protected]>
KVM: PPC: Fix get_d_signext() 12-bit displacement for paired-single D-form
Amit Machhiwal <[email protected]>
KVM: PPC: Book3S HV: Add preempt_disable() around virtual-mode HPTE bit-lock users
Sean Christopherson <[email protected]>
KVM: x86: Zero reserved synic flags when delivering message to avoid stack leak
Chengfeng Ye <[email protected]>
KVM: x86: Take SRCU in kvm_zap_gfn_range()
Loc Nguyen <[email protected]>
KVM: x86: Request event processing for exception VM-Exits
Sean Christopherson <[email protected]>
KVM: x86: Preserve DR6.BLD (Bus Lock Detect) when delivering #DB payload
David Woodhouse <[email protected]>
KVM: x86/xen: Take kvm->srcu in __kvm_xen_has_interrupt()
David Woodhouse <[email protected]>
KVM: x86/xen: Enforce 4-byte alignment of vcpu_info registration
Sean Christopherson <[email protected]>
KVM: x86/mmu: Bug the VM if KVM calcs a CPU role with EFER.LMA=1 && CR4.PAE=0
Sean Christopherson <[email protected]>
KVM: x86/mmu: Bug the VM if KVM attempts to walk more levels than the MMU has
Sean Christopherson <[email protected]>
KVM: Use goto to handle errors during memslot preparation
Sean Christopherson <[email protected]>
KVM: nSVM: Ignore EFER.LMA if EFER.LME=0 when preparing L2 state
Yosry Ahmed <[email protected]>
KVM: SVM: Trigger new ASID allocation in both VMCBs on pCPU switch
Mike Rapoport (Microsoft) <[email protected]>
x86/mm/pat: Fix effective RW computation in lookup_address_in_pgd_attr()
David Howells <[email protected]>
rxrpc: Fix return in rxrpc_recvmsg_data() for service calls
David Howells <[email protected]>
rxrpc: Fix double IRQ enablement
Chuck Lever <[email protected]>
SUNRPC: Treat every TLS error alert as fatal
Ameer Hamza <[email protected]>
sunrpc: treat empty auth.unix.gid replies as negative entries
Zhiling Zou <[email protected]>
SUNRPC: trace an accepted transport before publishing it
Chuck Lever <[email protected]>
SUNRPC: Resume receiving after a TLS control record
Chuck Lever <[email protected]>
SUNRPC: Reject a TLS alert record that is not two octets
Chuck Lever <[email protected]>
SUNRPC: Reject a socket that already has an svc_sock attached
Chris Mason <[email protected]>
sunrpc: pin gss module across auth_domain RCU free
Jeff Layton <[email protected]>
SUNRPC: keep the first error in svc_register()
Jérémy Jean <[email protected]>
SUNRPC: fix oversized GSS proxy token copy
Chuck Lever <[email protected]>
SUNRPC: Do not credit control-record octets to the RPC stream
Chuck Lever <[email protected]>
SUNRPC: Copy the deferred RPC Call from the head buffer
Aldo Ariel Panzardo <[email protected]>
nfsd: zero NFSv4 COMPOUND tag padding
Jeff Layton <[email protected]>
NFSD: validate transport name in listener_set before serv creation
Chuck Lever <[email protected]>
NFSD: Set nn->cld_net before registering the cld pipe
Chuck Lever <[email protected]>
NFSD: Return NFSERR_ISDIR for NFSv2 READ and WRITE on a non-regular file
Chuck Lever <[email protected]>
NFSD: Resolve the recall-any mask names in the trace format
Chuck Lever <[email protected]>
NFSD: Reject an oversized principal hash from nfsdcld
Aldo Ariel Panzardo <[email protected]>
nfsd: propagate SETXATTR value decode errors
Jérémy Jean <[email protected]>
nfsd: preflight SEQUENCE replies before accepting a slot
Chuck Lever <[email protected]>
NFSD: map fh_verify() status codes for NFS_ACLv3 replies
NeilBrown <[email protected]>
nfsd: honour client-provided attributes for NFS4_CREATE_EXCLUSIVE4_1
Cen Zhang (Microsoft Security FORGE Labs) <[email protected]>
nfsd: hold cl_lock in client_has_openowners()
Chuck Lever <[email protected]>
NFSD: Fix out-of-bounds read in the rpc_status dump
Wentao Liang <[email protected]>
nfsd: Fix id-to-name cache entry leak in idtoname_parse()
Chuck Lever <[email protected]>
NFSD: Fail a pool_threads read whose reply does not fit
Ameer Hamza <[email protected]>
nfsd: don't modify a session slot when replaying its cached reply
Chuck Lever <[email protected]>
NFSD: Don't complete a cld upcall the daemon has not read
Chuck Lever <[email protected]>
NFSD: Do not send CB_RECALL_ANY to NFSv4.0 clients
Aldo Ariel Panzardo <[email protected]>
NFSD: copy SETXATTR data from all XDR buffer segments
Aldo Ariel Panzardo <[email protected]>
nfsd: clear XDR padding in GETXATTR replies
Jeff Layton <[email protected]>
NFSD: cap the number of listeners accepted in listener_set
Benjamin Coddington <[email protected]>
NFSv4/flexfiles: fail I/O to the data server once a lock is lost
Benjamin Coddington <[email protected]>
NFSv4/filelayout: Anchor page coalescing on pattern_offset
Benjamin Coddington <[email protected]>
NFSv4.1/pnfs: suspend pNFS on NFS4ERR_TOOSMALL from LAYOUTGET
Chuck Lever <[email protected]>
pnfs/blocklayout: Complete a device upcall when the pipe is closed
Chuck Lever <[email protected]>
pnfs/blocklayout: Complete a device upcall only on its own reply
Benjamin Coddington <[email protected]>
pNFS: Fix CB_NOTIFY_DEVICEID CHANGE to consume ndc_immediate
Ratnaker Gautam <[email protected]>
smb: client: validate NT transaction response layout and offsets
Dominik Maier <[email protected]>
smb: client: fix slab-out-of-bounds write in id_mode_to_cifs_acl()
Abdifatah Suruur <[email protected]>
smb: client: fix fiemap wild read on empty truncated response
Luxiao Xu <[email protected]>
smb: client: fix buffer overflow in SMB2_tcon()
Paulo Alcantara <[email protected]>
smb: client: don't resurrect an exiting tcon from cached dir workers
VeroFess <[email protected]>
smb: server: size directory name conversion buffer correctly
Darrick J. Wong <[email protected]>
xfs: range-check bc_levels array access in scrub tracepoints
Darrick J. Wong <[email protected]>
xfs: propagate errors while checking null siblings
Darrick J. Wong <[email protected]>
xfs: opportunistically skip btree block checks
Darrick J. Wong <[email protected]>
xfs: only written file data blocks can be shared
Darrick J. Wong <[email protected]>
xfs: never reset the default quota timer
Darrick J. Wong <[email protected]>
xfs: fix data fork block count check in xrep_inode_blockcounts
Darrick J. Wong <[email protected]>
xfs: fix correction of unwritten extents in quota file data fork
Darrick J. Wong <[email protected]>
xfs: don't subtract excess usage twice when computing agf_btreeblks
Darrick J. Wong <[email protected]>
xfs: don't rescan ifree and icount when frozen
Darrick J. Wong <[email protected]>
xfs: don't overrun incore inode when cleaning attr forks
Darrick J. Wong <[email protected]>
xfs: don't clear COWEXTSIZE on directories on reflink filesystems
Darrick J. Wong <[email protected]>
xfs: clear set[ug]id mode bits when zapping attr fork
Darrick J. Wong <[email protected]>
xfs: clarify various parts of the bitmap API
Darrick J. Wong <[email protected]>
xfs: check for termination during rmap btree walk
Darrick J. Wong <[email protected]>
xfs: check for fragments when full-extent sharing matches
Aldo Ariel Panzardo <[email protected]>
xfs: bound inode fork length against the fork size during log recovery
Aldo Ariel Panzardo <[email protected]>
xfs: bound da-node entry count against the correct geometry
Darrick J. Wong <[email protected]>
xfs: always zero the whole shortform header when zeroing attr fork
Darrick J. Wong <[email protected]>
xfs: always report scrub errors in tracepoints
Darrick J. Wong <[email protected]>
xfs: always report inode repair setup failures
Darrick J. Wong <[email protected]>
xfs: always forget cached ACLs if the attr fork swap succeeds
Darrick J. Wong <[email protected]>
xfs: abort directory tree repair whenever dl->aborted is set
Aldo Ariel Panzardo <[email protected]>
xfs: reject remote xattr entries with an out-of-range value length
Aldo Ariel Panzardo <[email protected]>
xfs: reject out-of-range attribute value lengths in xfs_attr_copy_value
Darrick J. Wong <[email protected]>
xfs: reject absurdly large xattr value lengths in xchk_xattr_actor
Aleksandr Nogikh <[email protected]>
media: usbtv: fix null-pointer dereference on disconnect
Johan Hovold <[email protected]>
media: usbtv: drop redundant device reference
Al Viro <[email protected]>
ufs: fix ufs_read_cylinder() failure handling
Jean Delvare <[email protected]>
EDAC/mc: Really fix error path ordering in edac_mc_alloc()
Joseph Qi <[email protected]>
ksmbd: fix breaking_cnt leak on early return in oplock_break()
Yongjun Gwon <[email protected]>
ksmbd: serialize directory emptiness checks with readdir
Takashi Iwai <[email protected]>
ALSA: usb-audio: Use the right limit for PCM OOB check
Darrick J. Wong <[email protected]>
xfs: fix xchk_stats_estimate_bufsize to allow for the trailing null
Darrick J. Wong <[email protected]>
xfs: adjust checks for cross-AG reaping issues
Darrick J. Wong <[email protected]>
xfs: jump out of xchk_bmap_check_rmap if fatal signals
Darrick J. Wong <[email protected]>
xfs: mark overfull dabtree node blocks as corrupt
Darrick J. Wong <[email protected]>
xfs: check fork type against dabtree block magic number
Darrick J. Wong <[email protected]>
xfs: abort dirtree repair if the live update hook dies
Darrick J. Wong <[email protected]>
xfs: fix revalidation of xchk_dquot_iter cached mappings
Darrick J. Wong <[email protected]>
xfs: bail out of directory tree repairs on error
Darrick J. Wong <[email protected]>
xfs: assign an owner to scrub_stats_fops
Darrick J. Wong <[email protected]>
xfs: allow softlimit with no hardlimit in quota scrub
Darrick J. Wong <[email protected]>
xfs: fix lost errno returned from xfarray_foliosort
Darrick J. Wong <[email protected]>
xfs: don't repair fs summary counters with garbage
Darrick J. Wong <[email protected]>
xfs: fix skipped inode mask handling in iscan
Darrick J. Wong <[email protected]>
xfs: don't proceed with xattr repair if the live update fails
Darrick J. Wong <[email protected]>
xfs: don't fix the directory tree if live update fails
Darrick J. Wong <[email protected]>
xfs: don't pass iget failures up when marking ondisk inodes
Darrick J. Wong <[email protected]>
xfs: always reset incore attr fork buffer when resetting fork
Darrick J. Wong <[email protected]>
xfs: fix inode btree repair when a cluster is larger than a chunk
Darrick J. Wong <[email protected]>
xfs: actually report corrupt xattrs as XFAIL during cross-referencing
Darrick J. Wong <[email protected]>
xfs: fix buffer overflow in corrupt inline attr structure
Darrick J. Wong <[email protected]>
xfs: fix unnecessary dapos truncation in xchk_dir_walk
Darrick J. Wong <[email protected]>
xfs: online quotacheck must dirty dquot if enforcement adjustments needed
Darrick J. Wong <[email protected]>
xfs: fix buffer overruns in xfs_ioc_attr_list
Darrick J. Wong <[email protected]>
xfs: fix missing xfs_qm_adjust_dqlimits call in quotacheck repair
Darrick J. Wong <[email protected]>
xfs: fix xfs_rename_space_res for non-pptr filesystems
Darrick J. Wong <[email protected]>
xfs: fix ondisk symlink target validation in xrep_dinode_check_dfork
Darrick J. Wong <[email protected]>
xfs: compute the correct fdblocks/frextents for repair when they're negative
Darrick J. Wong <[email protected]>
xfs: clear the symlink zapped flag if inline symlink is ok
Amir Goldstein <[email protected]>
ovl: skip copy up of empty security.capability
Chris Mason <[email protected]>
ovl: set the revalidate flags after d_instantiate()
Chris Mason <[email protected]>
ovl: read the nlink xattr of every indexed non-dir
Amir Goldstein <[email protected]>
ovl: fortify ovl_copy_xattr() against underlying layer modifications
Chris Mason <[email protected]>
ovl: fix a torn path in ovl_get_redirect()
Chris Mason <[email protected]>
ovl: do not copy up an xattr value that was never read
Chris Mason <[email protected]>
ovl: always encode the origin fh when index is enabled
Chris Mason <[email protected]>
ovl: use the pinned upper dir in ovl_fix_origin()
Chris Mason <[email protected]>
ovl: take a snapshot of the name for copy up
Weiming Shi <[email protected]>
smb: client: stop processing a read response after a receive error
Diego Oliva <[email protected]>
smb: client: fix OOB last_entry pointer from unbounded LastNameOffset
Cen Zhang <[email protected]>
ocfs2: snapshot dentry names in file and setattr traces
Cen Zhang <[email protected]>
ocfs2: pin refcount trees before dropping the lookup lock
Jiaming Zhang <[email protected]>
ocfs2: fix chunk number of the first chunk in a local quota file
Cen Zhang <[email protected]>
ocfs2: cancel quota sync work before freeing quota info
Joseph Qi <[email protected]>
ocfs2/dlm: hold the lookup reference across convert AST enqueue
Cen Zhang <[email protected]>
ocfs2/dlm: hold a lock reference across grant AST enqueue
Cen Zhang <[email protected]>
ocfs2/heartbeat: unlink live slots when their node is missing
Sean Young <[email protected]>
media: rc: Fix ABBA deadlock by making locks more fine grained
Sean Young <[email protected]>
media: rc: Fix use after free in bpf progs
Sean Young <[email protected]>
media: rc: After rc_unregister_device() timers can be re-armed
Sean Young <[email protected]>
media: rc: Use after free in ir_raw_event_handle()
Sean Young <[email protected]>
media: rc: mce_kbd: Fix inconsistent locking of keylock
Weigang He <[email protected]>
media: rc: fintek-cir: process a full RX buffer instead of overflowing it
Sean Young <[email protected]>
media: rc: Ensure registered is cleared in error path
Sean Young <[email protected]>
media: rc: Ensure that rc_unregister_device() does not free input device
Janne Grunau <[email protected]>
nvmem: core: Fix OOB read for bit offsets of more than one byte
Myeonghun Pak <[email protected]>
power: supply: sbs-battery: disable polling before supply teardown
Bryan O'Donoghue <[email protected]>
phy: core: Fix race-condition between _of_phy_get() and try_module_get()
Nickolai Zeldovich <[email protected]>
resource: report a devm_request_resource() conflict under the lock
YANXIN LI <[email protected]>
ufs: use u64 for directory size in ufs_last_byte
Nguyen Quang Le Kien <[email protected]>
usb: gadget: fix refcount underflow in gadgetfs_bind() error path
Rosen Penev <[email protected]>
wifi: ath9k: delete channel-context timers on deinit
Yuchao Zhang <[email protected]>
xen-blkfront: unbind irq before tearing down ring and shadow requests
Igor Putko <[email protected]>
serial: core: shut down initialized port on removal
Vernon Yang <[email protected]>
mm: khugepaged: fix folio is used after folio_put/unlock()
Imre Kaloz <[email protected]>
mm/slab: sample slab_state once in kmem_cache_destroy()
Rik van Riel <[email protected]>
media: redrat3: fix UAF in probe error path leaving rc device registered
Balakrishnan Sambath <[email protected]>
media: microchip-isc: take a reference on the parsed endpoints
Cong Nguyen <[email protected]>
media: microchip-csi2dc: fix async notifier leak on probe error path
Fan Wu <[email protected]>
media: marvell: mcam: stop DMA and cancel s_bh_work before freeing DMA buffers
Fan Wu <[email protected]>
media: imx-jpeg: cancel timeout worker when streaming stops
Shuangpeng Bai <[email protected]>
media: gspca: use vb2_video_unregister_device() on disconnect
Myeonghun Pak <[email protected]>
media: cx23885: unregister DVB bus when SP2 CI setup fails
Amit Machhiwal <[email protected]>
KVM: PPC: Book3S HV: Add SRCU protection for virtual-mode HPT hcalls
Kyle Zeng <[email protected]>
io_uring/io-wq: save worker type before dropping its reference
Yousef Alhouseen <[email protected]>
HID: hiddev: keep state alive through disconnect unlock
Richard Patel <[email protected]>
genirq: Move interrupt thread exit_work object to irqaction
Richard Patel <[email protected]>
genirq: Defer kfree(irqaction) until irq_thread_dtor() finishes
Ngoc Quy <[email protected]>
fs/proc/task_mmu: pin mm_users in do_pagemap_scan()
Xiang Mei <[email protected]>
fbdev: udlfb: don't rebuild the mode list while the framebuffer is in use
Yibo Tan <[email protected]>
fbdev: atmel_lcdfb: Prevent FIFO work after removal
Osama Abdelkader <[email protected]>
drm/panthor: Fix TOCTOU race between GROUP_REGISTERED check and erase
Bui Viet Dung <[email protected]>
Bluetooth: hci_vhci: Pin module for debugfs file operations
Sung Byeongchan <[email protected]>
ALSA: pcmtest: handle multiple wraps in random capture fill
Takashi Iwai <[email protected]>
ALSA: control: Fix UAF in snd_ctl_elem_add() on card disconnect
Andreas Hindborg <[email protected]>
rust: block: fix Send bound for GenDisk
Miguel Ojeda <[email protected]>
objtool/rust: add one more noreturn Rust function for Rust 1.101.0
Karl Mehltretter <[email protected]>
klist: avoid accesses after waking klist_remove()
Ping Cheng <[email protected]>
HID: wacom: Write shared touch initial status only once
Ping Cheng <[email protected]>
HID: wacom: Setup SW_MUTE_DEVICE according to the order of input registration
Lee Jones <[email protected]>
HID: wacom: Redesign shared sibling data lifecycle
Lee Jones <[email protected]>
HID: wacom: Fix Use-After-Free in wacom_bamboo_pad
Lee Jones <[email protected]>
HID: wacom: Fix Use-After-Free in wacom_intuos_pad
Lee Jones <[email protected]>
HID: wacom: Advertise SW_MUTE_DEVICE capability prior to registration
Lee Jones <[email protected]>
HID: wacom: Use hdev->product in wacom_setup_touch_input_capabilities
Harald Freudenberger <[email protected]>
s390/zcrypt: Fix out-of-bounds ptr advance in cca_query_crypto_facility()
Heiko Carstens <[email protected]>
s390/signal: Fix incorrect return address in signal frame
Heiko Carstens <[email protected]>
s390/probes: Fix wrong opcode for cgrb fixup
Sumanth Korikkar <[email protected]>
s390/cpum_cf: Check session mask before cpu offline
Niklas Cassel <[email protected]>
ata: sata_fsl: Fix use-after-free of host_priv on probe() failure
Binbin Deng <[email protected]>
apparmor: fix a use-after-free in aa_lookupn_ns()
David Hildenbrand (Arm) <[email protected]>
mm/hugetlb: fix use-after-free in hugetlb_mfill_atomic_pte()
Deepanshu Kartikey <[email protected]>
media: imon: fix use-after-free in display_close via dev_dbg
Anuj Bolewar <[email protected]>
media: hackrf: fix use-after-free in hackrf_alloc_urbs() error path
Pei Xiao <[email protected]>
media: cx23885: Fix use-after-free in cx23885_finidev due to race condition
Fan Wu <[email protected]>
media: au0828: fix use-after-free in bulk_timeout timer on disconnect
Chuck Lever <[email protected]>
lockd: Fix use-after-free in nlmsvc_retry_blocked
Günther Noack <[email protected]>
landlock: Fix superblock use-after-free in release_inode()
Yehyeong Lee <[email protected]>
nvmet-fc: fix use-after-free in nvmet_fc_ls_create_connection()
James Kim <[email protected]>
rapidio: mport_cdev: fix use-after-free in mport_mm_close()
Henry Martin <[email protected]>
smb: client: fix use-after-free in cifs_ses_add_channel()
Diego Oliva <[email protected]>
smb: client: fix use-after-free infoleak via the readdir resume name
Zijing Yin <[email protected]>
SUNRPC: fix netns use-after-free in write_gssp()
Andreas Wendleder <[email protected]>
wifi: b43: fix use-after-free in b43_bcma_remove()
Li RongQing <[email protected]>
x86/ioperm: Prevent NULL dereference on theoretical missing IO bitmap
Kevin Cheng <[email protected]>
KVM: VMX: Synthesize nested EPT violation GVA_IS_VALID/GVA_TRANSLATED bits
Sean Christopherson <[email protected]>
KVM: x86: Tell ->inject_page_fault() whether or a fault came from hardware
Paolo Bonzini <[email protected]>
KVM: x86/mmu: pass PFERR_GUEST_PAGE/FINAL_MASK to kvm_translate_gpa
Christoph Zwerschke <[email protected]>
Revert "Bluetooth: btusb: Add ASUS USB-BT540 for Realtek 8761CU"
Christoph Zwerschke <[email protected]>
Revert "Bluetooth: btusb: Add ASUS USB-BT600 for Realtek 8761CU"
Eric Dumazet <[email protected]>
vlan: restore HW VLAN tag insertion with reorder_hdr off
Kuniyuki Iwashima <[email protected]>
tcp: Fix potential UAF in reqsk_timer_handler().
Namjae Jeon <[email protected]>
ksmbd: validate security descriptor offsets before pointer arithmetic
Karl Mehltretter <[email protected]>
ksmbd: use u8 for SMB2 oplock level values
DaeMyung Kang <[email protected]>
ksmbd: return end of file for reads past a named stream's data
Abdifatah Suruur <[email protected]>
ksmbd: reserve space for the UTF-16 terminator in stream info
DaeMyung Kang <[email protected]>
ksmbd: preserve unreadable named streams on open
Jan Koester <[email protected]>
ksmbd: ignore network devices of other namespaces
Cen Zhang (Microsoft) <[email protected]>
ksmbd: fix parent dentry lifetime in directory enumeration
Giorgi Kobakhia <[email protected]>
ksmbd: fix overflow in dacloffset bounds check in build_sec_desc()
Dairui Zhang <[email protected]>
ksmbd: fix OOB read and cross-share confusion in ksmbd_validate_name_reconnect()
Namjae Jeon <[email protected]>
ksmbd: fix extended session security negotiation for raw NTLMSSP
DaeMyung Kang <[email protected]>
ksmbd: avoid restoring only in-memory EOF after allocation change
Michail Andreas Michalopoulos <[email protected]>
ksmbd: accept share config responses from ksmbd-tools before 3.5.3
David Heidelberg <[email protected]>
backlight: qcom-wled: Fix WLED3 brightness register stride
David Heidelberg <[email protected]>
backlight: qcom-wled: Fix unbalanced OVP IRQ enable at probe
David Heidelberg <[email protected]>
backlight: qcom-wled: Fix NULL pointer dereference in wled_remove()
Myeonghun Pak <[email protected]>
backlight: lm3630a: Cancel delayed work before destroying workqueue
Kameron Carr <[email protected]>
Drivers: hv: vmbus: Bounds check the shared ring buffer indices
Johan Hovold <[email protected]>
driver core: fix parent lock use-after-free on USB disconnect
Josef Bacik <[email protected]>
driver core: Limit the messages on a refused uevent
Johan Hovold <[email protected]>
driver core: take parent lock on deferred probe
Jamal Hadi Salim <[email protected]>
net/sched: act_ife: do not consume the inner header on egress
Antonio Quartulli <[email protected]>
net/sched: fix packet reordering on requeue
owen kwan <[email protected]>
net/sched: sch_teql: fix use-after-free on lower qdisc drop
Jamal Hadi Salim <[email protected]>
net/sched: sch_teql: fix slaves_lock IRQ deadlock
Yuhang Zheng <[email protected]>
net/sched: cls_flower: avoid stale mask references after delete
Jamal Hadi Salim <[email protected]>
net/sched: cls_bpf: accept dev-bound programs on shared blocks
Hari Mishal <[email protected]>
drm/amd/display: guard dc_sink dereferences in MST mode validation
Jiakai Xu <[email protected]>
RISC-V: KVM: Fix double-free of sdata in kvm_pmu_clear_snapshot_area()
Timur Kristóf <[email protected]>
drm/amdgpu/uvd3.1: Fix checking whether UVD firmware keyselect was already set
Donggeun Yoo <[email protected]>
tracing: Fix NULL dereference when copying keys for a field variable
Pengpeng Hou <[email protected]>
tracing: Bound histogram expression strings with seq_buf
Pengpeng Hou <[email protected]>
tracing: Return ERR_PTR() from expr_str()
Pengpeng Hou <[email protected]>
tracing: Use __free() for expr_str() buffer
Tom Zanussi <[email protected]>
tracing: Fix fully-qualified variable reference printing in histograms
Christian Brauner <[email protected]>
ntfs3: free replaced mount options after a grace period
Christian Brauner <[email protected]>
ipc: drop the mqueue mount with kern_unmount() on setup failure
Vlad Kulikov <[email protected]>
ipc: create_ipc_ns: drop mqueue mount on sysctl setup failure
Dibin Moolakadan Subrahmanian <[email protected]>
drm/i915/dmc: Add sanity check for DMC load address
Bihaan Sen <[email protected]>
Input: xpad - add support for 8BitDo Pro 2 Wired Controller for Xbox
Weiming Shi <[email protected]>
net: team: free skb when broadcast has no txable port
Alexey Charkov <[email protected]>
regulator: of: fill in supply names in of_regulator_bulk_get_all()
Christian Brauner <[email protected]>
namespace: never expire a locked mount
Theo Andersen Carton <[email protected]>
drm/amdgpu: skip the noirq suspend reset for a switcheroo-parked GPU
Alex Deucher <[email protected]>
drm/amdgpu/gmc12: properly pass flush_type to gmc_v12_0_flush_vm_hub()
Pierre-Eric Pelloux-Prayer <[email protected]>
drm/amdgpu: remove gart_window_lock usage from gmc v12
Timur Kristóf <[email protected]>
drm/amd/display: Fix fast updates on DCE 6.x
Christian Brauner <[email protected]>
namespace: check a recursive bind mount for mount namespace loops
Mikulas Patocka <[email protected]>
dm-integrity: validate the superblock on resume
Paulo Alcantara <[email protected]>
smb: client: require stable pages for signed connections
Paulo Alcantara <[email protected]>
smb: client: only require read lease for size-extending zero range
Paulo Alcantara <[email protected]>
smb: client: drain and invalidate before server-side copy/clone
Paulo Alcantara <[email protected]>
smb: client: flush dirty data before zeroing a range
Paulo Alcantara <[email protected]>
smb: client: flush and commit data before querying allocated ranges
Paulo Alcantara <[email protected]>
smb: client: discard post-EOF pagecache when extending a file via clone range
Paulo Alcantara <[email protected]>
smb: client: clear post-EOF pagecache when extending a file via truncate
Yu-Hsiang Tseng <[email protected]>
ALSA: hda/realtek: Fix silent speaker on Higole F9B
Sean Christopherson <[email protected]>
KVM: SVM: Update control fields on #VMEXIT if and only if VMRUN succeeded
Sean Christopherson <[email protected]>
KVM: SVM: Preserve TLB control (i.e. pending TLB flush) on failed VMRUN
Hao Ge <[email protected]>
netfs: Fix missing alloc tagging of direct mempool allocations
Christian Brauner <[email protected]>
fs: don't silently unmount busy mounts
Ilya Maximets <[email protected]>
net/sched: act_ct: remove 'add_helper' dead code
Kendall Willis <[email protected]>
serial: 8250_omap: fix wake irq cleared during suspend
Sean Christopherson <[email protected]>
KVM: x86: Fill kvm_run exit fields in common get_nested_state_pages() error paths
Sean Christopherson <[email protected]>
KVM: x86: Re-pend GET_NESTED_STATE_PAGES if getting said pages fails
Imre Deak <[email protected]>
drm/i915/dp_mst: Fix configuring TUs for a disconnected stream
Adarsh Das <[email protected]>
smb: client: delete compound mids on send failure before unlock
David Francis <[email protected]>
drm/amdkfd: Avoid integer underflow in EOP ring size calculation.
David Francis <[email protected]>
drm/amdkfd: Avoid integer underflow with ffs in EOP ring size calc
Xiaogang Chen <[email protected]>
drm/amdkfd: Guard m->cp_hqd_eop_control setting by q->eop_ring_buffer_size
Darrick J. Wong <[email protected]>
xfs: don't cross reference rmapbt with bitmaps if they're incomplete
Tzung-Bi Shih <[email protected]>
watchdog: rzv2h: Avoid division by zero
Lad Prabhakar <[email protected]>
watchdog: rzv2h: Add support for configurable count clock source
Lad Prabhakar <[email protected]>
watchdog: rzv2h: Obtain clock-divider and timeout values from OF match data
Zongmin Zhou <[email protected]>
RISC-V: KVM: Fix sdata leak and stale snapshot_addr in snapshot_set_shmem
Xie Bo <[email protected]>
RISC-V: KVM: Propagate interrupted G-stage faults
Paulo Alcantara <[email protected]>
smb: client: fix fattr leaking on wsl_to_fattr() failure
Jonghyuk Kim(MalHyuk) <[email protected]>
drm/msm: RCU-free the scheduler-containing ring and VM objects
Kevin Wang <[email protected]>
drm/amd/pm: fix gpu metrics energy accumulator for smu 13.0.0/13.0.7
Prike Liang <[email protected]>
drm/amdgpu: skip gfx switch_power_profile during GPU reset
Alex Deucher <[email protected]>
drm/amdgpu/pm: add workload profile pause helper
Arie Miller <[email protected]>
hwmon: (asus_rog_ryujin) Synchronize HID command and report handling
Paulo Alcantara <[email protected]>
smb: client: fix file type corruption in posix_reparse_to_fattr()
Pali Rohár <[email protected]>
cifs: Rename struct reparse_posix_data to reparse_nfs_data_buffer and move to common/smb2pdu.h
Pali Rohár <[email protected]>
cifs: Remove struct reparse_posix_data from struct cifs_open_info_data
Pali Rohár <[email protected]>
cifs: Remove duplicate struct reparse_symlink_data and SYMLINK_FLAG_RELATIVE
Paulo Alcantara <[email protected]>
smb: client: fix WSL reparse point uid/gid override
Paulo Alcantara <[email protected]>
smb: client: fix uid/gid override in getattr with posix extensions
Théo Lebrun <[email protected]>
mips: select CONFIG_WEAK_REORDERING_BEYOND_LLSC from CONFIG_EYEQ
John Hubbard <[email protected]>
rust: allow clippy::as_underscore in the generated bindings
Mikulas Patocka <[email protected]>
dm-integrity: fix NULL pointer dereference when the 'R' flag is used
Ido Schimmel <[email protected]>
ipv6: udp: Create exceptions before socket matching
Ido Schimmel <[email protected]>
ipv6: Fix redirect exception creation for UDP/RAW sockets
Daehyeon Ko <[email protected]>
vsock/vmci: validate packet source for connected sockets
Yunpeng Tian <[email protected]>
smb: client: reject SetEA requests that do not fit the request buffer
Janani Sunil <[email protected]>
iio: adc: adi-axi-adc: Initialize state mutex
Guangshuo Li <[email protected]>
i2c: qcom-cci: fix autosuspend cleanup
Vladimir Zapolskiy <[email protected]>
i2c: qcom-cci: Remove overcautious disable_irq() calls
Vladimir Zapolskiy <[email protected]>
i2c: qcom-cci: Do not check return value of cci_init()
Hui Su <[email protected]>
io_uring/waitid: honor task_work cancellation
Shakeel Butt <[email protected]>
memcg: bypass the reclaim and oom killer for dying tasks once oom_reaper is done
Breno Leitao <[email protected]>
mm/kmemleak: report RCU-tasks quiescent states during the scan
Breno Leitao <[email protected]>
mm/kmemleak: stop the task stack scan early when interrupted
Eckhart Mohr <[email protected]>
ALSA: hda/realtek: Add quirk for TongFang XxAF5xxx
Eckhart Mohr <[email protected]>
ALSA: hda/realtek: Add quirk for TongFang X6SP45xU
Eckhart Mohr <[email protected]>
ALSA: hda/realtek: Add quirk for TongFang X6xx45xU
Gary Guo <[email protected]>
rust: cfi: disable function merging if CFI is enabled
Frank Sorenson <[email protected]>
cifs: add cifs_resize_file_locked() to guard fscache_resize_cookie() under i_rwsem
Yang Wang <[email protected]>
drm/amdgpu: Disable runtime PM for externally attached dGPUs
Tiezhu Yang <[email protected]>
LoongArch: Expand module virtual address space to 2GB
fangqiurong <[email protected]>
sched_ext: Fix exit_task leak on fork failure during enable
Denis Batishchev <[email protected]>
ALSA: hda/realtek: Enable micmute LED on HP EliteBook 6 G1a p/n: AD3Q9ET#UUG
Jeff Layton <[email protected]>
nfsd: use test_and_clear_bit for somebody_reclaimed to prevent lost update
Thomas Gleixner <[email protected]>
futex: Sanitize and document task_struct::futex::state transitions
Bibo Mao <[email protected]>
LoongArch: KVM: Set vcpu->cpu before IN_GUEST_MODE is set
Bibo Mao <[email protected]>
LoongArch: KVM: Deliver interrupt after IN_GUEST_MODE is set
Bibo Mao <[email protected]>
LoongArch: KVM: Check kvm_request_pending() in kvm_late_check_requests()
Bibo Mao <[email protected]>
LoongArch: KVM: Skip PMU checking on vCPU context switch
Adrian Hunter <[email protected]>
i3c: master: Fix potential UAF in i3c_device_uevent()
Guopeng Zhang <[email protected]>
mm: memcg-v1: fix wrong linux-mm list address in deprecation warnings
Keren Sun <[email protected]>
mm: remove unnecessary whitespace before a quoted newline
Thiébaud Weksteen <[email protected]>
module: validate string table section types
Matthew Maurer <[email protected]>
module: Factor out elf_validity_cache_index_str
Matthew Maurer <[email protected]>
module: Factor out elf_validity_cache_index_sym
Matthew Maurer <[email protected]>
module: Factor out elf_validity_cache_index_mod
Matthew Maurer <[email protected]>
module: Factor out elf_validity_cache_index_info
Matthew Maurer <[email protected]>
module: Factor out elf_validity_cache_secstrings
Matthew Maurer <[email protected]>
module: Factor out elf_validity_cache_sechdrs
Matthew Maurer <[email protected]>
module: Factor out elf_validity_ehdr
Stanislaw Gruszka <[email protected]>
module/kallsyms: fix nextval for data symbol lookup
Sebastian Andrzej Siewior <[email protected]>
module: Use RCU in find_kallsyms_symbol().
Jose Villaseñor Montfort <[email protected]>
HID: input: read battery capacity from its actual report offset
Dev Jain <[email protected]>
mm/migrate: use huge_ptep_get() in remove_migration_pte()
Dev Jain <[email protected]>
mm/rmap: use huge_ptep_get() in try_to_migrate_one()
Mario Limonciello <[email protected]>
platform/x86/amd/pmc: Fix msg_port restoration in amd_stb_debugfs_open_v2()
Lukas Wunner <[email protected]>
PCI/AER: Emit TLP Log only for unmasked errors
Lukas Wunner <[email protected]>
PCI/AER: Fix mapping of errors to agent & layer
Yosry Ahmed <[email protected]>
KVM: x86: Always initialize EFER reserved bits on vendor initialization
Jackson Lee <[email protected]>
media: chips-media: wave5: Resume device before setting EOS flag
Jackson Lee <[email protected]>
media: chips-media: wave5: Set inst->std during default format initialization
Sean Christopherson <[email protected]>
KVM: x86/mmu: Use split "zap all fast" helpers when invalidating memslot
Sean Christopherson <[email protected]>
KVM: SEV: Mark vCPU RUNNABLE after AP_CREATE, even if VMSA is unusable
Sean Christopherson <[email protected]>
KVM: SEV: Extract loading of guest-provided VMSA to a separate helper
Julian Haarmann <[email protected]>
platform/x86: lenovo/ymc: Only match lower byte in WMI lid switch query response
Matthew Auld <[email protected]>
drm/xe/display: skip FORCE_WC and vm_bound check for external dma-bufs
Qing Luo <[email protected]>
sctp: auth: discard auth_chunk when skb_clone fails
Pablo Neira Ayuso <[email protected]>
netfilter: nf_conntrack_expect: add and use nf_ct_expect_related_pair()
Bui Viet Dung <[email protected]>
wwan: wwan_hwsim: Pin module for debugfs file operations
Giorgi Kobakhia <[email protected]>
udf: fix return value for non-recorded-allocated extents in udf_map_block()
Jonathan Gopel <[email protected]>
thunderbolt: Do not RPM complete unrelated subtrees on unplug
Cen Zhang <[email protected]>
ocfs2: publish the filecheck owner before adding sysfs attributes
Cen Zhang <[email protected]>
ocfs2: pin owning modules for open debugfs files
Cen Zhang <[email protected]>
ocfs2: drain quorum work before removing the cluster
Cen Zhang <[email protected]>
ocfs2/dlm: drain join handlers before releasing module text
Wei Jie Law <[email protected]>
net: usb: pegasus: do not advance rx_skb->data on dropped frames
Kaho Jiang <[email protected]>
net: ipv4: add zero check for snd_cwnd_clamp
Xiang Mei <[email protected]>
media: go7007: only set audio_enabled if go7007_snd_init() succeeded
Xiang Mei <[email protected]>
media: em28xx: reject audio endpoint with zero packet size
Myeonghun Pak <[email protected]>
media: cx88: Disable PCI device on MPEG initialization failure
Xiang Mei <[email protected]>
libceph: bound mon_command ack decode to front len
Andrea Parri <[email protected]>
kcsan: Avoid division by zero in kcsan_prandom_u32_max()
Fang Xieyan <[email protected]>
kcov: ignore an out-of-range comparison count in write_comp_data()
Yuanfu Xie <[email protected]>
ceph: fail readdir when the MDS reply carries no dirfrag
Baokun Li <[email protected]>
blk-crypto: fix NULL deref and UAF in __blk_crypto_evict_key()
Rohinthan P <[email protected]>
media: em28xx: use video_unregister_device for radio_dev
Christian Brauner <[email protected]>
Revert "namei: don't reveal overmounted entries in refwalk"
Petr Mladek <[email protected]>
nbcon/reboot: Switch NBCON consoles into the emergency mode in emergency_restart()
Michael Reeves <[email protected]>
regmap: Remove debugfs before cache teardown
Matus Gajdos <[email protected]>
ALSA: usb-audio: Add native DSD support for Cambridge Audio streamers
Jaidheer Sirigineedi <[email protected]>
ALSA: hda/realtek: Add mute LED quirk for HP Pavilion 15-eg3xxx (103c:8bfd)
Miquel Raynal <[email protected]>
spi: cadence-qspi: Fix status polling with octal DTR chips
Eckhart Mohr <[email protected]>
ALSA: hda/realtek: Add quirk for ASRock NUC BOX-358H
Reinhard Speyerer <[email protected]>
net: usb: qmi_wwan: add Rolling Wireless RN947R
Vladimir Murzin <[email protected]>
usb: mtu3: Fix double dereference in TP_printk
renpanpan <[email protected]>
ALSA: hda/realtek: Add mute LED quirk for HP Pavilion 14-dv1001TU
Muhtasham Nawr al-Mahmud <[email protected]>
ALSA: hda/realtek: Fix speakers on ASUS PM3406CHA
Zhang Heng <[email protected]>
ALSA: hda/realtek: Add quirk for Acer Nitro AN515-45
Tarun Noonemunthala <[email protected]>
ALSA: hda/realtek: Add quirk for HP ENVY 13-aq1xxx
Luis Banha <[email protected]>
ALSA: hda/realtek: Add mute LED quirk for HP Pavilion 15-ec1xxx
Zhang Heng <[email protected]>
ALSA: hda/realtek: Add quirk for Lenovo ThinkBook G8+
KIM MinWoo <[email protected]>
ALSA: hda/realtek: Add quirk for Lenovo ThinkBook 16p Gen 3 ARH (21EK)
Tomasz Bojanowski <[email protected]>
ALSA: usb-audio: Add mixer mapping for MSI MAG B850M MORTAR WIFI
Hernan Ganzo <[email protected]>
ALSA: hda/realtek: Limit internal mic boost on HP Pavilion 15 (103c:2164)
Jasper Firth <[email protected]>
ASoC: Intel: bytcr_rt5651: Add quirk for Chuwi Hi8 with generic DMI strings
Daniel Ortiz <[email protected]>
ASoC: amd: yc: Add DMI quirk for Lenovo V15 G6 ARP
Andy Moreton <[email protected]>
sfc: add X4D PF support
Rosen Penev <[email protected]>
gpio: mvebu: keep resume masks within the irqchip cache
Seiji Adachi <[email protected]>
ASoC: amd: yc: Add Lenovo ThinkPad E16 Gen 2 (21JN) to quirks
Ewan D. Milne <[email protected]>
scsi: devinfo: Add BLIST_SKIP_IO_HINTS for EMC Symmetrix
Dmitry Antipov <[email protected]>
HID: roccat: fix locking in roccat_connect() and roccat_disconnect()
Maurizio Lombardi <[email protected]>
nvme-fc: do not warn on controller removal race
Youth Cao <[email protected]>
HID: i2c-hid: Add i2c-hid-quirk-bad-input-size quirk for 0911:5288 device
Namjae Jeon <[email protected]>
ksmbd: handle allocated range queries on dense files
Fernando Fernandez Mancera <[email protected]>
netfilter: tproxy: use DEBUG_NET_WARN_ON_ONCE for protocol fallbacks
Xiubo Li <[email protected]>
ceph: fix use-after-dereference of NULL ci in __ceph_remove_cap()
Mehmet Aysel <[email protected]>
ASoC: amd: acp-config: Add HVY-WXX9/M1060 DMI quirk
Bob Song <[email protected]>
ALSA: hda/conexant: Always enable the headset-mic pin on plugin
Xiubo Li <[email protected]>
ceph: do not cache negative dentries for snapped directories
Mehmet Aysel <[email protected]>
ASoC: amd: acp3x-es83xx: Add HVY-WXX9/M1060 DMI quirk
Federico Valentín Andrade <[email protected]>
ALSA: usb-audio: Skip mixer creation on M-Audio Venom
Li Jun <[email protected]>
tpm: tpm_tis_spi: fix nodef CR50 tpm_tis_spi_resume is null
Dave Carey <[email protected]>
HID: multitouch: Fix stale MT slots when contact count drops to zero
Vadim Klishko <[email protected]>
HID: i2c-hid: Add a quirk for a Cirque I2C device.
Zhang Heng <[email protected]>
ASoC: amd: yc: Add DMI entry for Alienware m18 R1 AMD
Jimmy Zuber <[email protected]>
fuse: zero the partial EOF page when extending a file
Zhang Heng <[email protected]>
ALSA: hda/realtek: Add quirk for Lenovo IdeaPad Slim 3 15ABR8
Md Rabbani <[email protected]>
net: stmmac: fix device node reference leaks in stmmac_mtl_setup()
Sumeet Pawnikar <[email protected]>
powercap: intel_rapl: Fix kernel panic during PMU unbind
Helge Deller <[email protected]>
fbcon: Fix KASAN slab-out-of-bounds Read in fbcon_prepare_logo
Shiji Yang <[email protected]>
net: ethernet: mtk_wed: increase WED v2 WDMA RESV_BUFF to 0x80
Jenson Johnathon Reggentin <[email protected]>
docs: block: fix dead http link in blk-mq.rst
Chen Changcheng <[email protected]>
scsi: snic: Fix SCSI host leak on workqueue allocation failure
Will Porter <[email protected]>
ALSA: usb-audio: Add iD14 MkI to monitor-mix volume quirk
Csaba Budai <[email protected]>
ALSA: hda/realtek: Fix ALC700 audio on Intel Hades Canyon
Daeho Jeong <[email protected]>
f2fs: avoid setting SBI_NEED_FSCK on transient resize failure
Robin Everaars <[email protected]>
ACPI: button: Add DMI quirk for Razer Blade Pro 17 early 2020 lid switch
Tao Cui <[email protected]>
sched_ext/scx_flatcg: expire cached hweights on weight changes
Namjae Jeon <[email protected]>
ksmbd: enable TCP keepalive for accepted connections
BingKun Yue <[email protected]>
fbdev: platinumfb: add error checking for ioremap calls
Randy Dunlap <[email protected]>
fbdev: maxine: fix 64-bit build error
Carlos Song <[email protected]>
i2c: imx-lpi2c: properly unwind resources on probe failure
Pengpeng Hou <[email protected]>
rtc: brcmstb-waketimer: add missing MODULE_DEVICE_TABLE()
Robert Leussler <[email protected]>
rtc: ds1307: fix RX8130 wakeup alarm WADA bit for day-of-month mode
Jack Yu <[email protected]>
ASoC: rt712-sdca: Pull high JD2 to prevent from entering TV mode
Jinqian Yang <[email protected]>
virtio_ring: fix infinite loop in virtnet_poll_cleantx when device is broken
Pengpeng Hou <[email protected]>
rtc: ab-eoz9: add missing MODULE_DEVICE_TABLE()
Denis V. Lunev <[email protected]>
virtio_balloon: warn on failed buffer add in tell_host()
Weimin Xiong <[email protected]>
vdpa/mlx5: roll back MR update after VQ setup failure
Gilles Risch <[email protected]>
drm/radeon: fix internal display on iMac11, 1 (RV770/DCE3.1)
Xiong Weimin <[email protected]>
vdpa_sim: hold iommu_lock across dma_unmap passthrough transition
Kuninori Morimoto <[email protected]>
ASoC: codec: max98926: fixup invert setup mask
Andrew Onyshchuk <[email protected]>
platform/x86: thinkpad_acpi: Fix fan speed reporting on Edge E330
Yaroslav Dudkov <[email protected]>
platform/x86: msi-ec: Add MSI Katana GF76 11UEK EC firmware
Alex Elder <[email protected]>
net: stmmac: use dma_addr_t for DMA addresses
Jia Zhu <[email protected]>
NFSv4: pin the superblock for active state owners
ZhangGuoDong <[email protected]>
NFS: Verify symlink inode before caching target
Thomas Huth <[email protected]>
smb: server: Free session data in user_session.c with kfree_sensitive()
Namjae Jeon <[email protected]>
ksmbd: notify parent directory leases on child create
Benjamin Coddington <[email protected]>
pNFS: honor clora_changed when recalling a layout
Thomas Huth <[email protected]>
smb: server: Make sure that passkey is not leaked on the heap in user_config.c
Namjae Jeon <[email protected]>
ksmbd: honor client signing-required in all modes
Namjae Jeon <[email protected]>
ksmbd: reject blocking compound lock requests
Gael Blivet <[email protected]>
ksmbd: fix AsyncId zeroed before use in smb2_lock() cancel response
Namjae Jeon <[email protected]>
ksmbd: fix SMB2 byte-range lock end offset
Yashraj Ghule <[email protected]>
ALSA: hda/realtek: Fix mute LED for HP Victus 15-fa1xxx (MB 8C3F)
ChenXiaoSong <[email protected]>
smb/server: cancel async requests when closing connection
Gael Blivet <[email protected]>
ksmbd: report actual xattr value length in stream enumeration
Gael Blivet <[email protected]>
ksmbd: skip fallocate for SMB2_CREATE_ALLOCATION_SIZE on a stream handle
Namjae Jeon <[email protected]>
ksmbd: allow FSCTL_SET_SPARSE without input buffer
Namjae Jeon <[email protected]>
ksmbd: honor byte-range locks for zero data
Namjae Jeon <[email protected]>
ksmbd: handle empty QUERY_ALLOCATED_RANGES output
Namjae Jeon <[email protected]>
ksmbd: return buffer too small for short security queries
Gael Blivet <[email protected]>
ksmbd: fix off-by-one rejecting minimal COPYCHUNK query-limits request
Namjae Jeon <[email protected]>
ksmbd: reject SMB3.1.1 binding with mismatched cipher
Gael Blivet <[email protected]>
ksmbd: fix durable handle v2 default timeout units (60 -> 60000)
Namjae Jeon <[email protected]>
ksmbd: allow I/O on directory named streams
Namjae Jeon <[email protected]>
ksmbd: preserve access denied status for copychunk
Namjae Jeon <[email protected]>
ksmbd: protect private extended attributes
David C.C.M. Gall <[email protected]>
crypto: keembay - use crypto_memneq() to compare CCM AEAD tags
Israel Téllez García <[email protected]>
libbpf: Fix ring buffer consumer loop on 32-bit position wrap
David C.C.M. Gall <[email protected]>
crypto: sa2ul - use crypto_memneq() to compare AEAD tag
David C.C.M. Gall <[email protected]>
crypto: keembay - use crypto_memneq() to compare GCM AEAD tags
Eric Dumazet <[email protected]>
gre: fix ERSPAN o_flags race/corruption in xmit and fill_info
Yang Wen <[email protected]>
exfat: keep FITRIM within the requested range
Anuj Bolewar <[email protected]>
drm/virtio: reclaim pending vbufs before tearing down vqs
Basavaraj Natikar <[email protected]>
HID: amd_sfh: Serialize access to the shared emp2 pointer
Neil Andrews <[email protected]>
ALSA: usb-audio: Rename the Audient iD14 monitor mix volume control
Takashi Iwai <[email protected]>
ALSA: hda/intel: Add sanity check for BAR0 size
Farhan Ali <[email protected]>
PCI: Avoid saving config space state if inaccessible
Michail Tatas <[email protected]>
ipmi: Fix leak in __ipmi_bmc_register
Charles Keepax <[email protected]>
soundwire: dmi-quirks: Disable ghost Realtek on Asus ROG Zephyrus Duo
Arash Golgol <[email protected]>
regulator: fan53555: Add support for FAN53555BUC23X type
Jiaming Zhang <[email protected]>
hfsplus: validate extent record length before writing it back
Dmytro Moroziuk <[email protected]>
ALSA: hda/conexant: Add mute LED quirk for HP ProBook 440 G5
Matt Turner <[email protected]>
alpha: run the remote RTC access in a worker, not an IPI callback
Chao Shi <[email protected]>
nvme: ratelimit the completion-path messages driven by device data
Griffin Kroah-Hartman <[email protected]>
nfc: nxp-nci: Add remove on IRQ error
Griffin Kroah-Hartman <[email protected]>
nfc: mrvl: spi: Unregister dev on allocation fail
Vasant Hegde <[email protected]>
iommu/amd: Fix missing CMD_COMPLETE_PPR response for invalid PPR requests
Feng Tang <[email protected]>
selftests: net: reuseport_bpf_numa: consider cpuless numa node
John Johansen <[email protected]>
apparmor: fix auditing of mount binary data
Rongguang Wei <[email protected]>
tap: fix incorrect variable used for USO check in set_offload()
Geliang Tang <[email protected]>
nvme-tcp: look up host_iface in the current netns
Zhe Liu <[email protected]>
docs: cgroup-v2: fix stale "io" controller introduction
Brian Grech <[email protected]>
selftests/net: fin_ack_lat: fix latency threshold typo
Hari Mishal <[email protected]>
nvmet: passthru: fix OOB reads when parsing ns id descriptor list
Dapeng Mi <[email protected]>
perf/x86: Free hybrid state on PMU init failure
Dapeng Mi <[email protected]>
perf/x86: Unregister PMI handler on PMU init failure
Michal Pecio <[email protected]>
ALSA: usx2y: Stop clearing urb->hcpriv before submission
Guanghui Feng <[email protected]>
iommu/vt-d: Fix CACHE_TAG_NESTING_DEVTLB polluting shared variables in flush loop
Pengpeng Hou <[email protected]>
fbdev: udlfb: validate vendor descriptor items
Andreas Kemnade <[email protected]>
fbdev: omap2: dsi: do not copy isr table
Atish Patra <[email protected]>
RISC-V: perf: fix resource cleanup on driver probe failure
Rui Qi <[email protected]>
riscv: kprobes: Prevent probes in breakpoint handlers
Daniel Golle <[email protected]>
net: dsa: mt7530: check CORE_PLL_GROUP4 access in mt7531_setup()
Daniel Golle <[email protected]>
net: pcs: mtk-lynxi: check regmap reads in mtk_pcs_lynxi_get_state()
Daniel Golle <[email protected]>
net: dsa: mt7530: check bus->read() error in core_rmw()
Laxman Acharya <[email protected]>
Bluetooth: hci_event: fix out-of-bounds read in LE PA report reassembly
Daniel Golle <[email protected]>
net: dsa: mt7530: error out on failed PHY_IAC command writes
Muhammad Saheed <[email protected]>
Bluetooth: hci_sync: Disable legacy instance's ext adv before setup snapshot
Li Qiang <[email protected]>
Bluetooth: hci_bcsp: validate received packet lengths
Chen Changcheng <[email protected]>
Bluetooth: btrsi: Move set_bt_context after successful HCI registration
Garrett Blackmon <[email protected]>
ALSA: hda/realtek: Fix speakers on ASUS ROG Zephyrus G14 GA403UM
Zhang Heng <[email protected]>
ALSA: hda/realtek: Fix headset mic on ASUS Vivobook S14 S5406SA
Junhao He <[email protected]>
ACPI: APEI: Handle repeated SEA error storms
Aurabindo Pillai <[email protected]>
drm/amd: Add DCN6 register headers
Filipe Manana <[email protected]>
btrfs: fix memory barrier order in reloc_root_is_dead()
Pengpeng Hou <[email protected]>
Bluetooth: hci_nokia: validate firmware packet bounds
Pavel Zverev <[email protected]>
Bluetooth: btusb: Add support for 1357:c123 Realtek 8852BE device
Rui Qi <[email protected]>
selftests/ftrace: Force C locale in ftracetest
Andreas Haufler <[email protected]>
tools/lib/thermal: Fix misplaced extern "C" closing brace
Yunye Zhao <[email protected]>
md: add cond_resched() to md_do_sync()'s skip path
Yu Kuai <[email protected]>
md/raid5: reject zero-sector reshape chunks
Shang En Sim <[email protected]>
ALSA: hda/realtek: Enable mute LEDs on HP Spectre x360 16-aa0xxx
Junzhe Yu <[email protected]>
ext4: guard against NULL s_group_info in ext4_get_group_info
Pengpeng Hou <[email protected]>
HID: rmi: check report length before trimming sentinel bytes
liulhong617 <[email protected]>
arm64: mm: fix accidental linear mapping of no-map reserved memory
Stefan Hansson <[email protected]>
wifi: rsi: Fix types to appease CFI
Charles Keepax <[email protected]>
soundwire: dmi-quirks: Disable ghost Realtek on Asus Zenbook Duo
Praveen Talari <[email protected]>
opp: Use clk_get_optional() to avoid leaving opp_table->clk as an error pointer
Carl Quist <[email protected]>
ALSA: hda/realtek: Enable mute LED on HP Laptop 15-dy0xxx
Zihan Xi <[email protected]>
xsk: account ring allocations to memcg
Jinhui Guo <[email protected]>
net: usb: cdc_ether: add quirk for AMI BMC stale link events
Johan Alvarado <[email protected]>
net: stmmac: raise TX completion interrupt at the end of an xmit burst
Felix Fietkau <[email protected]>
wifi: mt76: mt7603: file buffered frames under the TID reported to mac80211
Marcos Paulo Medeiros <[email protected]>
ACPI: video: force native backlight on Acer Nitro AN515-46
Stefan Haberland <[email protected]>
s390/dasd: Snapshot intrc before freeing the request block
Simon Glass <[email protected]>
kconfig: abort rather than loop for ever on EOF
Allison Henderson <[email protected]>
net/rds: unpin MR pages with unpin_user_pages_dirty_lock()
Sharath Srinivasan <[email protected]>
net/rds: fix rds_message leak in the rds_send_xmit() drop path
Håkon Bugge <[email protected]>
net/rds: hold the socket while an rds_mr references it
Allison Henderson <[email protected]>
net/rds: don't use unpin_user_pages_dirty_lock() from atomic context
Wahid Khan <[email protected]>
HID: intel-ish-hid: ignore post-init ENUM_DEVICES from firmware
Yuxiang Lin <[email protected]>
HID: quirks: add ALWAYS_POLL quirk for AULA Mini 60 HE Pro Dongle
Aaron Ma <[email protected]>
HID: quirks: Add ALWAYS_POLL quirk for Beitong BTP-KP20D dongle
Stuart Hayhurst <[email protected]>
HID: logitech-hidpp: Add support for G502 X Plus USB mouse
Mauricio Orozco <[email protected]>
ALSA: hda/realtek: Add quirk for ASUS VivoBook M515DA/X515DAP
Mariano Baragiola <[email protected]>
wifi: wilc1000: validate monitor transmit frame headers
Can Peng <[email protected]>
wifi: brcmfmac: validate msgbuf flowring IDs before use
Can Peng <[email protected]>
wifi: brcmfmac: Set DMA direction for msgbuf packet IDs
Felix Fietkau <[email protected]>
wifi: mt76: mt7603: fix U-APSD service period termination
Felix Fietkau <[email protected]>
wifi: mt76: set the EOSP bit in the QoS header of the last released frame
Felix Fietkau <[email protected]>
wifi: mt76: mt7615: fix NULL deref in mt7615_mac_set_rates
Peter Ujfalusi <[email protected]>
ASoC: SOF: Intel: mtl: Power down DSP if it is left enabled in pre_fw_run()
ZhaoJinming <[email protected]>
wifi: ath11k: fix resource leak on error in ext IRQ setup
Geetha sowjanya <[email protected]>
perf: marvell: Cancel CN10K DDR PMU hrtimer on device remove
Pablo Neira Ayuso <[email protected]>
netfilter: nf_tables: call skb_valid_dst() before skb_dst()
Minghao Zhang <[email protected]>
netfilter: conntrack: tcp: use UNACK timeout for non-closing RST packets
Ahmed Naseef <[email protected]>
wifi: mt76: mt7603: add 0x7592 EEPROM chip ID
Prashant Rahul <[email protected]>
wifi: mt76: mt7921: fix memory leak when skb_linearize fails in mcu rx event
David Bauer <[email protected]>
wifi: mt76: mt7915: configure noise floor reporting on reset
Devin Wittmayer <[email protected]>
wifi: mt76: mt76x02: report rx FCS errors to mac80211
David Bauer <[email protected]>
wifi: mt76: mt7603: free beacon SKB on error
Hari Mishal <[email protected]>
virtio_console: take a kref in find_port_by_vq() to fix port UAF
Rosen Penev <[email protected]>
nvmem: brcm_nvram: fix out-of-bounds access on malformed flash data
Rosen Penev <[email protected]>
nvmem: brcm_nvram: reject empty NVRAM partition
이상호 <[email protected]>
romfs: detect hard link cycles
bui duc phuc <[email protected]>
regulator: rt6245: Restore state on enable failure
Oleg Proshkin <[email protected]>
mfd: axp20x: Preserve other control bits when powering off
Bob Song <[email protected]>
ALSA: hda/realtek: add missing error checks for COEF index reads in alc269
Dmitry Torokhov <[email protected]>
mfd: ipaq-micro: Fix out-of-bounds stack read in ipaq_micro_str
Konstantin Komarov <[email protected]>
fs/ntfs3: Fix memory leak in indx_find_sort()
Bob Song <[email protected]>
ALSA: hda/realtek: add missing NULL check for codec->bus->pci
Yichong Chen <[email protected]>
exfat: free new directory cluster if zeroing fails
Armin Wolf <[email protected]>
platform/x86: dell-smbios-wmi: Fix chardev resource management
wangdicheng <[email protected]>
ALSA: hda/conexant: Add NULL check for dc_mode_path
Yichong Chen <[email protected]>
exfat: clean up new entry on add entry failure
David Strahan <[email protected]>
scsi: smartpqi: Add new PCI device-ids
Gary Guo <[email protected]>
ata: ata_generic: Don't store pci_device_id
Dmitry Osipenko <[email protected]>
clk: tegra: support 48MHz clock for pll_p_out1
Chen Changcheng <[email protected]>
media: cx88: fix memory leak in cx8802_register_driver() error path
Pengpeng Hou <[email protected]>
clk: imx: imx8qxp-lpcg: add missing MODULE_DEVICE_TABLE()
Pengpeng Hou <[email protected]>
clk: imx: imx8qxp: add missing MODULE_DEVICE_TABLE()
Nicolin Chen <[email protected]>
iommu/tegra241-cmdqv: Rate-limit the error ISR's log message
Yichong Chen <[email protected]>
exfat: write moved entry before removing source
Jay Vadayath <[email protected]>
udf: bound lengthAllocDescs from unallocated space entry
Jan Kara <[email protected]>
udf: Fix bh leak for unallocated space entries
Tyrel Datwyler <[email protected]>
scsi: ibmvfc: free ibmvfc_target allocations with mempool_free
Tyrel Datwyler <[email protected]>
scsi: ibmvfc: check for NULL evt in implicit LOGO and target delete path
Jiaxing Hu <[email protected]>
iommu/rockchip: Clear stale page faults before enabling stall
Pengpeng Hou <[email protected]>
hsi: omap_ssi: remove debugfs on port creation failure
Tomer Maimon <[email protected]>
pinctrl: npcm8xx: move GPIO IRQ setup into request_resources
Tomer Maimon <[email protected]>
pinctrl: npcm8xx: fix debounce register selection
Tomer Maimon <[email protected]>
pinctrl: npcm8xx: clear pending GPIO events during init
Tomer Maimon <[email protected]>
pinctrl: npcm8xx: enable RMII outputs from RMII groups
Pengpeng Hou <[email protected]>
firmware: imx: scu: manage mailbox channels and global handle
Abdun Nihaal <[email protected]>
platform/x86: int1092: Fix info leak in parse_package()
Konstantin Komarov <[email protected]>
fs/ntfs3: load ATTR_BITMAP run extents from $MFT extension records
Senjin <[email protected]>
fs/ntfs3: fix lseek EINVAL on sparse/compressed files with 64-bit clusters
Konstantin Komarov <[email protected]>
ntfs3: fix info-leak in ntfs_rename()
Kyle Zeng <[email protected]>
fs/ntfs3: reserve NUL byte when converting UTF-16 names
Brian Norris <[email protected]>
PCI/portdrv: Allow probing even without child services
Ruoyu Wang <[email protected]>
ntfs3: initialize err in attr_wof_frame_info
Pengpeng Hou <[email protected]>
soc: ixp4xx: qmgr: add missing MODULE_DEVICE_TABLE()
Randolph Sapp <[email protected]>
drm/etnaviv: force flush on power register ops
Rosen Penev <[email protected]>
ata: pata_ep93xx: fix PIO fallback when DMA init fails
Benjamin Marzinski <[email protected]>
bitops: make the *_bit_le functions use unsigned long
Zhang Yi <[email protected]>
ext4: use FGP_WRITEBEGIN for tail block zeroing
Zhang Yi <[email protected]>
ext4: check return value of ext4_get_block() in ext4_load_tail_bh()
Alexander Wilhelm <[email protected]>
wifi: ath12k: fix scan command endianness on big endian
Manikanta Pubbisetty <[email protected]>
wifi: ath10k: trigger hardware recovery upon rx failures
Pengpeng Hou <[email protected]>
wifi: ath11k: validate regulatory capability phy_id
Mukesh Ojha <[email protected]>
iommu/qcom: Publish pgtbl_ops before releasing init_mutex
Pengpeng Hou <[email protected]>
thermal: intel: int340x: clean up RFIM groups on DVFS failure
Mukesh Ojha <[email protected]>
iommu/qcom: Enable clocks before hardware access in qcom_iommu_ctx_probe()
Mukesh Ojha <[email protected]>
iommu/qcom: Check pm_runtime_resume_and_get() return in probe
Heiko Schocher <[email protected]>
drm/panel: simple: Add Kyocera tcg070wvlq panel
Esteban Urrutia <[email protected]>
iommu/arm-smmu-qcom: Add SM8450 MDSS compatible
Baokun Li <[email protected]>
ext4: reject mount if clusters/inodes per group are not 8-aligned
Lachlan Hodges <[email protected]>
wifi: cfg80211: include cf1 offset when sending chandef
Kuan-Wei Chiu <[email protected]>
riscv, bpf: Add support for BPF_MOVSX in RV32 JIT
Pengpeng Hou <[email protected]>
power: reset: piix4-poweroff: add missing MODULE_DEVICE_TABLE()
Yuyang Huang <[email protected]>
net: prestera: ignore duplicate RIF destruction events
Aleksander Jan Bajkowski <[email protected]>
net: sfp: add quirk for HORACO copper SFP+ module
Pengpeng Hou <[email protected]>
power: supply: cros_pchg: unregister EC notifier
Kuan-Wei Chiu <[email protected]>
riscv, bpf: Add support for BPF_SDIV and BPF_SMOD in RV32 JIT
Thomas Renninger <[email protected]>
ACPI: sysfs: Properly map BERT and CCEL data to their ACPI tables
Zhao Li <[email protected]>
wifi: mac80211_hwsim: clear PMSR request state on abort
Shahar Tzarfati <[email protected]>
wifi: mac80211: ibss: read deauth reason_code after frame length check
Yun Zhou <[email protected]>
ext4: set EXT4_STATE_NO_EXPAND in ext4_evict_inode
Ali Alaei <[email protected]>
PCI: vmd: Handle BUS_RESTRICT_CFG value 3 for Arrow Lake-HX
Baokun Li <[email protected]>
ext4: reduce max cluster size to match documented 256MB limit
Kate Hsuan <[email protected]>
ACPI: battery: Sanitise model_number by dropping unprintable characters
Pengpeng Hou <[email protected]>
ACPI: FPDT: validate table and record lengths
Bob Song <[email protected]>
ALSA: hda: Check snd_hda_power_pm construct error before executing verb
Nizar Al-Kabbani <[email protected]>
platform/x86: asus-nb-wmi: map ProArt key (0x8b) to KEY_PROG3
Yousef Alhouseen <[email protected]>
media: go7007: s2250: propagate control I/O failures
Rituparna Warwatkar <[email protected]>
media: dvb-core: fix feed leak on failed DMX_ADD_PID
Emmanuel Grumbach <[email protected]>
wifi: iwlwifi: mvm: ignore sync frames when sync is disabled
Aditya Sherawat <[email protected]>
drm/msm/adreno: Add support for A704 GPU
Yuho Choi <[email protected]>
driver core: attribute_container: Unwind device_add() on attr failure
Logan Gunthorpe <[email protected]>
PCI: switchtec: Add Microchip PCI1008 to NTB DMA alias quirk
Logan Gunthorpe <[email protected]>
PCI: switchtec: Add Microchip PCI1008 device ID
Yousef Alhouseen <[email protected]>
misc: ibmvmc: reject oversized inbound messages
Pei Xiao <[email protected]>
ipack: ipoctal: add rwsem to guard against TOCTOU in remove path
Yousef Alhouseen <[email protected]>
misc: ibmvmc: release send buffer on write errors
Pengpeng Hou <[email protected]>
greybus: manifest: validate string descriptor header
Yousef Alhouseen <[email protected]>
misc: hpilo: validate device queue entries before use
Yousef Alhouseen <[email protected]>
misc: genwqe: handle a first DMA address of zero
Yousef Alhouseen <[email protected]>
misc: bcm-vk: validate write size before allocation
Ian Abbott <[email protected]>
comedi: pcmuio: Add sanity check to interrupt handler
Ian Abbott <[email protected]>
comedi: pcm816: Fix sanity check in interrupt handler
Ian Abbott <[email protected]>
comedi: pcmmio: Add sanity check to interrupt handler
Ian Abbott <[email protected]>
comedi: aio_iiro_16: Add sanity check to interrupt handler
Ian Abbott <[email protected]>
comedi: pcm711: Fix sanity check in interrupt handler
Ian Abbott <[email protected]>
comedi: dt2811: Fix sanity check in interrupt handler
Ian Abbott <[email protected]>
comedi: das6402: Add sanity check to interrupt handler
Ian Abbott <[email protected]>
comedi: quatech_daqp_cs: Fix sanity check in interrupt handler
Ian Abbott <[email protected]>
comedi: pcm818: Fix sanity check in interrupt handler
Ian Abbott <[email protected]>
comedi: ni_at_a2150: Fix sanity check in interrupt handler
Ian Abbott <[email protected]>
comedi: ni_atmio16d: Add sanity check to interrupt handler
Pengpeng Hou <[email protected]>
uio: sercos3: add missing MODULE_DEVICE_TABLE()
Michail Tatas <[email protected]>
USB: misc: uss720: Fix leak in get_1284_register
Oliver Neukum <[email protected]>
usb: misc: cypress_cy7c63: check result of IO
Lucas Martins Alves <[email protected]>
usb: musb: host: clear stale RX interrupt on three-strikes error
Hans Verkuil <[email protected]>
media: cec/core: drop cec_post_state_event call
Hans Verkuil <[email protected]>
media: cec: tegra_cec: don't break off msg on NACK
Shivaprasad G Bhat <[email protected]>
scsi: qla2xxx: Handle INTx not connected while passing through
Mikko Perttunen <[email protected]>
gpu: host1x: Wait for timeout worker completion on channel free
Namhyung Kim <[email protected]>
tools/lib/api: Fix potential double-free from fdarray__grow()
Emmanuel Grumbach <[email protected]>
wifi: iwlwifi: mvm: reset the smart fifo state upon FW stop
Jingyi Wang <[email protected]>
remoteproc: core: cancel crash_handler work in rproc_add() error path
Jingyi Wang <[email protected]>
remoteproc: qcom: Check subdev start status in rproc_stop()
Yousef Alhouseen <[email protected]>
media: go7007: avoid undefined shifts in MPEG-4 headers
Pengpeng Hou <[email protected]>
media: cx18: stop VBI start-code scan before short tail
Pengpeng Hou <[email protected]>
media: ivtv: stop VBI start-code scan before short tail
Jurison Murati <[email protected]>
media: i2c: ov8865: Program the sensor on stream start
Lucas Stach <[email protected]>
drm/etnaviv: check all modules for idle after reset
Jurison Murati <[email protected]>
media: i2c: ov8865: Drop the runtime PM usage count on stream failure
Haoxiang Li <[email protected]>
iwlwifi: dvm: add missing cleaup for on error path
Hari Mishal <[email protected]>
nvme: bound ns descriptor header and body to identify buffer
Charles Keepax <[email protected]>
soundwire: intel_auxdevice: Add cs42l44 to wake_capable_list
Bard Liao <[email protected]>
soundwire: dmi-quirks: add a global ghost list
Niranjana Vishwanathapura <[email protected]>
drm/xe: only resume exec queues that were actually suspended
Hans Verkuil <[email protected]>
media: em28xx: use vb2_video_unregister_device
Hans Verkuil <[email protected]>
media: em28xx: requeue buffers if start_streaming fails
Hans Verkuil <[email protected]>
media: em28xx: dev_info->pr_info since dev has been freed
Mike Tipton <[email protected]>
pmdomain: qcom: rpmhpd: Skip retention by default
Pengpeng Hou <[email protected]>
gpio: vf610: add missing MODULE_DEVICE_TABLE()
Pengpeng Hou <[email protected]>
crypto: keembay - add missing MODULE_DEVICE_TABLE()
Pengpeng Hou <[email protected]>
pinctrl: sx150x: add missing MODULE_DEVICE_TABLE()
Gabriel Prostitis <[email protected]>
USB: gadget: inode: fix mm lifetime handling
David Laight <[email protected]>
usb_string_copy: Use kzalloc() to avoid leaking old data
Xu Rao <[email protected]>
usb: gadget: u_audio: clean up capture endpoint on feedback failure
Haoxiang Li <[email protected]>
usb: fsl_qe_udc: check qe_alloc_request() failure in ch9getstatus()
Aniket Randive <[email protected]>
serial: qcom_geni: Disable closing_wait for console to prevent shutdown timeout
Haoxiang Li <[email protected]>
tty: serial: pch_uart: add check for pci_get_slot()
Rahul Bukte <[email protected]>
serial: 8250: force synchronous probe for the ISA and PNP drivers
Xu Rao <[email protected]>
mmc: block: reject invalid perdev_minors before division
Arnd Bergmann <[email protected]>
media: v4l2-tpg: reduce stack usage for kasan builds
Pengpeng Hou <[email protected]>
media: cec: tegra: add missing MODULE_DEVICE_TABLE()
Chris Lew <[email protected]>
rpmsg: char: Check for ongoing chrdev destroy
Pranjal Shrivastava <[email protected]>
PCI/ATS: Ensure pci_ats_supported() is PF-aware for VFs
Pengpeng Hou <[email protected]>
ASoC: codecs: max98396: Unwind supplies on resume failure
Qingtao Cao <[email protected]>
bus: mhi: core: Fix sys error transition latency
John Garry <[email protected]>
nvme: don't reference NS after unlocking in nvme_ns_head_ctrl_ioctl()
Alex Deucher <[email protected]>
drm/amdgpu/gfx11: WARN() rather than BUG() for invalid SDMA engine
Alex Deucher <[email protected]>
drm/amdgpu/atomfirmware: WARN() rather than BUG()
Deepanshu Kartikey <[email protected]>
udf: avoid recursive s_alloc_mutex deadlock when freeing AED blocks
Kyle Zeng <[email protected]>
udf: validate extent partition references in udf_current_aext()
Devansh Soni <[email protected]>
staging: rtl8723bs: fix missing unregister_netdev on sdio_alloc_irq failure
Xixin Liu <[email protected]>
nvme: zns: cap zone report nr_zones by DMA buffer size
Xixin Liu <[email protected]>
nvme-auth: use crypto_memneq for DH-HMAC-CHAP response comparison
John Garry <[email protected]>
nvme: handle positive error codes in nuse_show()
Tanmay Shah <[email protected]>
remoteproc: core: Full attach detach during recovery
Jerome Brunet <[email protected]>
clk: sunxi-ng: fix ccu probe clock unregister on error
Marek Szyprowski <[email protected]>
mmc: dw_mmc: stop and complete DMA also in STATE_DATA_BUSY state
Pengpeng Hou <[email protected]>
mmc: sdhci-of-ma35d1: add missing MODULE_DEVICE_TABLE()
Ben Dooks <[email protected]>
mmc: cqhci: fix to missed endian conversions
Pengpeng Hou <[email protected]>
mmc: moxart: report DMA completion timeout
Pengpeng Hou <[email protected]>
gpio: sifive: add missing MODULE_DEVICE_TABLE()
David Heidelberg <[email protected]>
dt-bindings: arm: qcom,ids: Add SoC ID for Snapdragon SDM 850
Zhiwei Zhang <[email protected]>
RDMA/rxe: Check PDs for memory window binds
David Heidelberg <[email protected]>
soc: qcom: socinfo: Add SoC ID for SDM850
Pengpeng Hou <[email protected]>
iio: adc: max1241: add missing MODULE_DEVICE_TABLE()
Yun Zhou <[email protected]>
block: reject block device inodes with i_rdev == 0 in lookup_bdev()
Chin-Yen Lee <[email protected]>
wifi: rtw89: wow: add QoS control field to WoWLAN ARP response for MLO
William Hansen-Baird <[email protected]>
wifi: rtlwifi: fix disabling of ASPM for RTL8723BE with AER flooding
Chih-Kang Chang <[email protected]>
wifi: rtw89: wow: only WiFi 6 chips initialize RF registers in WoWLAN mode
William Hansen-Baird <[email protected]>
wifi: rtlwifi: rtl8723be: Remove unnecessary irq save/restore in hw_init()
Ben Dooks <[email protected]>
dmaengine: dw-axi-dmac: fix __le32 on set of CH_CTL_H_LLI_VALID
Yun Zhou <[email protected]>
net: mvneta_bm: add suspend/resume support to prevent crash after resume
Pengpeng Hou <[email protected]>
dmaengine: pl330: remove debugfs file on teardown
Charles Keepax <[email protected]>
soundwire: dmi-quirks: Disable ghost Realtek on Asus Expertbook
Jiayuan Chen <[email protected]>
netfilter: ebtables: bound num_counters like nentries in do_replace()
Yousef Alhouseen <[email protected]>
net: usb: rtl8150: handle link status read failures
Yuan Chen <[email protected]>
libbpf: Skip bpf_object__probe_loading() when BPF token is in use
Haikun Zhou <[email protected]>
drm/panel-edp: Support MB116AS01'3 edp panel
Eric Huang <[email protected]>
drm/amdkfd: add sanity check in svm_range_is_valid
Yang Wang <[email protected]>
drm/amd/pm: Validate legacy hwmgr PP table offsets
Yang Wang <[email protected]>
drm/amd/pm: Validate Vega10 PPTable subtable bounds
Yang Wang <[email protected]>
drm/amd/pm: Validate Tonga PPTable subtable bounds
Xiang Liu <[email protected]>
drm/amd/pm: Guard VBIOS AC timing table walk
Yang Wang <[email protected]>
drm/amd/pm: Validate Tonga PowerPlay state array bounds
Yang Wang <[email protected]>
drm/amd/pm: Use uploaded size for legacy custom PPTable
Yang Wang <[email protected]>
drm/amd/pm: Validate pp_table header before reading size
Yang Wang <[email protected]>
drm/amd/pm: Validate Vega hwmgr PowerPlay table bounds
Lijo Lazar <[email protected]>
drm/amdgpu: Guard reads in pcie state readout
Matthew Jacob <[email protected]>
drm/amdgpu: Support some Barco AMD based graphics adapters
Lijo Lazar <[email protected]>
drm/amd/pm: validate vega10 profile mode inputs
Lijo Lazar <[email protected]>
drm/amdgpu: Validate ATIF buffer length before use
Lijo Lazar <[email protected]>
drm/amdgpu: Add checks to vbios fetch through ATRM
Abhijeeth Babu <[email protected]>
i2c: acpi: Force ELAN1300 touchpads to 100 kHz
Nicolas Escande <[email protected]>
wifi: ath12k: avoid setting 320MHz support on non 6GHz band
Jiawen Liu <[email protected]>
spi: bcmbca-hsspi: return error from failed controller suspend
Jiawen Liu <[email protected]>
spi: nxp-fspi: disable runtime PM on probe failures
Damon Ding <[email protected]>
drm/panel-edp: Add BOE NE160QDM-NY1 panel
Jiawen Liu <[email protected]>
spi: bcm63xx-hsspi: return error from failed controller suspend
Jiawen Liu <[email protected]>
spi: bcm63xx: return error from failed controller suspend
Jiawen Liu <[email protected]>
spi: bcm-qspi: return error from failed controller suspend
Zide Chen <[email protected]>
perf/x86/intel/uncore: Fix PCI PMU cleanup on setup failure
Zizhi Wo <[email protected]>
fat: reject name longer than NAME_MAX in msdos_format_name()
Dapeng Mi <[email protected]>
perf/x86/intel: Fallback to sw branch type decoding if no hw decoding
Bryam Vargas <[email protected]>
iio: accel: fxls8962af: clamp the device-reported FIFO sample count
Mithil Bavishi <[email protected]>
ARM: OMAP2+: Add CFI type for omap4_finish_suspend
Uwe Kleine-König (The Capable Hub) <[email protected]>
regmap: maple: Workaround for another false-positive compiler warning
Haoxiang Li <[email protected]>
ASoC: hdac_hdmi: Fix resource cleanup on probe failure
Pengpeng Hou <[email protected]>
ASoC: tlv320aic26: remove keyclick sysfs file
William Theesfeld <[email protected]>
clk: zynq: handle kasprintf() failure in periph_clk registration
Pengpeng Hou <[email protected]>
ASoC: sma1303: remove fault-check sysfs group on remove
Kemeng Shi <[email protected]>
irqdomain: Plug leak in irq_domain_alloc_irqs_locked() error path
Pengpeng Hou <[email protected]>
media: cec: stm32: return an error when log-address wait times out
Kryštof Černý <[email protected]>
w1: ds2482: add OF device match table
Pengpeng Hou <[email protected]>
gpio: pca9570: Use I2C match data
YiPeng Chai <[email protected]>
drm/amdgpu: add bounds check to prevent array overflow
Gangliang Xie <[email protected]>
drm/amdgpu: add buf length check
Ruoyu Wang <[email protected]>
drm/radeon: avoid double free in r600 DPM cleanup
Charlene Liu <[email protected]>
drm/amd/display: fix max dispclk_khz/dppclk_khz double 1000
Asad Kamal <[email protected]>
drm/amdgpu: Gate debugfs MMIO access on kernel lockdown
Asad Kamal <[email protected]>
drm/amd/pm: Validate OD DPM triples before mutating tables
Jonas Karlman <[email protected]>
drm/rockchip: dw_hdmi: Use resume_early pm ops for system suspend
YuanZhe Liu <[email protected]>
ALSA: line6: Clear prev_fbuf on capture buffer release
Yao Kai <[email protected]>
ext4: validate readdir offset before accessing dirent
Zihan Xi <[email protected]>
net: gso: limit recursive IP-in-IP segmentation
Jérémy Jean <[email protected]>
lib/crypto: arm64: Fix lost Poly1305 carry when resuming NEON state
Christian Brauner <[email protected]>
fork: don't create io threads once PF_POSTCOREDUMP is set
Christian Brauner <[email protected]>
fork: move the coredump and exec checks into create_io_thread()
Christian Brauner <[email protected]>
exec: cancel io_uring requests before de_thread()
André Draszik <[email protected]>
kbuild: link-vmlinux.sh: improve detection of third pass requirement
Ridham Khurana <[email protected]>
platform: cznic: turris-omnia-mcu: Add missing MODULE_DEVICE_TABLE()
Daniel Schaefer <[email protected]>
iio: hid-sensor: als: scale each channel individually
SJ Park <[email protected]>
mm/damon/sysfs: put target pids for apply_inputs() failure
SJ Park <[email protected]>
mm/damon/sysfs: put target pids for damon_start() failure
Baolin Wang <[email protected]>
mm: vmscan: fix dirty folios throttling on cgroup v1 for MGLRU
SJ Park <[email protected]>
mm/damon/core: error damos_commit_quota_goal() for zero target_value
Sasha Levin <[email protected]>
Revert "KVM: s390: move pv gmap functions into kvm"
Sasha Levin <[email protected]>
Revert "KVM: s390: use __kvm_faultin_pfn()"
Sasha Levin <[email protected]>
Revert "KVM: s390: move gmap_shadow_pgt_lookup() into kvm"
Sasha Levin <[email protected]>
Revert "KVM: s390: pv: fix race when making a page secure"
Sasha Levin <[email protected]>
Revert "KVM: s390: Fix FOLL_*/FAULT_FLAG_* confusion"
Sasha Levin <[email protected]>
Revert "s390/uv: Don't return 0 from make_hva_secure() if the operation was not successful"
Fuad Tabba <[email protected]>
KVM: arm64: Transfer the hyp stack pages out of the host stage-2
Namjae Jeon <[email protected]>
ksmbd: wait for negotiation before receiving another PDU
Zizhen Liu <[email protected]>
net: skbuff: propagate shared-frag marker in skb_zerocopy()
-------------
Diffstat:
Documentation/admin-guide/cgroup-v2.rst | 10 +- Documentation/block/blk-mq.rst | 2 +- .../bindings/clock/nuvoton,ma35d1-clk.yaml | 16 +- Documentation/hwmon/k10temp.rst | 8 +- Documentation/networking/ip-sysctl.rst | 5 +- Documentation/networking/rxrpc.rst | 13 +- Documentation/virt/hyperv/vmbus.rst | 17 +- Makefile | 7 +- arch/alpha/include/asm/mmu_context.h | 35 +- arch/alpha/include/asm/sfp-machine.h | 4 + arch/alpha/include/asm/switch_to.h | 1 - arch/alpha/include/asm/tlbflush.h | 3 +- arch/alpha/kernel/rtc.c | 37 +- arch/alpha/kernel/smp.c | 67 +- arch/alpha/mm/fault.c | 23 +- arch/alpha/mm/tlbflush.c | 18 +- arch/arm/include/asm/linkage.h | 29 + arch/arm/include/asm/smp.h | 2 +- arch/arm/kernel/head-nommu.S | 1 + arch/arm/kernel/head.S | 1 + arch/arm/kernel/smp.c | 15 +- arch/arm/mach-imx/pm-imx6.c | 26 +- arch/arm/mach-imx/suspend-imx6.S | 6 +- arch/arm/mach-omap2/sleep44xx.S | 5 +- arch/arm/mm/alignment.c | 51 +- .../boot/dts/freescale/imx8mp-verdin-yavia.dtsi | 7 +- arch/arm64/boot/dts/mediatek/mt7986a.dtsi | 1 + .../dts/qcom/sdm845-xiaomi-beryllium-common.dtsi | 6 + arch/arm64/boot/dts/qcom/sdm845-xiaomi-polaris.dts | 6 + arch/arm64/boot/dts/ti/k3-am62-lp-sk.dts | 2 +- arch/arm64/boot/dts/ti/k3-am62-phycore-som.dtsi | 2 +- arch/arm64/boot/dts/ti/k3-am62-verdin.dtsi | 6 +- arch/arm64/boot/dts/ti/k3-am625-beagleplay.dts | 6 +- arch/arm64/boot/dts/ti/k3-am62a-phycore-som.dtsi | 2 +- arch/arm64/boot/dts/ti/k3-am62a7-sk.dts | 5 +- arch/arm64/boot/dts/ti/k3-am62x-phyboard-lyra.dtsi | 2 +- arch/arm64/boot/dts/ti/k3-am62x-sk-common.dtsi | 2 +- arch/arm64/crypto/poly1305-armv8.pl | 2 +- arch/arm64/include/asm/kvm_host.h | 7 +- arch/arm64/include/asm/pgtable.h | 3 + arch/arm64/kernel/efi.c | 8 +- arch/arm64/kvm/arm.c | 31 +- arch/arm64/kvm/hyp/nvhe/setup.c | 10 + arch/arm64/kvm/vgic/vgic-mmio-v3.c | 33 +- arch/arm64/mm/contpte.c | 4 +- arch/arm64/mm/mmu.c | 14 + arch/loongarch/include/asm/barrier.h | 3 - arch/loongarch/include/asm/hw_breakpoint.h | 4 +- arch/loongarch/include/asm/loongarch.h | 4 +- arch/loongarch/include/asm/numa.h | 2 +- arch/loongarch/include/asm/pgtable.h | 2 +- arch/loongarch/kernel/hw_breakpoint.c | 27 +- arch/loongarch/kernel/irq.c | 3 +- arch/loongarch/kernel/traps.c | 13 +- arch/loongarch/kvm/vcpu.c | 38 +- arch/loongarch/mm/init.c | 17 +- arch/loongarch/pci/pci.c | 3 +- arch/microblaze/kernel/entry.S | 19 +- arch/microblaze/kernel/signal.c | 26 + arch/mips/Kconfig | 1 + arch/mips/mm/tlb-r4k.c | 21 +- arch/powerpc/kvm/book3s_hv.c | 76 +- arch/powerpc/kvm/book3s_paired_singles.c | 7 +- arch/powerpc/platforms/pseries/plpks.c | 27 +- arch/powerpc/platforms/pseries/plpks_sed_ops.c | 12 +- arch/riscv/include/asm/pgtable.h | 9 +- arch/riscv/kernel/traps.c | 3 + arch/riscv/kvm/mmu.c | 2 + arch/riscv/kvm/vcpu_exit.c | 2 +- arch/riscv/kvm/vcpu_pmu.c | 9 + arch/riscv/kvm/vcpu_sbi_replace.c | 12 +- arch/riscv/net/bpf_jit_comp32.c | 47 +- arch/s390/include/asm/gmap.h | 3 +- arch/s390/include/asm/uv.h | 6 +- arch/s390/kernel/perf_cpum_cf.c | 3 + arch/s390/kernel/process.c | 12 +- arch/s390/kernel/signal.c | 6 +- arch/s390/kernel/uv.c | 401 +- arch/s390/kvm/Makefile | 2 +- arch/s390/kvm/gaccess.c | 42 +- arch/s390/kvm/gmap.c | 121 - arch/s390/kvm/gmap.h | 19 - arch/s390/kvm/intercept.c | 3 +- arch/s390/kvm/kvm-s390.c | 156 +- arch/s390/kvm/kvm-s390.h | 6 - arch/s390/kvm/pv.c | 21 - arch/s390/lib/probes.c | 2 +- arch/s390/mm/gmap.c | 45 +- arch/x86/events/core.c | 19 +- arch/x86/events/intel/lbr.c | 2 +- arch/x86/events/intel/uncore.c | 5 +- arch/x86/include/asm/kvm_host.h | 18 +- arch/x86/include/asm/vmx.h | 8 + arch/x86/kernel/process.c | 1 + arch/x86/kvm/hyperv.c | 5 +- arch/x86/kvm/mmu/mmu.c | 29 +- arch/x86/kvm/mmu/paging_tmpl.h | 39 +- arch/x86/kvm/regs.c | 3 +- arch/x86/kvm/svm/nested.c | 15 +- arch/x86/kvm/svm/sev.c | 73 +- arch/x86/kvm/svm/svm.c | 35 +- arch/x86/kvm/svm/svm.h | 1 + arch/x86/kvm/vmx/nested.c | 41 +- arch/x86/kvm/vmx/vmx.c | 9 +- arch/x86/kvm/x86.c | 82 +- arch/x86/kvm/xen.c | 18 + arch/x86/mm/pat/set_memory.c | 23 +- block/bdev.c | 12 + block/blk-crypto-fallback.c | 6 + block/blk-iocost.c | 2 + block/blk-mq.c | 2 + crypto/algif_skcipher.c | 8 +- drivers/accessibility/speakup/selection.c | 6 + drivers/acpi/acpi_fpdt.c | 55 +- drivers/acpi/apei/ghes.c | 10 +- drivers/acpi/battery.c | 14 + drivers/acpi/button.c | 11 + drivers/acpi/pfr_update.c | 2 +- drivers/acpi/sysfs.c | 9 +- drivers/acpi/video_detect.c | 8 + drivers/ata/ahci_st.c | 78 +- drivers/ata/ata_generic.c | 6 +- drivers/ata/libahci.c | 28 +- drivers/ata/libahci_platform.c | 4 + drivers/ata/libata-core.c | 75 +- drivers/ata/libata-scsi.c | 5 + drivers/ata/libata-sff.c | 5 + drivers/ata/pata_ep93xx.c | 30 +- drivers/ata/sata_fsl.c | 26 +- drivers/ata/sata_qstor.c | 8 +- drivers/base/attribute_container.c | 7 +- drivers/base/base.h | 1 + drivers/base/bus.c | 45 +- drivers/base/core.c | 4 +- drivers/base/dd.c | 92 +- drivers/base/regmap/regcache-maple.c | 2 +- drivers/base/regmap/regmap-debugfs.c | 1 + drivers/base/regmap/regmap.c | 15 +- drivers/block/aoe/aoenet.c | 14 +- drivers/block/floppy.c | 8 +- drivers/block/loop.c | 6 +- drivers/block/xen-blkfront.c | 16 +- drivers/bluetooth/btrsi.c | 3 +- drivers/bluetooth/btusb.c | 8 +- drivers/bluetooth/hci_bcsp.c | 5 +- drivers/bluetooth/hci_nokia.c | 20 + drivers/bluetooth/hci_vhci.c | 4 + drivers/bus/mhi/host/pm.c | 14 +- drivers/char/hw_random/amd-rng.c | 2 +- drivers/char/hw_random/ba431-rng.c | 2 +- drivers/char/hw_random/core.c | 1 + drivers/char/ipmi/ipmi_msghandler.c | 1 + drivers/char/tpm/tpm-dev-common.c | 3 + drivers/char/tpm/tpm_nsc.c | 8 +- drivers/char/tpm/tpm_tis_spi.h | 8 +- drivers/char/virtio_console.c | 13 +- drivers/clk/imx/clk-imx8qxp-lpcg.c | 1 + drivers/clk/imx/clk-imx8qxp.c | 1 + drivers/clk/imx/clk.c | 15 +- drivers/clk/mstar/clk-msc313-mpll.c | 2 +- drivers/clk/mvebu/ap-cpu-clk.c | 4 +- drivers/clk/qcom/gcc-ipq5018.c | 10 + drivers/clk/qcom/gcc-ipq5332.c | 1 + drivers/clk/starfive/clk-starfive-jh7110-isp.c | 2 +- drivers/clk/sunxi-ng/ccu_common.c | 12 +- drivers/clk/tegra/clk-pll.c | 1 + drivers/clk/zynq/clkc.c | 8 + drivers/clocksource/timer-digicolor.c | 2 + drivers/clocksource/timer-fttmr010.c | 2 + drivers/comedi/drivers/aio_iiro_16.c | 3 + drivers/comedi/drivers/das6402.c | 10 +- drivers/comedi/drivers/dt2811.c | 7 +- drivers/comedi/drivers/ni_at_a2150.c | 13 +- drivers/comedi/drivers/ni_atmio16d.c | 3 + drivers/comedi/drivers/pcl711.c | 3 +- drivers/comedi/drivers/pcl816.c | 3 +- drivers/comedi/drivers/pcl818.c | 3 +- drivers/comedi/drivers/pcmmio.c | 3 + drivers/comedi/drivers/pcmuio.c | 5 +- drivers/comedi/drivers/quatech_daqp_cs.c | 4 +- drivers/cpufreq/Kconfig | 1 + drivers/cpufreq/amd-pstate.c | 6 +- drivers/cpufreq/cpufreq_conservative.c | 8 +- drivers/cpufreq/cpufreq_governor.c | 29 +- drivers/cpufreq/cpufreq_governor.h | 2 + drivers/cpufreq/cpufreq_stats.c | 4 + drivers/cpufreq/intel_pstate.c | 2 + drivers/cpufreq/loongson3_cpufreq.c | 73 +- drivers/crypto/amlogic/amlogic-gxl-core.c | 7 +- drivers/crypto/atmel-aes.c | 2 +- drivers/crypto/atmel-tdes.c | 6 +- drivers/crypto/caam/caampkc.c | 6 + drivers/crypto/ccp/dbc.c | 4 +- drivers/crypto/hisilicon/hpre/hpre_crypto.c | 20 +- .../crypto/intel/keembay/keembay-ocs-aes-core.c | 3 +- drivers/crypto/intel/keembay/keembay-ocs-ecc.c | 1 + drivers/crypto/intel/keembay/ocs-aes.c | 3 +- drivers/crypto/intel/qat/qat_common/adf_dev_mgr.c | 10 +- .../crypto/intel/qat/qat_common/adf_gen4_vf_mig.c | 5 + drivers/crypto/intel/qat/qat_common/adf_vf_isr.c | 2 - drivers/crypto/nx/nx-842.c | 2 + drivers/crypto/sa2ul.c | 3 +- drivers/cxl/acpi.c | 20 +- drivers/cxl/core/pci.c | 20 +- drivers/cxl/core/port.c | 3 + drivers/dax/super.c | 2 +- drivers/dma/altera-msgdma.c | 10 +- drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c | 2 +- drivers/dma/pl330.c | 19 +- drivers/edac/edac_mc.c | 6 +- drivers/edac/i10nm_base.c | 1 + drivers/firewire/ohci-serdes-test.c | 4 +- drivers/firewire/ohci.h | 2 +- drivers/firmware/efi/libstub/efi-stub.c | 8 + drivers/firmware/imx/imx-scu.c | 25 +- drivers/fpga/fpga-mgr.c | 2 +- drivers/gpio/gpio-davinci.c | 6 +- drivers/gpio/gpio-mvebu.c | 33 +- drivers/gpio/gpio-pca953x.c | 14 +- drivers/gpio/gpio-pca9570.c | 2 +- drivers/gpio/gpio-sifive.c | 1 + drivers/gpio/gpio-vf610.c | 1 + drivers/gpio/gpiolib.c | 12 +- drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c | 68 +- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v11.c | 3 +- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c | 18 +- drivers/gpu/drm/amd/amdgpu/amdgpu_atomfirmware.c | 2 - drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c | 10 +- drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c | 7 + drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 13 +- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 13 + drivers/gpu/drm/amd/amdgpu/amdgpu_hmm.c | 9 +- drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c | 5 +- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 7 + drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 3 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vm_sdma.c | 5 + drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c | 57 +- drivers/gpu/drm/amd/amdgpu/cik.c | 10 + drivers/gpu/drm/amd/amdgpu/gmc_v12_0.c | 4 +- drivers/gpu/drm/amd/amdgpu/uvd_v3_1.c | 2 +- drivers/gpu/drm/amd/amdgpu/vi.c | 10 + drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 36 +- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 35 +- drivers/gpu/drm/amd/amdkfd/kfd_doorbell.c | 23 +- drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v10.c | 4 +- drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v11.c | 4 +- drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v12.c | 4 +- drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v9.c | 6 +- drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_vi.c | 7 +- drivers/gpu/drm/amd/amdkfd/kfd_priv.h | 4 + drivers/gpu/drm/amd/amdkfd/kfd_process.c | 4 +- drivers/gpu/drm/amd/amdkfd/kfd_queue.c | 23 +- drivers/gpu/drm/amd/amdkfd/kfd_svm.c | 29 +- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 11 +- .../drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c | 2 +- .../amd/display/amdgpu_dm/amdgpu_dm_mst_types.c | 3 + .../gpu/drm/amd/display/dc/dce60/dce60_resource.c | 7 + .../gpu/drm/amd/display/dc/dml/dsc/rc_calc_fpu.c | 2 +- .../drm/amd/display/dc/dml2/dml21/dml21_wrapper.c | 8 +- .../dml21/src/dml2_core/dml2_core_dcn4_calcs.c | 2 + .../drm/amd/display/modules/color/color_gamma.c | 3 +- .../amd/include/asic_reg/dcn/dcn_6_0_0_offset.h | 15799 +++++ .../amd/include/asic_reg/dcn/dcn_6_0_0_sh_mask.h | 58556 +++++++++++++++++++ .../amd/include/asic_reg/dpcs/dpcs_6_0_0_offset.h | 47 + .../amd/include/asic_reg/dpcs/dpcs_6_0_0_sh_mask.h | 55 + .../include/asic_reg/mmhub/mmhub_5_0_1_offset.h | 17 + .../include/asic_reg/mmhub/mmhub_5_0_1_sh_mask.h | 17 + drivers/gpu/drm/amd/include/kgd_pp_interface.h | 1 + drivers/gpu/drm/amd/pm/amdgpu_dpm.c | 23 +- drivers/gpu/drm/amd/pm/inc/amdgpu_dpm.h | 2 + drivers/gpu/drm/amd/pm/powerplay/amd_powerplay.c | 21 +- .../gpu/drm/amd/pm/powerplay/hwmgr/ppatomctrl.c | 28 +- .../amd/pm/powerplay/hwmgr/process_pptables_v1_0.c | 673 +- .../drm/amd/pm/powerplay/hwmgr/processpptables.c | 446 +- .../gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 36 +- .../gpu/drm/amd/pm/powerplay/hwmgr/vega10_hwmgr.c | 48 +- .../pm/powerplay/hwmgr/vega10_processpptables.c | 623 +- .../pm/powerplay/hwmgr/vega12_processpptables.c | 7 + .../pm/powerplay/hwmgr/vega20_processpptables.c | 7 + drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 19 +- .../gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c | 2 - .../gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c | 4 +- drivers/gpu/drm/arm/malidp_crtc.c | 1 + drivers/gpu/drm/bridge/analogix/analogix_dp_core.c | 13 +- drivers/gpu/drm/etnaviv/etnaviv_gpu.c | 16 +- drivers/gpu/drm/etnaviv/etnaviv_gpu.h | 6 + drivers/gpu/drm/i915/display/intel_dmc.c | 55 + drivers/gpu/drm/i915/display/intel_dmc_regs.h | 12 + drivers/gpu/drm/i915/display/intel_dp_mst.c | 21 + drivers/gpu/drm/i915/display/intel_dp_mst.h | 2 + drivers/gpu/drm/i915/display/intel_link_bw.c | 4 +- drivers/gpu/drm/msm/adreno/a6xx_catalog.c | 2 +- drivers/gpu/drm/msm/hdmi/hdmi_bridge.c | 2 +- drivers/gpu/drm/msm/hdmi/hdmi_phy.c | 16 +- drivers/gpu/drm/msm/msm_ringbuffer.c | 2 +- drivers/gpu/drm/msm/msm_ringbuffer.h | 1 + drivers/gpu/drm/nouveau/nouveau_abi16.c | 4 + drivers/gpu/drm/nouveau/nouveau_connector.c | 1 + drivers/gpu/drm/nouveau/nouveau_dp.c | 4 +- drivers/gpu/drm/nouveau/nouveau_fence.c | 2 +- drivers/gpu/drm/nouveau/nouveau_svm.c | 13 + drivers/gpu/drm/panel/panel-edp.c | 2 + drivers/gpu/drm/panel/panel-simple.c | 3 + drivers/gpu/drm/panthor/panthor_sched.c | 14 +- drivers/gpu/drm/radeon/atombios_crtc.c | 5 +- drivers/gpu/drm/radeon/atombios_encoders.c | 23 +- drivers/gpu/drm/radeon/r600_dpm.c | 21 +- drivers/gpu/drm/rockchip/dw_hdmi-rockchip.c | 7 +- drivers/gpu/drm/ttm/ttm_bo_util.c | 11 +- drivers/gpu/drm/virtio/virtgpu_drv.h | 1 + drivers/gpu/drm/virtio/virtgpu_kms.c | 1 + drivers/gpu/drm/virtio/virtgpu_vq.c | 15 + drivers/gpu/drm/xe/display/intel_fb_bo.c | 3 +- drivers/gpu/drm/xe/display/xe_fb_pin.c | 3 +- drivers/gpu/drm/xe/xe_exec_queue_types.h | 12 + drivers/gpu/drm/xe/xe_preempt_fence.c | 7 + drivers/gpu/drm/xe/xe_vm.c | 18 +- drivers/gpu/host1x/hw/cdma_hw.c | 2 +- drivers/greybus/manifest.c | 2 + drivers/hid/amd-sfh-hid/amd_sfh_client.c | 4 +- .../amd-sfh-hid/hid_descriptor/amd_sfh_hid_desc.h | 2 - .../hid_descriptor/amd_sfh_hid_report_desc.h | 7 - drivers/hid/amd-sfh-hid/sfh1_1/amd_sfh_interface.c | 6 + drivers/hid/hid-core.c | 4 +- drivers/hid/hid-cougar.c | 3 + drivers/hid/hid-cp2112.c | 9 +- drivers/hid/hid-elo.c | 3 + drivers/hid/hid-ids.h | 6 + drivers/hid/hid-input.c | 17 +- drivers/hid/hid-logitech-dj.c | 3 + drivers/hid/hid-logitech-hidpp.c | 2 + drivers/hid/hid-mcp2200.c | 5 + drivers/hid/hid-mcp2221.c | 2 +- drivers/hid/hid-multitouch.c | 19 +- drivers/hid/hid-picolcd_fb.c | 12 +- drivers/hid/hid-prodikeys.c | 7 +- drivers/hid/hid-pxrc.c | 3 + drivers/hid/hid-quirks.c | 4 + drivers/hid/hid-rmi.c | 2 +- drivers/hid/hid-roccat-isku.c | 3 + drivers/hid/hid-roccat-koneplus.c | 3 + drivers/hid/hid-roccat-konepure.c | 3 + drivers/hid/hid-roccat-kovaplus.c | 3 + drivers/hid/hid-roccat-pyra.c | 3 + drivers/hid/hid-roccat-ryos.c | 3 + drivers/hid/hid-roccat-savu.c | 3 + drivers/hid/hid-roccat.c | 8 +- drivers/hid/hid-zydacron.c | 3 + drivers/hid/i2c-hid/i2c-hid-core.c | 4 +- drivers/hid/intel-ish-hid/ishtp-hid-client.c | 5 +- drivers/hid/usbhid/hiddev.c | 37 +- drivers/hid/wacom_sys.c | 198 +- drivers/hid/wacom_wac.c | 99 +- drivers/hid/wacom_wac.h | 6 +- drivers/hsi/controllers/omap_ssi_core.c | 3 + drivers/hte/hte-tegra194.c | 10 +- drivers/hv/ring_buffer.c | 29 +- drivers/hwmon/asus_rog_ryujin.c | 22 +- drivers/hwmon/coretemp.c | 31 +- drivers/hwmon/corsair-cpro.c | 9 +- drivers/hwmon/gigabyte_waterforce.c | 5 + drivers/hwmon/k10temp.c | 5 +- drivers/hwmon/lm95245.c | 6 +- drivers/hwmon/sht3x.c | 5 +- drivers/i2c/busses/i2c-designware-master.c | 8 + drivers/i2c/busses/i2c-imx-lpi2c.c | 21 +- drivers/i2c/busses/i2c-mt7621.c | 9 +- drivers/i2c/busses/i2c-qcom-cci.c | 24 +- drivers/i2c/i2c-core-acpi.c | 7 +- drivers/i3c/master.c | 3 +- drivers/iio/accel/adis16201.c | 10 +- drivers/iio/accel/adxl313_spi.c | 2 + drivers/iio/accel/adxl380_spi.c | 2 + drivers/iio/accel/fxls8962af-core.c | 2 + drivers/iio/accel/kxcjk-1013.c | 1 + drivers/iio/accel/mma9551.c | 1 + drivers/iio/accel/mma9553.c | 1 + drivers/iio/adc/adi-axi-adc.c | 4 + drivers/iio/adc/at91-sama5d2_adc.c | 1 + drivers/iio/adc/max11205.c | 2 + drivers/iio/adc/max1241.c | 1 + drivers/iio/adc/mcp3911.c | 2 + drivers/iio/adc/stm32-adc.c | 4 +- drivers/iio/adc/ti-adc128s052.c | 8 +- drivers/iio/dac/ad5755.c | 3 + drivers/iio/frequency/adf4377.c | 3 + drivers/iio/imu/inv_icm42600/inv_icm42600.h | 1 + drivers/iio/imu/inv_icm42600/inv_icm42600_accel.c | 17 +- drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c | 2 + drivers/iio/imu/inv_icm42600/inv_icm42600_core.c | 9 + drivers/iio/imu/inv_icm42600/inv_icm42600_gyro.c | 8 +- drivers/iio/light/apds9306.c | 2 +- drivers/iio/light/hid-sensor-als.c | 22 +- drivers/iio/potentiometer/x9250.c | 7 +- drivers/iio/pressure/bmp280-spi.c | 2 + drivers/infiniband/hw/hfi1/fault.c | 1 - drivers/infiniband/sw/rxe/rxe_mw.c | 20 +- drivers/input/joystick/xpad.c | 1 + drivers/input/keyboard/matrix_keypad.c | 3 - drivers/iommu/amd/amd_iommu_types.h | 1 + drivers/iommu/amd/iommu.c | 38 +- drivers/iommu/arm/arm-smmu-v3/tegra241-cmdqv.c | 16 +- drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c | 1 + drivers/iommu/arm/arm-smmu/qcom_iommu.c | 18 +- drivers/iommu/dma-iommu.c | 20 +- drivers/iommu/intel/cache.c | 5 +- drivers/iommu/intel/iommu.h | 17 +- drivers/iommu/iommufd/fault.c | 4 +- drivers/iommu/iommufd/io_pagetable.c | 3 + drivers/iommu/rockchip-iommu.c | 13 + drivers/ipack/devices/ipoctal.c | 16 +- drivers/irqchip/irq-gic-v3-its.c | 2 +- drivers/irqchip/irq-imx-intmux.c | 15 +- drivers/irqchip/irq-mchp-eic.c | 4 +- drivers/irqchip/irq-msi-lib.c | 1 + drivers/irqchip/irq-riscv-imsic-platform.c | 2 +- drivers/leds/flash/leds-ktd2692.c | 10 +- drivers/mailbox/mtk-cmdq-mailbox.c | 7 +- drivers/mailbox/qcom-ipcc.c | 6 + drivers/md/dm-bufio.c | 4 +- drivers/md/dm-integrity.c | 55 + drivers/md/dm-snap-persistent.c | 7 +- drivers/md/dm-vdo/indexer/chapter-index.c | 15 +- drivers/md/dm-vdo/indexer/delta-index.c | 17 +- drivers/md/dm-vdo/indexer/volume.c | 6 - drivers/md/dm-writecache.c | 54 +- drivers/md/dm.c | 2 +- drivers/md/md.c | 21 +- drivers/md/raid5-cache.c | 34 +- drivers/md/raid5.c | 13 +- drivers/md/raid5.h | 1 + drivers/media/cec/core/cec-adap.c | 1 - drivers/media/cec/platform/stm32/stm32-cec.c | 16 +- drivers/media/cec/platform/tegra/tegra_cec.c | 14 +- .../extron-da-hd-4k-plus/extron-da-hd-4k-plus.c | 4 +- drivers/media/common/saa7146/saa7146_core.c | 3 +- drivers/media/common/v4l2-tpg/v4l2-tpg-core.c | 14 +- drivers/media/dvb-core/dmxdev.c | 11 +- drivers/media/dvb-frontends/stv0900_core.c | 2 + drivers/media/dvb-frontends/stv090x.c | 2 + drivers/media/i2c/adv7180.c | 2 +- drivers/media/i2c/adv7604.c | 3 +- drivers/media/i2c/alvium-csi2.c | 1 + drivers/media/i2c/ov8856.c | 3 +- drivers/media/i2c/ov8865.c | 48 +- drivers/media/i2c/tc358743.c | 3 +- drivers/media/pci/cx18/cx18-driver.c | 9 +- drivers/media/pci/cx18/cx18-vbi.c | 2 +- drivers/media/pci/cx23885/cx23885-core.c | 4 + drivers/media/pci/cx23885/cx23885-dvb.c | 14 +- drivers/media/pci/cx88/cx88-mpeg.c | 10 +- drivers/media/pci/intel/ipu-bridge.c | 2 +- drivers/media/pci/ivtv/ivtv-vbi.c | 2 +- drivers/media/pci/tw68/tw68-core.c | 2 +- drivers/media/pci/tw686x/tw686x-core.c | 10 + drivers/media/platform/amphion/vpu_core.c | 19 +- drivers/media/platform/amphion/vpu_drv.c | 1 + drivers/media/platform/atmel/atmel-isi.c | 7 +- .../platform/chips-media/wave5/wave5-vpu-dec.c | 24 + .../platform/chips-media/wave5/wave5-vpu-enc.c | 6 +- .../media/platform/imagination/e5010-jpeg-enc.c | 4 +- drivers/media/platform/m2m-deinterlace.c | 2 +- drivers/media/platform/marvell/Kconfig | 1 + drivers/media/platform/marvell/mcam-core.c | 14 +- drivers/media/platform/marvell/mmp-driver.c | 5 +- .../media/platform/mediatek/jpeg/mtk_jpeg_core.c | 17 +- .../media/platform/mediatek/mdp3/mtk-mdp3-comp.c | 14 +- .../mediatek/vcodec/decoder/mtk_vcodec_dec_drv.c | 2 + drivers/media/platform/mediatek/vpu/mtk_vpu.c | 2 + .../media/platform/microchip/microchip-csi2dc.c | 1 + .../media/platform/microchip/microchip-isc-base.c | 62 +- .../media/platform/microchip/microchip-isc-clk.c | 7 +- drivers/media/platform/microchip/microchip-isc.h | 1 + .../platform/microchip/microchip-sama5d2-isc.c | 28 +- .../platform/microchip/microchip-sama7g5-isc.c | 28 +- drivers/media/platform/nuvoton/npcm-video.c | 9 +- drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c | 23 +- drivers/media/platform/qcom/camss/camss-vfe-17x.c | 5 +- drivers/media/platform/qcom/camss/camss-vfe.c | 14 +- .../media/platform/samsung/exynos4-is/fimc-lite.c | 3 +- drivers/media/platform/samsung/s5p-mfc/s5p_mfc.c | 4 +- .../media/platform/st/sti/delta/delta-mjpeg-hdr.c | 7 +- drivers/media/platform/ti/davinci/vpif_capture.c | 5 +- drivers/media/platform/ti/davinci/vpif_display.c | 3 + drivers/media/platform/verisilicon/hantro_drv.c | 9 +- .../platform/verisilicon/hantro_g1_mpeg2_dec.c | 5 + .../verisilicon/rockchip_vpu981_hw_av1_dec.c | 68 +- drivers/media/rc/bpf-lirc.c | 18 +- drivers/media/rc/fintek-cir.c | 4 + drivers/media/rc/imon.c | 5 - drivers/media/rc/ir-hix5hd2.c | 5 +- drivers/media/rc/ir-mce_kbd-decoder.c | 5 +- drivers/media/rc/ir_toy.c | 2 +- drivers/media/rc/lirc_dev.c | 3 + drivers/media/rc/meson-ir-tx.c | 20 +- drivers/media/rc/rc-ir-raw.c | 66 +- drivers/media/rc/rc-main.c | 42 +- drivers/media/rc/redrat3.c | 21 + drivers/media/rc/streamzap.c | 1 + drivers/media/rc/sunxi-cir.c | 2 +- drivers/media/test-drivers/vicodec/codec-fwht.h | 2 +- drivers/media/test-drivers/vicodec/vicodec-core.c | 16 +- drivers/media/test-drivers/vidtv/vidtv_bridge.c | 4 + drivers/media/test-drivers/vidtv/vidtv_demod.c | 9 - drivers/media/test-drivers/vim2m.c | 29 +- drivers/media/test-drivers/vivid/vivid-core.c | 1 + drivers/media/test-drivers/vivid/vivid-vid-cap.c | 13 + drivers/media/usb/au0828/au0828-core.c | 4 + drivers/media/usb/au0828/au0828-dvb.c | 20 +- drivers/media/usb/cx231xx/cx231xx-audio.c | 15 +- drivers/media/usb/cx231xx/cx231xx-cards.c | 2 +- drivers/media/usb/cx231xx/cx231xx.h | 2 +- drivers/media/usb/dvb-usb-v2/rtl28xxu.c | 14 +- drivers/media/usb/em28xx/em28xx-audio.c | 7 + drivers/media/usb/em28xx/em28xx-cards.c | 2 +- drivers/media/usb/em28xx/em28xx-core.c | 3 - drivers/media/usb/em28xx/em28xx-video.c | 26 +- drivers/media/usb/go7007/go7007-driver.c | 5 +- drivers/media/usb/go7007/go7007-fw.c | 28 +- drivers/media/usb/go7007/go7007-usb.c | 8 + drivers/media/usb/go7007/s2250-board.c | 54 +- drivers/media/usb/gspca/gspca.c | 3 +- drivers/media/usb/hackrf/hackrf.c | 7 +- drivers/media/usb/pvrusb2/pvrusb2-sysfs.c | 1 + drivers/media/usb/usbtv/usbtv-core.c | 6 +- drivers/media/usb/usbtv/usbtv-video.c | 4 + drivers/media/usb/uvc/uvc_ctrl.c | 2 +- drivers/media/v4l2-core/v4l2-common.c | 2 +- drivers/media/v4l2-core/v4l2-ctrls-core.c | 12 +- drivers/memory/brcmstb_dpfe.c | 24 +- drivers/mfd/axp20x.c | 2 +- drivers/mfd/da903x.c | 34 +- drivers/mfd/ipaq-micro.c | 2 +- drivers/mfd/tps65217.c | 69 +- drivers/mfd/wcd934x.c | 8 +- drivers/misc/bcm-vk/bcm_vk_msg.c | 18 +- drivers/misc/genwqe/card_utils.c | 2 +- drivers/misc/hpilo.c | 7 +- drivers/misc/ibmvmc.c | 17 +- drivers/misc/mei/vsc-tp.c | 2 +- drivers/mmc/core/block.c | 5 + drivers/mmc/host/cqhci-core.c | 14 +- drivers/mmc/host/dw_mmc.c | 1 + drivers/mmc/host/moxart-mmc.c | 11 +- drivers/mmc/host/sdhci-of-ma35d1.c | 1 + drivers/mtd/chips/cfi_cmdset_0002.c | 15 + drivers/mtd/maps/amd76xrom.c | 2 + drivers/mtd/maps/l440gx.c | 2 - drivers/mtd/maps/pci.c | 2 +- drivers/mtd/mtdcore.c | 2 +- drivers/mtd/mtdsuper.c | 4 +- drivers/mtd/nand/raw/atmel/nand-controller.c | 6 +- drivers/mtd/nand/raw/sunxi_nand.c | 3 + drivers/mtd/parsers/qcomsmempart.c | 4 +- drivers/mtd/spi-nor/core.c | 9 + drivers/mtd/spi-nor/sfdp.c | 8 + drivers/net/bonding/bond_main.c | 2 +- drivers/net/dsa/mt7530.c | 44 +- drivers/net/ethernet/google/gve/gve_flow_rule.c | 1 + drivers/net/ethernet/hisilicon/hisi_femac.c | 1 + drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 40 +- drivers/net/ethernet/marvell/mvneta.c | 18 + drivers/net/ethernet/marvell/mvneta_bm.c | 72 + .../ethernet/marvell/prestera/prestera_router.c | 6 +- drivers/net/ethernet/mediatek/mtk_wed.c | 5 + drivers/net/ethernet/mediatek/mtk_wed_regs.h | 1 + drivers/net/ethernet/sfc/efx.c | 4 + drivers/net/ethernet/stmicro/stmmac/chain_mode.c | 3 +- drivers/net/ethernet/stmicro/stmmac/ring_mode.c | 3 +- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 4 + .../net/ethernet/stmicro/stmmac/stmmac_platform.c | 6 +- drivers/net/macvlan.c | 3 +- drivers/net/netdevsim/bpf.c | 11 + drivers/net/pcs/pcs-mtk-lynxi.c | 7 +- drivers/net/phy/sfp.c | 3 + drivers/net/ppp/ppp_generic.c | 1 + drivers/net/tap.c | 5 +- drivers/net/team/team_mode_broadcast.c | 2 + drivers/net/tun.c | 14 +- drivers/net/usb/cdc_ether.c | 16 + drivers/net/usb/pegasus.c | 16 +- drivers/net/usb/qmi_wwan.c | 1 + drivers/net/usb/rtl8150.c | 4 +- drivers/net/veth.c | 5 +- drivers/net/virtio_net.c | 25 +- drivers/net/wireless/ath/ath10k/htt_rx.c | 6 +- drivers/net/wireless/ath/ath11k/ahb.c | 79 +- drivers/net/wireless/ath/ath11k/dp.c | 2 + drivers/net/wireless/ath/ath11k/wmi.c | 6 + drivers/net/wireless/ath/ath12k/wmi.c | 37 +- drivers/net/wireless/ath/ath12k/wmi.h | 10 + drivers/net/wireless/ath/ath9k/channel.c | 2 + drivers/net/wireless/broadcom/b43/main.c | 5 +- .../wireless/broadcom/brcm80211/brcmfmac/msgbuf.c | 49 +- .../broadcom/brcm80211/brcmsmac/phy/phy_n.c | 2 +- drivers/net/wireless/intel/iwlwifi/dvm/tx.c | 4 +- drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 1 + drivers/net/wireless/intel/iwlwifi/mvm/time-sync.h | 4 + drivers/net/wireless/mediatek/mt76/eeprom.c | 17 +- drivers/net/wireless/mediatek/mt76/mt7603/beacon.c | 2 + drivers/net/wireless/mediatek/mt76/mt7603/dma.c | 2 +- drivers/net/wireless/mediatek/mt76/mt7603/eeprom.c | 1 + drivers/net/wireless/mediatek/mt76/mt7603/main.c | 76 +- drivers/net/wireless/mediatek/mt76/mt7615/init.c | 17 +- drivers/net/wireless/mediatek/mt76/mt7615/main.c | 6 +- .../net/wireless/mediatek/mt76/mt7615/pci_init.c | 1 + .../net/wireless/mediatek/mt76/mt7615/pci_mac.c | 5 +- .../net/wireless/mediatek/mt76/mt7615/usb_sdio.c | 5 +- drivers/net/wireless/mediatek/mt76/mt76x02_mac.c | 22 +- .../net/wireless/mediatek/mt76/mt76x02_usb_mcu.c | 2 +- drivers/net/wireless/mediatek/mt76/mt7915/mac.c | 9 +- drivers/net/wireless/mediatek/mt76/mt7921/mcu.c | 4 +- drivers/net/wireless/mediatek/mt76/mt7996/mac.c | 4 +- drivers/net/wireless/mediatek/mt76/tx.c | 18 +- drivers/net/wireless/mediatek/mt76/usb.c | 31 +- drivers/net/wireless/microchip/wilc1000/mon.c | 30 +- drivers/net/wireless/realtek/rtlwifi/pci.c | 39 +- .../net/wireless/realtek/rtlwifi/rtl8723be/hw.c | 6 - drivers/net/wireless/realtek/rtw88/mac80211.c | 2 +- drivers/net/wireless/realtek/rtw89/fw.c | 63 +- drivers/net/wireless/realtek/rtw89/rtw8851b_rfk.c | 4 +- drivers/net/wireless/realtek/rtw89/wow.c | 9 +- drivers/net/wireless/rsi/rsi_91x_coex.c | 3 +- drivers/net/wireless/rsi/rsi_91x_main.c | 7 +- drivers/net/wireless/rsi/rsi_91x_sdio_ops.c | 3 +- drivers/net/wireless/rsi/rsi_91x_usb_ops.c | 7 +- drivers/net/wireless/rsi/rsi_common.h | 2 +- drivers/net/wireless/rsi/rsi_sdio.h | 2 +- drivers/net/wireless/rsi/rsi_usb.h | 2 +- drivers/net/wireless/virtual/mac80211_hwsim.c | 10 +- drivers/net/wwan/iosm/iosm_ipc_protocol_ops.c | 5 + drivers/net/wwan/wwan_hwsim.c | 4 + drivers/nfc/nfcmrvl/spi.c | 4 + drivers/nfc/nxp-nci/i2c.c | 4 +- drivers/nvme/host/auth.c | 18 +- drivers/nvme/host/core.c | 4 + drivers/nvme/host/fc.c | 2 +- drivers/nvme/host/ioctl.c | 2 +- drivers/nvme/host/nvme.h | 6 +- drivers/nvme/host/pci.c | 6 +- drivers/nvme/host/rdma.c | 1 + drivers/nvme/host/sysfs.c | 18 +- drivers/nvme/host/tcp.c | 16 +- drivers/nvme/host/zns.c | 8 +- drivers/nvme/target/admin-cmd.c | 2 +- drivers/nvme/target/auth.c | 2 + drivers/nvme/target/configfs.c | 2 + drivers/nvme/target/fabrics-cmd-auth.c | 45 +- drivers/nvme/target/fc.c | 18 +- drivers/nvme/target/io-cmd-bdev.c | 5 +- drivers/nvme/target/io-cmd-file.c | 4 +- drivers/nvme/target/nvmet.h | 2 + drivers/nvme/target/passthru.c | 9 + drivers/nvme/target/rdma.c | 2 +- drivers/nvme/target/zns.c | 10 + drivers/nvmem/brcm_nvram.c | 15 +- drivers/nvmem/core.c | 4 +- drivers/opp/core.c | 54 +- drivers/parisc/eisa_enumerator.c | 15 +- drivers/pci/ats.c | 7 +- drivers/pci/controller/dwc/pcie-qcom-ep.c | 2 + drivers/pci/controller/pcie-rockchip-host.c | 20 - drivers/pci/controller/pcie-xilinx-dma-pl.c | 10 +- drivers/pci/controller/vmd.c | 3 + drivers/pci/hotplug/pciehp_core.c | 2 +- drivers/pci/pci-label.c | 2 +- drivers/pci/pci.c | 48 +- drivers/pci/pcie/aer.c | 35 +- drivers/pci/pcie/portdrv.c | 28 +- drivers/pci/probe.c | 5 +- drivers/pci/quirks.c | 21 + drivers/pci/switch/switchtec.c | 1 + drivers/pci/xen-pcifront.c | 11 +- drivers/peci/controller/peci-aspeed.c | 6 +- drivers/peci/controller/peci-npcm.c | 6 +- drivers/perf/marvell_cn10k_ddr_pmu.c | 6 + drivers/perf/riscv_pmu_sbi.c | 33 +- drivers/perf/xgene_pmu.c | 4 +- drivers/phy/phy-core.c | 45 +- drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c | 96 +- drivers/pinctrl/pinctrl-sx150x.c | 1 + drivers/pinctrl/stm32/pinctrl-stm32.c | 6 +- drivers/platform/cznic/turris-omnia-mcu-base.c | 1 + drivers/platform/x86/amd/pmc/mp1_stb.c | 23 +- drivers/platform/x86/amd/pmc/pmc.c | 5 +- drivers/platform/x86/amd/pmf/spc.c | 8 +- drivers/platform/x86/amd/pmf/sps.c | 10 +- drivers/platform/x86/asus-nb-wmi.c | 1 + drivers/platform/x86/asus-wmi.c | 42 +- drivers/platform/x86/dell/dell-smbios-wmi.c | 69 +- drivers/platform/x86/hp/hp-bioscfg/bioscfg.c | 82 +- .../x86/hp/hp-bioscfg/passwdobj-attributes.c | 16 +- .../platform/x86/hp/hp-bioscfg/spmobj-attributes.c | 5 +- drivers/platform/x86/hp/hp-wmi.c | 7 +- drivers/platform/x86/intel/int1092/intel_sar.c | 8 +- drivers/platform/x86/intel/pmt/class.c | 9 +- .../x86/intel/uncore-frequency/uncore-frequency.c | 2 +- drivers/platform/x86/lenovo-ymc.c | 8 +- drivers/platform/x86/msi-ec.c | 1 + drivers/platform/x86/siemens/simatic-ipc.c | 21 +- drivers/platform/x86/thinkpad_acpi.c | 1 + drivers/pmdomain/qcom/rpmhpd.c | 14 +- drivers/power/reset/piix4-poweroff.c | 1 + drivers/power/supply/ab8500_fg.c | 69 +- drivers/power/supply/bq27xxx_battery.c | 2 +- drivers/power/supply/cros_peripheral_charger.c | 13 +- drivers/power/supply/generic-adc-battery.c | 2 +- drivers/power/supply/qcom_pmi8998_charger.c | 41 +- drivers/power/supply/sbs-battery.c | 11 + drivers/powercap/intel_rapl_common.c | 4 +- drivers/pwm/pwm-tiehrpwm.c | 3 + drivers/rapidio/devices/rio_mport_cdev.c | 5 +- drivers/regulator/core.c | 4 + drivers/regulator/fan53555.c | 6 + drivers/regulator/of_regulator.c | 26 +- drivers/regulator/rt6190-regulator.c | 18 +- drivers/regulator/rt6245-regulator.c | 5 +- drivers/remoteproc/remoteproc_core.c | 23 +- drivers/remoteproc/remoteproc_elf_loader.c | 23 +- drivers/rpmsg/rpmsg_char.c | 5 + drivers/rtc/rtc-ab-eoz9.c | 1 + drivers/rtc/rtc-brcmstb-waketimer.c | 1 + drivers/rtc/rtc-cmos.c | 6 +- drivers/rtc/rtc-ds1307.c | 2 +- drivers/s390/block/dasd.c | 10 +- drivers/s390/crypto/zcrypt_ccamisc.c | 22 +- drivers/scsi/dc395x.c | 10 +- drivers/scsi/ibmvscsi/ibmvfc.c | 10 +- drivers/scsi/libiscsi_tcp.c | 3 +- drivers/scsi/qla2xxx/qla_os.c | 15 +- drivers/scsi/scsi_devinfo.c | 2 +- drivers/scsi/smartpqi/smartpqi_init.c | 36 + drivers/scsi/snic/snic_main.c | 1 + drivers/sh/intc/core.c | 11 +- drivers/sh/maple/maple.c | 4 +- drivers/slimbus/messaging.c | 2 +- drivers/soc/fsl/dpio/dpio-driver.c | 9 +- drivers/soc/fsl/qe/tsa.c | 16 +- drivers/soc/ixp4xx/ixp4xx-qmgr.c | 1 + drivers/soc/qcom/socinfo.c | 1 + drivers/soundwire/dmi-quirks.c | 42 +- drivers/soundwire/intel_auxdevice.c | 1 + drivers/spi/spi-amd.c | 17 + drivers/spi/spi-bcm-qspi.c | 9 +- drivers/spi/spi-bcm2835.c | 4 +- drivers/spi/spi-bcm63xx-hsspi.c | 6 +- drivers/spi/spi-bcm63xx.c | 5 +- drivers/spi/spi-bcmbca-hsspi.c | 6 +- drivers/spi/spi-cadence-quadspi.c | 3 +- drivers/spi/spi-cadence-xspi.c | 16 +- drivers/spi/spi-ch341.c | 6 + drivers/spi/spi-jcore.c | 2 + drivers/spi/spi-ljca.c | 7 +- drivers/spi/spi-npcm-fiu.c | 8 + drivers/spi/spi-nxp-fspi.c | 31 +- drivers/spi/spi-zynq-qspi.c | 13 +- drivers/staging/greybus/uart.c | 32 +- drivers/staging/media/av7110/sp8870.c | 5 +- drivers/staging/media/imx/imx-media-csc-scaler.c | 1 + drivers/staging/media/meson/vdec/vdec.c | 2 +- drivers/staging/rtl8723bs/core/rtw_recv.c | 101 +- drivers/staging/rtl8723bs/hal/sdio_ops.c | 7 + drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 5 +- .../int340x_thermal/processor_thermal_device.c | 10 +- .../intel/int340x_thermal/processor_thermal_rfim.c | 11 +- drivers/thermal/intel/intel_powerclamp.c | 3 +- drivers/thunderbolt/icm.c | 6 +- drivers/tty/serial/8250/8250_exar.c | 36 +- drivers/tty/serial/8250/8250_lpss.c | 7 +- drivers/tty/serial/8250/8250_omap.c | 15 +- drivers/tty/serial/8250/8250_platform.c | 1 + drivers/tty/serial/8250/8250_pnp.c | 1 + drivers/tty/serial/pch_uart.c | 5 + drivers/tty/serial/pmac_zilog.c | 4 +- drivers/tty/serial/qcom_geni_serial.c | 8 + drivers/tty/serial/serial_core.c | 7 + drivers/ufs/core/ufs_bsg.c | 10 +- drivers/ufs/core/ufshcd.c | 21 +- drivers/uio/uio_sercos3.c | 1 + drivers/usb/class/cdc-acm.c | 6 +- drivers/usb/core/driver.c | 1 - drivers/usb/core/message.c | 1 + drivers/usb/fotg210/fotg210-udc.c | 17 +- drivers/usb/gadget/configfs.c | 4 +- drivers/usb/gadget/function/u_audio.c | 12 +- drivers/usb/gadget/legacy/inode.c | 24 +- drivers/usb/gadget/udc/fsl_qe_udc.c | 8 +- drivers/usb/misc/cypress_cy7c63.c | 8 +- drivers/usb/misc/uss720.c | 1 + drivers/usb/mtu3/mtu3_trace.h | 4 +- drivers/usb/musb/musb_host.c | 14 +- drivers/usb/serial/option.c | 5 + drivers/usb/serial/sierra.c | 3 +- drivers/usb/serial/usb_wwan.c | 3 + drivers/usb/typec/ucsi/ucsi_ccg.c | 15 +- drivers/vdpa/mlx5/net/mlx5_vnet.c | 23 +- drivers/vdpa/vdpa_sim/vdpa_sim.c | 3 +- drivers/vfio/pci/mlx5/cmd.c | 2 +- drivers/video/backlight/lm3630a_bl.c | 1 + drivers/video/backlight/qcom-wled.c | 35 +- drivers/video/fbdev/atmel_lcdfb.c | 24 +- drivers/video/fbdev/core/bitblit.c | 7 +- drivers/video/fbdev/core/fbcon.c | 7 + drivers/video/fbdev/omap2/omapfb/dss/dsi.c | 9 +- drivers/video/fbdev/platinumfb.c | 35 +- drivers/video/fbdev/sh_mobile_lcdcfb.c | 6 +- drivers/video/fbdev/smscufx.c | 9 +- drivers/video/fbdev/ssd1307fb.c | 6 +- drivers/video/fbdev/udlfb.c | 36 +- drivers/video/fbdev/xen-fbfront.c | 7 +- drivers/virtio/virtio_balloon.c | 6 +- drivers/virtio/virtio_ring.c | 8 + drivers/w1/masters/ds2482.c | 8 + drivers/watchdog/rzv2h_wdt.c | 59 +- drivers/xen/gntdev.c | 7 + drivers/xen/privcmd.c | 47 +- drivers/xen/xen-pciback/pci_stub.c | 7 +- fs/affs/bitmap.c | 2 +- fs/afs/rxrpc.c | 4 +- fs/aio.c | 18 +- fs/btrfs/inode.c | 3 - fs/btrfs/relocation.c | 13 +- fs/btrfs/super.c | 3 + fs/btrfs/volumes.c | 6 +- fs/ceph/addr.c | 15 +- fs/ceph/caps.c | 23 +- fs/ceph/crypto.c | 3 + fs/ceph/dir.c | 14 +- fs/ceph/inode.c | 3 +- fs/ceph/mds_client.c | 28 +- fs/ceph/mdsmap.c | 12 +- fs/ceph/snap.c | 7 +- fs/ceph/xattr.c | 10 + fs/crypto/keysetup.c | 8 +- fs/dax.c | 12 +- fs/dcache.c | 16 +- fs/dlm/lowcomms.c | 6 +- fs/erofs/decompressor.c | 2 +- fs/exec.c | 11 +- fs/exfat/balloc.c | 31 +- fs/exfat/dir.c | 8 +- fs/exfat/namei.c | 27 +- fs/exportfs/expfs.c | 6 +- fs/ext4/balloc.c | 6 +- fs/ext4/dir.c | 20 +- fs/ext4/ext4.h | 5 +- fs/ext4/extents.c | 26 +- fs/ext4/indirect.c | 17 + fs/ext4/inode.c | 20 +- fs/ext4/namei.c | 11 +- fs/ext4/super.c | 24 +- fs/f2fs/compress.c | 10 +- fs/f2fs/data.c | 11 +- fs/f2fs/file.c | 49 +- fs/f2fs/gc.c | 9 +- fs/f2fs/segment.c | 3 +- fs/f2fs/super.c | 42 +- fs/fat/fat.h | 2 +- fs/fat/fatent.c | 21 +- fs/fat/file.c | 3 +- fs/fat/misc.c | 6 +- fs/fat/namei_msdos.c | 3 + fs/fs-writeback.c | 7 +- fs/fs_pin.c | 9 +- fs/fuse/dir.c | 3 + fs/fuse/file.c | 9 + fs/fuse/virtio_fs.c | 21 +- fs/gfs2/lops.c | 4 +- fs/hfsplus/extents.c | 2 + fs/hugetlbfs/inode.c | 2 +- fs/iomap/fiemap.c | 8 +- fs/isofs/inode.c | 2 + fs/isofs/isofs.h | 2 + fs/isofs/rock.c | 11 +- fs/jbd2/journal.c | 2 +- fs/lockd/svclock.c | 2 + fs/namei.c | 29 - fs/namespace.c | 20 +- fs/netfs/objects.c | 4 +- fs/netfs/rolling_buffer.c | 2 +- fs/nfs/blocklayout/blocklayout.h | 5 - fs/nfs/blocklayout/rpc_pipefs.c | 79 +- fs/nfs/callback_proc.c | 3 +- fs/nfs/callback_xdr.c | 2 +- fs/nfs/dir.c | 6 + fs/nfs/filelayout/filelayout.c | 8 +- fs/nfs/flexfilelayout/flexfilelayout.c | 25 +- fs/nfs/netns.h | 5 +- fs/nfs/nfs4_fs.h | 2 + fs/nfs/nfs4proc.c | 8 + fs/nfs/nfs4state.c | 78 +- fs/nfs/pnfs.c | 24 +- fs/nfs/pnfs.h | 2 +- fs/nfsd/nfs3acl.c | 15 + fs/nfsd/nfs4idmap.c | 4 +- fs/nfsd/nfs4proc.c | 4 +- fs/nfsd/nfs4recover.c | 42 +- fs/nfsd/nfs4state.c | 43 +- fs/nfsd/nfs4xdr.c | 26 +- fs/nfsd/nfsctl.c | 73 +- fs/nfsd/nfsproc.c | 19 +- fs/nfsd/xdr4.h | 1 + fs/nilfs2/dir.c | 34 + fs/nilfs2/inode.c | 6 - fs/nilfs2/segment.c | 2 + fs/nilfs2/sysfs.c | 5 +- fs/nilfs2/the_nilfs.c | 34 +- fs/notify/fanotify/fanotify.c | 7 +- fs/notify/fanotify/fanotify.h | 21 +- fs/ntfs3/attrib.c | 2 +- fs/ntfs3/dir.c | 14 +- fs/ntfs3/fslog.c | 29 +- fs/ntfs3/index.c | 14 +- fs/ntfs3/inode.c | 10 +- fs/ntfs3/namei.c | 9 +- fs/ntfs3/ntfs_fs.h | 2 + fs/ntfs3/super.c | 18 +- fs/ocfs2/cluster/heartbeat.c | 39 +- fs/ocfs2/cluster/netdebug.c | 4 + fs/ocfs2/cluster/nodemanager.c | 10 +- fs/ocfs2/cluster/quorum.c | 7 +- fs/ocfs2/cluster/quorum.h | 1 + fs/ocfs2/dir.c | 76 +- fs/ocfs2/dlm/dlmconvert.c | 10 +- fs/ocfs2/dlm/dlmdebug.c | 5 + fs/ocfs2/dlm/dlmdomain.c | 3 +- fs/ocfs2/dlm/dlmlock.c | 8 +- fs/ocfs2/dlmglue.c | 6 + fs/ocfs2/file.c | 118 +- fs/ocfs2/filecheck.c | 5 +- fs/ocfs2/journal.c | 3 +- fs/ocfs2/journal.h | 1 - fs/ocfs2/quota_local.c | 12 +- fs/ocfs2/refcounttree.c | 15 +- fs/ocfs2/super.c | 17 +- fs/ocfs2/xattr.c | 142 +- fs/overlayfs/copy_up.c | 112 +- fs/overlayfs/dir.c | 22 +- fs/overlayfs/inode.c | 14 +- fs/overlayfs/namei.c | 8 +- fs/overlayfs/overlayfs.h | 8 +- fs/overlayfs/readdir.c | 29 +- fs/overlayfs/super.c | 17 +- fs/pnode.c | 125 +- fs/proc/task_mmu.c | 9 +- fs/read_write.c | 8 +- fs/romfs/super.c | 8 + fs/signalfd.c | 28 +- fs/smb/client/cached_dir.c | 30 +- fs/smb/client/cifsacl.c | 9 +- fs/smb/client/cifsfs.c | 61 +- fs/smb/client/cifsfs.h | 4 +- fs/smb/client/cifsglob.h | 5 +- fs/smb/client/cifspdu.h | 30 - fs/smb/client/cifssmb.c | 69 +- fs/smb/client/connect.c | 4 +- fs/smb/client/inode.c | 46 +- fs/smb/client/readdir.c | 3 + fs/smb/client/reparse.c | 67 +- fs/smb/client/sess.c | 6 +- fs/smb/client/smb2ops.c | 122 +- fs/smb/client/smb2pdu.c | 12 +- fs/smb/client/transport.c | 6 + fs/smb/common/smb2pdu.h | 14 +- fs/smb/server/auth.c | 3 +- fs/smb/server/connection.c | 22 + fs/smb/server/mgmt/user_config.c | 6 +- fs/smb/server/mgmt/user_session.c | 4 +- fs/smb/server/misc.c | 8 +- fs/smb/server/oplock.c | 16 +- fs/smb/server/server.c | 21 + fs/smb/server/smb2pdu.c | 426 +- fs/smb/server/smb2pdu.h | 1 + fs/smb/server/smb_common.c | 6 +- fs/smb/server/smbacl.c | 53 +- fs/smb/server/transport_ipc.c | 16 +- fs/smb/server/transport_rdma.c | 1 - fs/smb/server/transport_tcp.c | 15 + fs/smb/server/vfs.c | 133 +- fs/smb/server/vfs.h | 3 +- fs/smb/server/vfs_cache.c | 46 +- fs/smb/server/vfs_cache.h | 2 + fs/splice.c | 12 +- fs/stat.c | 6 +- fs/udf/balloc.c | 12 +- fs/udf/inode.c | 33 +- fs/udf/super.c | 5 +- fs/udf/truncate.c | 2 +- fs/udf/udfdecl.h | 3 +- fs/ufs/cylinder.c | 31 +- fs/ufs/dir.c | 2 +- fs/verity/open.c | 38 +- fs/xfs/libxfs/xfs_attr_leaf.c | 13 + fs/xfs/libxfs/xfs_da_btree.c | 14 + fs/xfs/libxfs/xfs_inode_fork.c | 4 +- fs/xfs/libxfs/xfs_symlink_remote.c | 8 +- fs/xfs/libxfs/xfs_symlink_remote.h | 2 +- fs/xfs/libxfs/xfs_trans_space.c | 6 +- fs/xfs/scrub/agheader.c | 15 +- fs/xfs/scrub/agheader_repair.c | 6 +- fs/xfs/scrub/alloc_repair.c | 11 +- fs/xfs/scrub/attr.c | 17 +- fs/xfs/scrub/attr_repair.c | 18 +- fs/xfs/scrub/bitmap.c | 20 + fs/xfs/scrub/bmap.c | 7 + fs/xfs/scrub/btree.c | 16 +- fs/xfs/scrub/common.c | 7 +- fs/xfs/scrub/dabtree.c | 27 +- fs/xfs/scrub/dir.c | 2 + fs/xfs/scrub/dirtree_repair.c | 76 +- fs/xfs/scrub/dqiterate.c | 1 + fs/xfs/scrub/fscounters.c | 14 +- fs/xfs/scrub/ialloc_repair.c | 8 +- fs/xfs/scrub/inode.c | 2 +- fs/xfs/scrub/inode_repair.c | 39 +- fs/xfs/scrub/iscan.c | 2 +- fs/xfs/scrub/newbt.c | 13 - fs/xfs/scrub/newbt.h | 1 - fs/xfs/scrub/parent_repair.c | 4 + fs/xfs/scrub/quota.c | 8 +- fs/xfs/scrub/quota_repair.c | 39 +- fs/xfs/scrub/quotacheck_repair.c | 54 +- fs/xfs/scrub/readdir.c | 2 +- fs/xfs/scrub/reap.c | 2 +- fs/xfs/scrub/refcount.c | 17 +- fs/xfs/scrub/repair.h | 2 +- fs/xfs/scrub/rmap.c | 20 +- fs/xfs/scrub/stats.c | 5 +- fs/xfs/scrub/symlink.c | 17 +- fs/xfs/scrub/trace.c | 13 + fs/xfs/scrub/trace.h | 10 +- fs/xfs/scrub/xfarray.c | 4 +- fs/xfs/xfs_dquot.c | 20 +- fs/xfs/xfs_dquot.h | 2 +- fs/xfs/xfs_handle.c | 2 +- fs/xfs/xfs_inode_item_recover.c | 20 +- fs/xfs/xfs_qm.c | 6 +- fs/xfs/xfs_trans_dquot.c | 6 +- include/asm-generic/bitops/le.h | 18 +- include/dt-bindings/arm/qcom,ids.h | 1 + include/linux/device.h | 5 + include/linux/device/bus.h | 3 - include/linux/fault-inject.h | 10 +- include/linux/fs.h | 4 +- include/linux/hid.h | 1 + include/linux/hiddev.h | 2 + include/linux/hugetlb.h | 4 +- include/linux/interrupt.h | 2 + include/linux/libata.h | 1 + include/linux/mempool.h | 7 + include/linux/pci.h | 2 +- include/linux/remoteproc.h | 2 + include/linux/rtc.h | 2 + include/math-emu/op-common.h | 23 +- include/math-emu/soft-fp.h | 8 + include/media/v4l2-ctrls.h | 6 + include/net/addrconf.h | 3 + include/net/gso.h | 8 + include/net/mptcp.h | 9 + include/net/netfilter/nf_conntrack_expect.h | 3 + include/trace/events/huge_memory.h | 12 +- include/trace/misc/nfs.h | 10 + include/uapi/linux/pci_regs.h | 6 + include/video/maxinefb.h | 4 +- init/main.c | 6 +- init/version.c | 3 + io_uring/io-wq.c | 14 +- io_uring/io_uring.c | 3 +- io_uring/kbuf.c | 4 +- io_uring/net.c | 12 + io_uring/rsrc.c | 4 +- io_uring/sqpoll.c | 28 +- io_uring/sqpoll.h | 3 +- io_uring/tctx.c | 6 +- io_uring/timeout.c | 3 + io_uring/waitid.c | 5 + ipc/mqueue.c | 7 + ipc/msgutil.c | 3 +- ipc/namespace.c | 9 +- ipc/shm.c | 23 +- kernel/bpf/queue_stack_maps.c | 3 + kernel/cgroup/cgroup.c | 2 +- kernel/cpu_pm.c | 9 +- kernel/debug/gdbstub.c | 55 +- kernel/fork.c | 4 + kernel/futex/core.c | 8 +- kernel/futex/pi.c | 100 +- kernel/irq/internals.h | 2 + kernel/irq/irqdomain.c | 4 +- kernel/irq/manage.c | 31 +- kernel/kcov.c | 8 + kernel/kcsan/core.c | 7 +- kernel/module/kallsyms.c | 31 +- kernel/module/main.c | 612 +- kernel/reboot.c | 9 + kernel/resource.c | 11 +- kernel/sched/cpufreq_schedutil.c | 14 +- kernel/sched/ext.c | 2 +- kernel/sched/fair.c | 7 +- kernel/seccomp.c | 7 +- kernel/sys.c | 3 + kernel/time/itimer.c | 2 +- kernel/time/namespace.c | 2 +- kernel/time/posix-cpu-timers.c | 4 +- kernel/time/timekeeping.c | 3 +- kernel/trace/ring_buffer.c | 2 + kernel/trace/trace_events_hist.c | 105 +- kernel/ucount.c | 21 +- lib/842/842_decompress.c | 7 +- lib/buildid.c | 4 + lib/decompress_bunzip2.c | 6 +- lib/fault-inject.c | 7 +- lib/klist.c | 16 +- lib/kobject_uevent.c | 8 +- mm/damon/core.c | 19 +- mm/damon/sysfs-schemes.c | 6 +- mm/damon/sysfs.c | 21 + mm/damon/tests/core-kunit.h | 316 + mm/hugetlb.c | 153 +- mm/hugetlb_cgroup.c | 33 + mm/khugepaged.c | 11 +- mm/kmemleak.c | 32 +- mm/madvise.c | 12 +- mm/memcontrol-v1.c | 12 +- mm/memcontrol.c | 13 + mm/mempolicy.c | 14 +- mm/migrate.c | 6 +- mm/mlock.c | 2 +- mm/nommu.c | 6 +- mm/page_alloc.c | 18 +- mm/percpu.c | 5 +- mm/rmap.c | 11 +- mm/shmem.c | 4 +- mm/slab_common.c | 17 +- mm/vmscan.c | 19 +- mm/zswap.c | 3 +- net/8021q/vlan_dev.c | 33 +- net/bluetooth/6lowpan.c | 1 + net/bluetooth/hci_debugfs.c | 9 + net/bluetooth/hci_event.c | 7 + net/bluetooth/hci_sync.c | 30 + net/bluetooth/l2cap_core.c | 41 +- net/bluetooth/l2cap_sock.c | 4 + net/bridge/netfilter/ebtables.c | 12 +- net/ceph/mon_client.c | 5 +- net/ceph/osd_client.c | 13 +- net/ceph/osdmap.c | 16 +- net/core/gro.c | 4 + net/core/gso.c | 1 + net/core/skbuff.c | 15 +- net/ipv4/af_inet.c | 3 + net/ipv4/inet_connection_sock.c | 16 +- net/ipv4/inet_hashtables.c | 5 +- net/ipv4/ip_gre.c | 42 +- net/ipv4/ipmr.c | 1 + net/ipv4/metrics.c | 5 + net/ipv4/netfilter/nf_nat_h323.c | 22 +- net/ipv4/netfilter/nf_reject_ipv4.c | 11 +- net/ipv4/netfilter/nf_tproxy_ipv4.c | 2 +- net/ipv4/syncookies.c | 2 + net/ipv4/sysctl_net_ipv4.c | 2 + net/ipv4/tcp_cong.c | 4 +- net/ipv4/tcp_input.c | 4 +- net/ipv4/tcp_output.c | 2 +- net/ipv6/addrconf.c | 46 +- net/ipv6/inet6_hashtables.c | 4 +- net/ipv6/ip6_gre.c | 5 +- net/ipv6/ip6_offload.c | 4 + net/ipv6/netfilter/nf_reject_ipv6.c | 13 +- net/ipv6/netfilter/nf_tproxy_ipv6.c | 2 +- net/ipv6/reassembly.c | 1 + net/ipv6/route.c | 2 +- net/ipv6/udp.c | 13 + net/mac80211/ibss.c | 4 +- net/mptcp/protocol.c | 9 +- net/mptcp/subflow.c | 35 +- net/netfilter/nf_conntrack_expect.c | 35 +- net/netfilter/nf_conntrack_netlink.c | 8 +- net/netfilter/nf_conntrack_proto_tcp.c | 6 +- net/netfilter/nf_nat_sip.c | 20 +- net/netfilter/nft_meta.c | 6 +- net/netfilter/nft_rt.c | 6 +- net/netfilter/nft_xfrm.c | 9 +- net/packet/af_packet.c | 12 +- net/rds/ib_cm.c | 6 +- net/rds/ib_rdma.c | 4 +- net/rds/ib_recv.c | 13 +- net/rds/message.c | 26 + net/rds/rdma.c | 63 +- net/rds/rds.h | 15 +- net/rds/send.c | 18 +- net/rxrpc/recvmsg.c | 22 +- net/rxrpc/rxperf.c | 16 +- net/sched/act_ct.c | 5 +- net/sched/act_ife.c | 4 + net/sched/cls_bpf.c | 28 +- net/sched/cls_flower.c | 50 +- net/sched/sch_generic.c | 10 +- net/sched/sch_teql.c | 60 +- net/sctp/associola.c | 4 + net/sctp/endpointola.c | 4 + net/sctp/socket.c | 26 +- net/smc/smc_tx.c | 7 + net/sunrpc/auth_gss/svcauth_gss.c | 29 +- net/sunrpc/svc.c | 9 +- net/sunrpc/svc_xprt.c | 24 +- net/sunrpc/svcauth_unix.c | 7 + net/sunrpc/svcsock.c | 86 +- net/sunrpc/xprtrdma/rpc_rdma.c | 27 +- net/sunrpc/xprtrdma/svc_rdma_transport.c | 3 +- net/sunrpc/xprtrdma/verbs.c | 9 +- net/tipc/group.c | 19 +- net/tipc/socket.c | 12 +- net/unix/sysctl_net_unix.c | 4 +- net/vmw_vsock/vmci_transport.c | 34 +- net/wireless/nl80211.c | 4 + net/xdp/xsk_buff_pool.c | 2 + net/xdp/xsk_queue.c | 12 +- rust/bindings/lib.rs | 1 + rust/kernel/block/mq/gen_disk.rs | 10 +- rust/uapi/lib.rs | 1 + scripts/kconfig/conf.c | 17 + scripts/link-vmlinux.sh | 20 +- security/apparmor/include/label.h | 6 +- security/apparmor/include/policy_ns.h | 16 + security/apparmor/label.c | 1 - security/apparmor/mount.c | 4 +- security/apparmor/policy.c | 16 + security/apparmor/policy_ns.c | 2 +- security/landlock/fs.c | 10 +- sound/core/compress_offload.c | 28 +- sound/core/control.c | 2 + sound/core/init.c | 12 +- sound/core/seq/oss/seq_oss_device.h | 1 + sound/core/seq/oss/seq_oss_event.c | 3 + sound/core/seq/oss/seq_oss_init.c | 2 + sound/core/ump_convert.c | 2 +- sound/drivers/aloop.c | 11 +- sound/drivers/pcmtest.c | 42 +- sound/mips/sgio2audio.c | 13 +- sound/oss/dmasound/dmasound_q40.c | 65 +- sound/pci/cs46xx/dsp_spos.c | 2 +- sound/pci/hda/hda_codec.c | 12 + sound/pci/hda/hda_intel.c | 9 + sound/pci/hda/hda_sysfs.c | 4 + sound/pci/hda/patch_conexant.c | 17 +- sound/pci/hda/patch_realtek.c | 98 +- sound/pci/hda/patch_via.c | 1 + sound/soc/amd/acp-config.c | 14 + sound/soc/amd/acp/acp3x-es83xx/acp3x-es83xx.c | 8 + sound/soc/amd/ps/pci-ps.c | 2 + sound/soc/amd/yc/acp6x-mach.c | 21 + sound/soc/codecs/arizona-jack.c | 1 + sound/soc/codecs/hdac_hda.c | 16 + sound/soc/codecs/hdac_hdmi.c | 10 +- sound/soc/codecs/lpass-wsa-macro.c | 42 +- sound/soc/codecs/max98396.c | 24 +- sound/soc/codecs/max98926.c | 2 +- sound/soc/codecs/pcm6240.c | 2 - sound/soc/codecs/rt5682s.c | 4 +- sound/soc/codecs/rt712-sdca-dmic.c | 4 +- sound/soc/codecs/rt712-sdca.c | 1 + sound/soc/codecs/rt712-sdca.h | 1 + sound/soc/codecs/sma1303.c | 2 + sound/soc/codecs/tlv320aic26.c | 6 + sound/soc/codecs/tlv320aic32x4-clk.c | 8 +- sound/soc/codecs/wcd9335.c | 25 +- sound/soc/codecs/wm8994.c | 3 + sound/soc/codecs/wsa884x.c | 11 +- sound/soc/intel/atom/sst/sst_acpi.c | 14 +- sound/soc/intel/boards/bytcr_rt5651.c | 17 + sound/soc/qcom/qdsp6/q6afe.c | 10 +- sound/soc/qcom/qdsp6/q6apm.c | 1 + sound/soc/sdw_utils/soc_sdw_rt711.c | 1 + sound/soc/sof/intel/mtl.c | 23 + sound/soc/ti/davinci-mcasp.c | 1 + sound/synth/emux/emux.c | 10 +- sound/synth/emux/soundfont.c | 9 + sound/usb/line6/pcm.c | 8 + sound/usb/mixer_maps.c | 27 + sound/usb/pcm.c | 3 +- sound/usb/quirks-table.h | 22 + sound/usb/quirks.c | 2 + sound/usb/usx2y/usbusx2yaudio.c | 1 - tools/lib/api/fd/array.c | 5 +- tools/lib/bpf/libbpf.c | 10 +- tools/lib/bpf/ringbuf.c | 2 +- tools/lib/thermal/include/thermal.h | 4 +- tools/objtool/check.c | 1 + tools/perf/arch/loongarch/util/header.c | 2 +- tools/sched_ext/scx_flatcg.bpf.c | 3 + tools/testing/selftests/core/unshare_test.c | 19 +- tools/testing/selftests/ftrace/ftracetest | 3 + tools/testing/selftests/net/fin_ack_lat.c | 2 +- tools/testing/selftests/net/reuseport_bpf_numa.c | 24 + tools/testing/selftests/seccomp/seccomp_bpf.c | 179 + virt/kvm/guest_memfd.c | 8 +- virt/kvm/kvm_main.c | 31 +- 1298 files changed, 89658 insertions(+), 5679 deletions(-)
Greg Kroah-Hartman
maintainerPATCH 4/1536 Revert "s390/uv: Dont return 0 from make_hva_secure() if the operation was not successful"
6.12-stable review patch. If anyone has any objections, please let me know.
------------------
This reverts commit cd78dd7fb054945c81d7106a094590be36f0553a.
--- arch/s390/kernel/uv.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
arch/s390/kernel/uv.c +1 -4
@@ -393,11 +393,8 @@ int make_hva_secure(struct mm_struct *mm, unsigned long hva, struct uv_cb_headerfolio_walk_end (&fw, vma);mmap_read_unlock (mm); -if (rc == -E2BIG || rc == -EBUSY ) { +if (rc == -E2BIG || rc == -EBUSY ) rc =s390_wiggle_split_folio (mm, folio, rc == -E2BIG ); -if (!rc) - rc = -EAGAIN ; - }folio_put (folio);return rc;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 5/1536 Revert "KVM: s390: Fix FOLL_*/FAULT_FLAG_* confusion"
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
This reverts commit f5b6a9fa37d0770f9977b9b3b9fb1dc6cb0423f3.
--- arch/s390/kvm/kvm-s390.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-)
arch/s390/kvm/kvm-s390.c +12 -12
@@ -4748,12 +4748,12 @@ static void kvm_s390_assert_primary_as(struct kvm_vcpu *vcpu)* @vcpu: the vCPU whose gmap is to be fixed up * @gfn: the guest frame number used for memslots (including fake memslots) * @gaddr: the gmap address, does not have to match @gfn for ucontrol gmaps -* @foll: FOLL_* flags +* @flags: FOLL_* flags * * Return: 0 on success, < 0 in case of error. * Context: The mm lock must not be held before calling. May sleep. */ -int __kvm_s390_handle_dat_fault (struct kvm_vcpu *vcpu,gfn_t gfn,gpa_t gaddr,unsigned int foll) +int __kvm_s390_handle_dat_fault (struct kvm_vcpu *vcpu,gfn_t gfn,gpa_t gaddr,unsigned int flags) {struct kvm_memory_slot *slot;unsigned int fault_flags;
@@ -4767,13 +4767,13 @@ int __kvm_s390_handle_dat_fault(struct kvm_vcpu *vcpu, gfn_t gfn, gpa_t gaddr, uif (!slot || slot->flags &KVM_MEMSLOT_INVALID )return vcpu_post_run_addressing_exception (vcpu); - fault_flags = foll &FOLL_WRITE ?FAULT_FLAG_WRITE :0 ; + fault_flags = flags &FOLL_WRITE ?FAULT_FLAG_WRITE :0 ;if (vcpu->arch.gmap->pfault_enabled) - foll |=FOLL_NOWAIT ; + flags |=FOLL_NOWAIT ; vmaddr =__gfn_to_hva_memslot (slot, gfn); try_again: - pfn =__kvm_faultin_pfn (slot, gfn, foll, &writable, &page); + pfn =__kvm_faultin_pfn (slot, gfn, flags, &writable, &page);/* Access outside memory, inject addressing exception */ if (is_noslot_pfn (pfn))
@@ -4789,7 +4789,7 @@ int __kvm_s390_handle_dat_fault(struct kvm_vcpu *vcpu, gfn_t gfn, gpa_t gaddr, ureturn 0 ; vcpu->stat.pfault_sync++;/* Could not setup async pfault, try again synchronously */ - foll &= ~FOLL_NOWAIT ; + flags &= ~FOLL_NOWAIT ; goto try_again; }/* Any other error */
@@ -4809,7 +4809,7 @@ int __kvm_s390_handle_dat_fault(struct kvm_vcpu *vcpu, gfn_t gfn, gpa_t gaddr, ureturn rc; } -static int vcpu_dat_fault_handler (struct kvm_vcpu *vcpu,unsigned long gaddr,unsigned int foll) +static int vcpu_dat_fault_handler (struct kvm_vcpu *vcpu,unsigned long gaddr,unsigned int flags) {unsigned long gaddr_tmp;gfn_t gfn;
@@ -4834,18 +4834,18 @@ static int vcpu_dat_fault_handler(struct kvm_vcpu *vcpu, unsigned long gaddr, un } gfn =gpa_to_gfn (gaddr_tmp); } -return __kvm_s390_handle_dat_fault (vcpu, gfn, gaddr, foll); +return __kvm_s390_handle_dat_fault (vcpu, gfn, gaddr, flags); }static int vcpu_post_run_handle_fault (struct kvm_vcpu *vcpu) { -unsigned int foll =0 ; +unsigned int flags =0 ;unsigned long gaddr;int rc; gaddr = current->thread.gmap_teid.addr *PAGE_SIZE ;if (kvm_s390_cur_gmap_fault_is_write ()) - foll =FOLL_WRITE ; + flags =FAULT_FLAG_WRITE ;switch (current->thread.gmap_int_code &PGM_INT_CODE_MASK ) {case 0 :
@@ -4887,7 +4887,7 @@ static int vcpu_post_run_handle_fault(struct kvm_vcpu *vcpu)send_sig (SIGSEGV , current,0 );if (rc != -ENXIO )break ; - foll =FOLL_WRITE ; + flags =FAULT_FLAG_WRITE ; fallthrough;case PGM_PROTECTION :case PGM_SEGMENT_TRANSLATION :
@@ -4897,7 +4897,7 @@ static int vcpu_post_run_handle_fault(struct kvm_vcpu *vcpu)case PGM_REGION_SECOND_TRANS :case PGM_REGION_THIRD_TRANS :kvm_s390_assert_primary_as (vcpu); -return vcpu_dat_fault_handler (vcpu, gaddr, foll); +return vcpu_dat_fault_handler (vcpu, gaddr, flags);default :KVM_BUG (1 , vcpu->kvm,"Unexpected program interrupt 0x%x, TEID 0x%016lx" , current->thread.gmap_int_code, current->thread.gmap_teid.val);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 3/1536 KVM: arm64: Transfer the hyp stack pages out of the host stage-2
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Fuad Tabba <[email protected]>
[ Upstream commit 3a8c562892b96f35bba1e00d5e455a15963bbb92 ]
fix_host_ownership() walks only the linear-map alias of each memblock region, and the per-CPU hyp stack, mapped in the private VA range for its guard page, has none.
Walk each stack's VA range with the same walker.
[ 38f9e4b905a0 ("arm64: kvm: Introduce nvhe stack size constants") is
not backported because it converts nvhe stack code in eight files to NVHE_STACK_SIZE, and the hyp stack here is one page, so PAGE_SIZE replaces it. ]
--- arch/arm64/kvm/hyp/nvhe/setup.c | 10 ++++++++++ 1 file changed, 10 insertions(+)
arch/arm64/kvm/hyp/nvhe/setup.c +10 -0
@@ -264,6 +264,16 @@ static int fix_host_ownership(void)return ret; } +/* The stacks sit in the private VA range, not the linear map. */ +for (i =0 ; i < hyp_nr_cpus; i++) { +struct kvm_nvhe_init_params *params =per_cpu_ptr (&kvm_init_params, i); +u64 start = params->stack_hyp_va -PAGE_SIZE ; + + ret =kvm_pgtable_walk (&pkvm_pgtable, start,PAGE_SIZE , &walker); +if (ret) +return ret; + } +return 0 ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 7/1536 Revert "KVM: s390: move gmap_shadow_pgt_lookup() into kvm"
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
This reverts commit 4f2fe83204ec878499b33b260d9b1b8c8c20f512.
--- arch/s390/include/asm/gmap.h | 3 ++- arch/s390/kvm/gaccess.c | 42 +--------------------------------- arch/s390/kvm/gmap.h | 2 -- arch/s390/mm/gmap.c | 44 ++++++++++++++++++++++++++++++++++-- 4 files changed, 45 insertions(+), 46 deletions(-)
arch/s390/include/asm/gmap.h +2 -1
@@ -134,6 +134,8 @@ int gmap_shadow_sgt(struct gmap *sg, unsigned long saddr, unsigned long sgt, int fake);int gmap_shadow_pgt (struct gmap *sg,unsigned long saddr,unsigned long pgt,int fake); +int gmap_shadow_pgt_lookup (struct gmap *sg,unsigned long saddr, +unsigned long *pgt,int *dat_protection,int *fake);int gmap_shadow_page (struct gmap *sg,unsigned long saddr,pte_t pte);void gmap_register_pte_notifier (struct gmap_notifier *);
@@ -151,7 +153,6 @@ void s390_uv_destroy_pfns(unsigned long count, unsigned long *pfns);int __s390_uv_destroy_range (struct mm_struct *mm,unsigned long start,unsigned long end,bool interruptible);int kvm_s390_wiggle_split_folio (struct mm_struct *mm,struct folio *folio,bool split); -unsigned long *gmap_table_walk (struct gmap *gmap,unsigned long gaddr,int level);/** * s390_uv_destroy_range - Destroy a range of pages in the given mm.
arch/s390/kvm/gaccess.c +1 -41
66 lines not on this page · raw message
arch/s390/kvm/gmap.h +0 -2
@@ -10,8 +10,6 @@#ifndef ARCH_KVM_S390_GMAP_H #define ARCH_KVM_S390_GMAP_H -#define GMAP_SHADOW_FAKE_TABLE 1ULL -int gmap_make_secure (struct gmap *gmap,unsigned long gaddr,void *uvcb);int gmap_convert_to_secure (struct gmap *gmap,unsigned long gaddr);int gmap_destroy_page (struct gmap *gmap,unsigned long gaddr);
arch/s390/mm/gmap.c +42 -2
62 lines not on this page · raw message
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 16/1536 kbuild: link-vmlinux.sh: improve detection of third pass requirement
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: André Draszik <[email protected]>
commit 14b8b4bf2d7bd5d58c17adbeed0edfda1dfc1a7f upstream.
It can happen that symbol sizes within .tmp_vmlinux1.kallsyms.o and .tmp_vmlinux2.kallsyms.o differ, without affecting file size on disk because of section alignment and/or padding emitted by the assembler.
link-vmlinux.sh doesn't detect this case currently and keeps using .tmp_vmlinux2.kallsyms.o to link the final vmlinux. Due to the different symbol sizes, other symbols are shifted within the final image compared to .tmp_vmlinux2, and the final comparison of System.map against "${kallsyms_sysmap}" fails with the message:
Inconsistent kallsyms data
Try "make KALLSYMS_EXTRA_PASS=1" as a workaround
This can happen in particular if the linker emits additional symbols that might have different names between our (re-)linking steps, e.g. because those names depend on the virtual address of the symbol. Linker stubs for ARM errata work-arounds are one such case.
These changed symbol names can cause the output of the token compression of kallsyms.c to change due to the changed symbol substring count, which in turn can change the size of the kallsyms_names symbol itself, causing the potential shift of subsequent symbol addresses in .tmp_vmlinux2.kallsyms.o and therefore the final image.
Update link-vmlinux.sh to not rely on file size of .tmp_vmlinux?.kallsyms.o alone but to also consider symbol offsets within to resolve this, and do a third pass if required.
--- scripts/link-vmlinux.sh | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-)
scripts/link-vmlinux.sh +19 -1
@@ -131,6 +131,18 @@ gen_btf() btf_vmlinux_bin_o=${btf_data} } +# Check if kallsymso_prev and kallsymso differ +# If symbol sizes within ${kallsymso} change, any symbols within vmlinux are +# likely to shift, invalidating ${kallsymso}. +# Since file size can remain unchanged even if symbol sizes change, compare the +# actual symbols instead of relying on file size only. +kallsymso_changed() +{ + ${NM} -n "${kallsymso_prev}" > "${kallsymso_prev}.sym" + ${NM} -n "${kallsymso}" > "${kallsymso}.sym" + ! cmp -s "${kallsymso_prev}.sym" "${kallsymso}.sym" +} + # Create ${2}.o file with all symbols from the ${1} object file kallsyms() {
@@ -151,6 +163,7 @@ kallsyms() ${CC} ${NOSTDINC_FLAGS} ${LINUXINCLUDE} ${KBUILD_CPPFLAGS} \ ${KBUILD_AFLAGS} ${KBUILD_AFLAGS_KERNEL} -c -o "${2}.o" "${2}.S" + kallsymso_prev="${kallsymso:-}" kallsymso=${2}.o }
@@ -263,7 +276,12 @@ if is_enabled CONFIG_KALLSYMS; then sysmap_and_kallsyms .tmp_vmlinux2 size2=$(${CONFIG_SHELL} "${srctree}/scripts/file-size.sh" ${kallsymso}) - if [ $size1 -ne $size2 ] || [ -n "${KALLSYMS_EXTRA_PASS}" ]; then + # Due to alignment, file size of the kallsymso object file might remain + # unchanged even if individual symbols within change size. Changed + # symbol sizes can still shift other symbols, though. Therefore, don't + # rely on file size alone. + if [ $size1 -ne $size2 ] || kallsymso_changed || \ + [ -n "${KALLSYMS_EXTRA_PASS}" ]; then vmlinux_link .tmp_vmlinux3 sysmap_and_kallsyms .tmp_vmlinux3 fi
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 17/1536 exec: cancel io_uring requests before de_thread()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christian Brauner <[email protected]>
[ Upstream commit b42c85c20d84ff3e4f0f027d6596c3b3b4a20657 ]
begin_new_exec() cancels the exec'ing thread's io_uring requests after de_thread() made it the only thread in the thread-group. Now io_uring_task_cancel() runs task work after. If it runs a create_worker_cb() item then a io-wq queued on the thread before the exec creates a new io-wq worker thread.
Said thread joins the thread-group which de_thread() just took down. The io-iwq sticks around until it notices that its workqueue is dying. But code after de_thread() relies on being single-threaded.
Move io_uring_task_cancel() before de_thread() but behind the point of no return. Any worker created during task work run from io_uring_task_cancel() is just a sibling thread that de_thread() will take down and reap.
Once io_uring_task_cancel() returned the thread has neither a task context nor a workqueue left so nothing can add a thread behind de_thread()'s back anymore.
--- fs/exec.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-)
fs/exec.c +7 -4
@@ -1257,6 +1257,13 @@ int begin_new_exec(struct linux_binprm * bprm)*/ bprm->point_of_no_return = true; +/* +* Cancel any io_uring activity across execve. This runs task work +* that may still create an io-wq worker, so do it while de_thread() +* can still zap it. +*/ +io_uring_task_cancel (); +/* Make this the only thread in the thread group */ retval =de_thread (me);if (retval)
@@ -1273,10 +1280,6 @@ int begin_new_exec(struct linux_binprm * bprm)/* see the comment in check_unsafe_exec() */ current->fs->in_exec =0 ; -/* -* Cancel any io_uring activity across execve -*/ -io_uring_task_cancel ();/* Ensure the files table is not shared. */ retval =unshare_files ();
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 18/1536 fork: move the coredump and exec checks into create_io_thread()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christian Brauner <[email protected]>
[ Upstream commit e760200370e4de054b6b5f568a7faa911e2956bb ]
Only a PF_USER_WORKER thread returns from get_signal() after a fatal signal and can go on to create a thread. get_signal() sets PF_SIGNALED before it dumps core and before it lets a PF_USER_WORKER thread return. That flags sticks.
The exec'ing thread itself is never signaled. But it doesn't need the check anyway as we moved cancellation of io_uring requests before de_thread(). create_io_thread() is the only way a signaled thread creates another one. vhost_task_create() is reached from ioctls alone.
io_should_retry_thread() doesn't retry -EINTR, so io-wq callers give up the same way they did when copy_process() refused.
Stable-dep-of: 1f978881ce6c ("fork: don't create io threads once PF_POSTCOREDUMP is set")
--- kernel/fork.c | 4 ++++ 1 file changed, 4 insertions(+)
kernel/fork.c +4 -0
@@ -2774,6 +2774,10 @@ struct task_struct *create_io_thread(int (*fn)(void *), void *arg, int node) .user_worker = 1, }; +/* A creator past its fatal signal gets no thread. */ +if (current->flags &PF_SIGNALED ) +return ERR_PTR (-EINTR ); +return copy_process (NULL ,0 , node, &args); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 19/1536 fork: dont create io threads once PF_POSTCOREDUMP is set
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Christian Brauner <[email protected]>
[ Upstream commit 1f978881ce6c9ac4f4d4a7b6a6e52339eadcd350 ]
zap_process() skips every thread that already has PF_POSTCOREDUMP set. Such a thread is past synchronize_group_exit(), so a coredump can't catch it anymore. It isn't counted in core_state->threads_remaining and it isn't sent SIGKILL.
do_exit() sets PF_POSTCOREDUMP in synchronize_group_exit() and calls io_uring_files_cancel() right after that. The cancellation runs task work and a create_worker_cb() that io-wq queued before the exit creates a new io-wq worker from there. If another thread started a coredump in the meantime that worker joins a thread-group which is already being dumped. zap_process() never saw it so it was never counted. But when it exits it sees signal->core_state in synchronize_group_exit() and decrements threads_remaining like any other thread.
So the count reaches zero one thread early and the dumper leaves coredump_wait_inactive() while a thread it counted is still running.
The task has no fatal signal pending because zap_process() deliberately didn't send it one, and it never went through get_signal() so it doesn't have PF_SIGNALED either.
Refuse to create an io thread when the creator has PF_POSTCOREDUMP. That costs nothing. io_uring_files_cancel() raises IO_WQ_BIT_EXIT before it runs any task work, so a worker created from there only ever gets to exit again, and io_should_retry_thread() doesn't retry -EINTR.
Clearing PF_POSTCOREDUMP for the new thread in copy_process() was the other option. It makes the worker a thread like any other, but it only helps while the dump hasn't started. A worker born after zap_process() has run is invisible to it whatever its flags say and still decrements threads_remaining on the way out. Refusing to create it covers both, and then no task is ever born with the flag, so there is nothing to clear.
Moving io_uring_files_cancel() ahead of synchronize_group_exit() closes the same window. It runs the cancellation, and whatever that can block on, before the thread announces itself to the dumper. A thread that blocks there never reaches coredump_task_exit() at all, so the dumper ends up waiting for a thread that never parks. Refusing the creation leaves the cancellation where it is. But it's very ugly to run io_uring work even before we did all the generic exit work.
--- kernel/fork.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
kernel/fork.c +2 -2
@@ -2774,8 +2774,8 @@ struct task_struct *create_io_thread(int (*fn)(void *), void *arg, int node) .user_worker = 1, }; -/* A creator past its fatal signal gets no thread. */ -if (current->flags &PF_SIGNALED ) +/* A creator past its fatal signal or its coredump point gets no thread. */ +if (current->flags & (PF_SIGNALED |PF_POSTCOREDUMP ))return ERR_PTR (-EINTR );return copy_process (NULL ,0 , node, &args);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 20/1536 lib/crypto: arm64: Fix lost Poly1305 carry when resuming NEON state
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jérémy Jean <[email protected]>
commit 24f07e8c07a0c0dd275331cbb41c79a78741eef9 upstream.
When poly1305_blocks_neon() resumes from a base 2^26 accumulator and the next update contains an odd number of full 16-byte blocks, it processes one leading block through poly1305_mult() so that the remaining NEON work has an even block count. That requires converting the accumulator to the base 2^64 form used by poly1305_mult(). The final ADC of that conversion stores the carry into d2, but the following accumulation and poly1305_mult() use h2. If the conversion carries across bit 128, the carry is dropped and the emitted tag is wrong.
This was introduced by Cryptogams commit 03dc4adf91c8 ("arm/poly1305-armv*.pl: optimize branches."), which removed the reduction that consumed d2 shortly before Linux imported the code. OpenSSL's copy did not take that change.
The carry is possible because the NEON code stores the accumulator [h0, h1, h2, h3, h4] in a lazily reduced, redundant base 2^26 form: its final carry chain leaves h0, h2, h3 < 2^26, but h1 and h4 may slightly exceed 2^26 - 1. For example, the reachable state
h0 = 4
h1 = 2^26
h2 = 2^26 - 1
h3 = 2^26 - 1
h4 = 2^24 - 1
represents 4 + 2^26*2^26 + (2^26-1)*2^52 + (2^26-1)*2^78 + (2^24-1)*2^104 = 2^128 + 4, despite the bit representing the 2^128 term (bit 24 of h4) not being set; the extra comes from the h1 limb being above the normal base 2^26 range. When this value is converted into the non-redundant base 2^64 form, a carry into the new 2^128 bit (in bit 0 of h2) is necessary to preserve the value.
Given the above bounds, a carry into bit 128 happens exactly when h1 >= 2^26, h2 = h3 = 2^26 - 1, and h4 mod 2^24 = 2^24 - 1.
Store the carry into h2, matching the other base 2^26 to base 2^64 conversions in poly1305_blocks() and poly1305_emit().
This bug causes an incorrect tag to be emitted. However, this is unlikely to happen in practice where Poly1305 is used with a random key, since the random key tends to distribute the accumulator values throughout their valid range. There isn't an obvious way for an attacker without knowledge of the r_key to cause [h0, h1, h2, h3, h4] to land on the precise values where this bug occurs.
[EB: Rewrote the commit message to more clearly describe the bug and
its impact, and simplified explanation about why there's a carry bit.]
--- arch/arm64/crypto/poly1305-armv8.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/crypto/poly1305-armv8.pl +1 -1
@@ -372,7 +372,7 @@ poly1305_blocks_neon: adc $h1,$h1,xzr lsr $h2,x14,#24 adds $h1,$h1,x14,lsl#40 - adc $d2,$h2,xzr // can be partially reduced... + adc $h2,$h2,xzr // preserve carry into top limb ldp $d0,$d1,[$inp],#16 // load input sub $len,$len,#16
Greg Kroah-Hartman
maintainerPATCH 21/1536 net: gso: limit recursive IP-in-IP segmentation
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Zihan Xi <[email protected]>
commit 006c8b834aed8b02bd8fb9fb05e9e7ead37d1763 upstream.
IP-in-IP GSO can re-enter inet_gso_segment() or ipv6_gso_segment() for each nested IP header. encap_level tracks header bytes, not callback depth, so a deep chain can exhaust the kernel stack. Making inet_gso_segment() stackable introduced unbounded IPv4 nesting; IPIP GSO/TSO later made the path reachable. The IPv6 stackable path was introduced separately and uses the same guard.
Count IPv4 and IPv6 GSO handler entries in skb_gso_cb, initialized once per top-level GSO operation and preserved across GRE/UDP context changes. Use the existing IP_TUNNEL_RECURSION_LIMIT for both handlers. The first five entries pass, and the sixth returns -EINVAL before dispatching another GSO callback.
[ Ting-Han: ipv6_gso_segment() still calls ipv6_hopopt_jumbo_remove()
right after skb_reset_network_header() in this version; keep the new recursion check directly after skb_reset_network_header() as upstream does, before the jumbo removal ]
--- include/net/gso.h | 8 ++++++++ net/core/gso.c | 1 + net/ipv4/af_inet.c | 3 +++ net/ipv6/ip6_offload.c | 4 ++++ 4 files changed, 16 insertions(+)
include/net/gso.h +8 -0
@@ -19,10 +19,18 @@ struct skb_gso_cb {int encap_level;__wsum csum;__u16 csum_start; +/* Number of IPv4/IPv6 GSO handler entries for this packet. */ +u8 recursion_counter; };#define SKB_GSO_CB_OFFSET 32#define SKB_GSO_CB (skb) ((struct skb_gso_cb *)((skb)->cb + SKB_GSO_CB_OFFSET)) +static inline bool gso_recursion_inc_test (struct sk_buff *skb, +unsigned int limit) +{ +return ++SKB_GSO_CB (skb)->recursion_counter > limit; +} +static inline int skb_tnl_header_len (const struct sk_buff *inner_skb) { return (skb_mac_header(inner_skb) - inner_skb->head) -
net/core/gso.c +1 -0
@@ -117,6 +117,7 @@ struct sk_buff *__skb_gso_segment(structSKB_GSO_CB (skb)->mac_offset =skb_headroom (skb);SKB_GSO_CB (skb)->encap_level =0 ; +SKB_GSO_CB (skb)->recursion_counter =0 ;skb_reset_mac_header (skb);skb_reset_mac_len (skb);
net/ipv4/af_inet.c +3 -0
@@ -1380,6 +1380,9 @@ struct sk_buff *inet_gso_segment(structint id;skb_reset_network_header (skb); +if (unlikely (gso_recursion_inc_test (skb, +IP_TUNNEL_RECURSION_LIMIT ))) + goto out; nhoff =skb_network_header (skb) -skb_mac_header (skb);if (unlikely (!pskb_may_pull (skb,sizeof (*iph)))) goto out;
net/ipv6/ip6_offload.c +4 -0
@@ -17,6 +17,7 @@#include <net/udp.h> #include <net/gro.h> #include <net/gso.h> +#include <net/ip_tunnels.h> #include "ip6_offload.h"
@@ -120,6 +121,9 @@ static struct sk_buff *ipv6_gso_segment(bool gso_partial;skb_reset_network_header (skb); +if (unlikely (gso_recursion_inc_test (skb, +IP_TUNNEL_RECURSION_LIMIT ))) + goto out; err =ipv6_hopopt_jumbo_remove (skb);if (err)return ERR_PTR (err);
Greg Kroah-Hartman
maintainerPATCH 22/1536 ext4: validate readdir offset before accessing dirent
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yao Kai <[email protected]>
commit bc4b7b0414c33b2c8898eb04386df0d21a13dad8 upstream.
A corrupted directory can trigger the following KASAN report when ext4_readdir() resumes from an invalid position:
BUG: KASAN: use-after-free in __ext4_check_dir_entry+0x5ef/0x820 Read of size 2 at addr ffff88810a646000 by task repro_linear/509 Call Trace: <TASK> dump_stack_lvl+0x53/0x70 print_report+0xd0/0x630 kasan_report+0xce/0x100 __ext4_check_dir_entry+0x5ef/0x820 ext4_readdir+0xcde/0x2b70 iterate_dir+0x1a1/0x520 __x64_sys_getdents64+0x12b/0x220 do_syscall_64+0xf9/0x540 entry_SYSCALL_64_after_hwframe+0x77/0x7f </TASK>
KASAN reports use-after-free because the out-of-bounds access lands in an adjacent freed page. The directory buffer itself is still referenced.
ext4_dir_llseek() invalidates the directory cookie so that ext4_readdir() rescans directory entries from the start of the block. The rescan checks only the lower bound of rec_len before advancing. A corrupted rec_len can therefore place the offset where the block has insufficient space for a complete directory entry. The rescan itself may dereference that truncated entry, or the main loop may pass it to __ext4_check_dir_entry(). The latter reads de->rec_len before validating the range. For example:
block offset 0 4092 4096
|---- de1.rec_len = 4092 -----|----|
de2.inode
| de2.rec_len
^ OOB, reported as UAFde2 starts at offset 4092 in this 4 KiB block. Its four-byte inode fits in the block, but its rec_len starts at offset 4096 and crosses the boundary.
The minimum safe length is inode-dependent. Encrypted and casefolded directory entries need eight additional hash bytes, while a valid metadata checksum tail is only 12 bytes.
Cache the metadata checksum feature state and derive the minimum directory entry length from the on-disk format. Use it to bound both the rescan and the offset passed to the main loop. Report an offset in a truncated block tail and skip the remainder of the block, while continuing to accept an offset exactly at the block boundary.
--- fs/ext4/dir.c | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-)
fs/ext4/dir.c +18 -2
@@ -137,6 +137,7 @@ static int ext4_readdir(struct file *filstruct buffer_head *bh =NULL ;struct fscrypt_str fstr =FSTR_INIT (NULL ,0 );struct dir_private_info *info = file->private_data; +bool has_csum =ext4_has_metadata_csum (sb); err =fscrypt_prepare_readdir (inode);if (err)
@@ -148,7 +149,7 @@ static int ext4_readdir(struct file *filreturn err;/* Can we just clear INDEX flag to ignore htree information? */ -if (!ext4_has_metadata_csum (sb)) { +if (!has_csum) {/* * We don't set the inode dirty flag since it's not * critical that it gets flushed back to the disk.
@@ -234,7 +235,10 @@ static int ext4_readdir(struct file *fil* dirent right now. Scan from the start of the block * to make sure. */ if (!inode_eq_iversion (inode, info->cookie)) { -for (i =0 ; i < sb->s_blocksize && i < offset; ) { +for (i =0 ; + i <= sb->s_blocksize - +ext4_dir_rec_len (1 , has_csum ?NULL : inode) && + i < offset;) { de = (struct ext4_dir_entry_2 *) (bh->b_data + i);/* It's too expensive to do a full
@@ -256,6 +260,17 @@ static int ext4_readdir(struct file *fil info->cookie =inode_query_iversion (inode); } +if (unlikely (offset < sb->s_blocksize && + offset > sb->s_blocksize - +ext4_dir_rec_len (1 , has_csum ?NULL : inode))) { +EXT4_ERROR_FILE (file, bh->b_blocknr, +"bad entry in directory: %s - offset=%u, size=%lu" , +"directory entry too close to block end" , + offset, sb->s_blocksize); + ctx->pos =round_up (ctx->pos, sb->s_blocksize); + goto next_block; + } +while (ctx->pos < inode->i_size && offset < sb->s_blocksize) { de = (struct ext4_dir_entry_2 *) (bh->b_data + offset);
@@ -311,6 +326,7 @@ static int ext4_readdir(struct file *fil ctx->pos +=ext4_rec_len_from_disk (de->rec_len, sb->s_blocksize); } +next_block:if ((ctx->pos < inode->i_size) && !dir_relax_shared (inode)) goto done;brelse (bh);
Greg Kroah-Hartman
maintainerPATCH 23/1536 ALSA: line6: Clear prev_fbuf on capture buffer release
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: YuanZhe Liu <[email protected]>
commit aa118c8f61d59387961d58ffae831c5259a9f222 upstream.
A KASAN slab-use-after-free read was reported in submit_audio_out_urb() when generating an impulse test signal:
BUG: KASAN: slab-use-after-free in create_impulse_test_signal sound/usb/line6/playback.c:76 [inline] BUG: KASAN: slab-use-after-free in submit_audio_out_urb+0x1848/0x1b20 sound/usb/line6/playback.c:249 Read of size 2 at addr ffff888008d74870 by task syz.2.3214/7785 Allocated by task 11: kmem_cache_alloc_noprof+0x2f0/0x390 mm/slub.c:4144 line6_buffer_acquire+0x1a1/0x220 sound/usb/line6/pcm.c:158 line6_pcm_acquire+0xb6/0x230 sound/usb/line6/pcm.c:329 line6_startup_work+0x3c/0x50 sound/usb/line6/driver.c:728 Freed by task 7785: kfree+0xf8/0x390 mm/slub.c:6566 line6_buffer_release sound/usb/line6/pcm.c:176 [inline] line6_buffer_release+0xa5/0xf0 sound/usb/line6/pcm.c:170 __line6_pcm_release sound/usb/line6/pcm.c:305 [inline] line6_pcm_release+0x5a/0x80 sound/usb/line6/pcm.c:313 snd_toneport_monitor_put+0x11b/0x190 sound/usb/line6/toneport.c:183
line6pcm->prev_fbuf points into the capture PCM stream buffer (line6pcm->in.buffer), which is updated during audio_in_callback() to feed rate synchronization, software monitoring, and impulse test signal generation on playback side.
When all capture streams are closed, line6_buffer_release() frees pstr->buffer with kfree(). However, it does not clear line6pcm->prev_fbuf. If playback is subsequently started (e.g. via impulse test signal volume control snd_line6_impulse_volume_put()), submit_audio_out_urb() dereferences the stale pointer line6pcm->prev_fbuf under in.lock, resulting in a slab-use-after-free read.
Clear prev_fbuf and prev_fsize in line6_buffer_release() when releasing the capture stream buffer under in.lock, ensuring that no stale buffer pointer can be accessed by submit_audio_out_urb().
--- sound/usb/line6/pcm.c | 8 ++++++++ 1 file changed, 8 insertions(+)
sound/usb/line6/pcm.c +8 -0
@@ -173,6 +173,14 @@ static void line6_buffer_release(structclear_bit (type, &pstr->opened);if (!pstr->opened) {line6_wait_clear_audio_urbs (line6pcm, pstr); +if (pstr == &line6pcm->in) { +/* prev_fbuf points into the capture buffer we are about +* to free; drop it while no capture URB is in flight. +*/ +guard (spinlock_irqsave)(&line6pcm->in.lock); + line6pcm->prev_fbuf =NULL ; + line6pcm->prev_fsize =0 ; + }kfree (pstr->buffer); pstr->buffer =NULL ; }
Greg Kroah-Hartman
maintainerPATCH 24/1536 drm/rockchip: dw_hdmi: Use resume_early pm ops for system suspend
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jonas Karlman <[email protected]>
[ Upstream commit af3a9eadc11896f6677bcb7102bfb7c84be48d2d ]
rockchip_drm_sys_resume()/drm_mode_config_helper_resume() is called before the resume pm ops of dw-hdmi. This result in an atomic_enable() before dw_hdmi_rockchip_resume()/dw_hdmi_resume() is called.
Resume (without changes):
- rockchip_drm_sys_resume()
- drm_mode_config_helper_resume()
- atomic_enable()
- dw_hdmi_rockchip_resume()
- dw_hdmi_resume()
- dw_hdmi_init_hw()
Change to use resume_early pm ops for system suspend to ensure pm ops for dw-hdmi is run before rockchip-drm pm ops. Also fix a possible NULL pointer dereference timing issue while at it.
Resume (with changes):
- dw_hdmi_rockchip_resume_early()
- dw_hdmi_resume()
- dw_hdmi_init_hw()
- rockchip_drm_sys_resume()
- drm_mode_config_helper_resume()
- atomic_enable()
--- drivers/gpu/drm/rockchip/dw_hdmi-rockchip.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-)
drivers/gpu/drm/rockchip/dw_hdmi-rockchip.c +4 -3
@@ -663,17 +663,18 @@ static void dw_hdmi_rockchip_remove(struct platform_device *pdev)component_del (&pdev->dev, &dw_hdmi_rockchip_ops); } -static int __maybe_unused dw_hdmi_rockchip_resume (struct device *dev) +static int __maybe_unused dw_hdmi_rockchip_resume_early (struct device *dev) {struct rockchip_hdmi *hdmi =dev_get_drvdata (dev); -dw_hdmi_resume (hdmi->hdmi); +if (hdmi) +dw_hdmi_resume (hdmi->hdmi);return 0 ; }static const struct dev_pm_ops dw_hdmi_rockchip_pm = { -SET_SYSTEM_SLEEP_PM_OPS (NULL , dw_hdmi_rockchip_resume) +SET_LATE_SYSTEM_SLEEP_PM_OPS (NULL , dw_hdmi_rockchip_resume_early) };struct platform_driver dw_hdmi_rockchip_pltfm_driver = {
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 25/1536 drm/amd/pm: Validate OD DPM triples before mutating tables
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Asad Kamal <[email protected]>
[ Upstream commit b390cb9d776039fc4f0be13b2649299079227d12 ]
vega10_odn_edit_dpm_table() and smu7_odn_edit_dpm_table() could mutate the live ODN table for valid triples, then return 0 after detecting a truncated buffer or out-of-range index. Validate all (index, clock, voltage) triples first and return -EINVAL on any failure; only then apply updates.
v2: Use distinct message for different error case, removed unused input_level from validation loop (Lijo)
v3: Reject negative level indices, input[] is long but was compared only against unsigned table bounds, so negative values could pass and truncate when assigned to uint32_t input_level.
Set DPMTABLE_OD_UPDATE_SCLK/MCLK only after validation passes, so a failed sysfs write does not leave need_update_dpm_table set for a later commit.
--- .../drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 34 ++++++++++------- .../drm/amd/pm/powerplay/hwmgr/vega10_hwmgr.c | 37 ++++++++++++------- 2 files changed, 43 insertions(+), 28 deletions(-)
drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c +20 -14
@@ -5661,23 +5661,29 @@ static int smu7_odn_edit_dpm_table(struct pp_hwmgr *hwmgr, }for (i =0 ; i < size; i +=3 ) { -if (i +3 > size || input[i] >= podn_dpm_table_in_backend->num_of_pl) { -pr_info ("invalid clock voltage input \n" ); -return 0 ; +if (i +3 > size) { +pr_info ("truncated clock/voltage input\n" ); +return -EINVAL ; } - input_level = input[i]; - input_clk = input[i+1 ] *100 ; - input_vol = input[i+2 ]; - -if (smu7_check_clk_voltage_valid (hwmgr, type, input_clk, input_vol)) { - podn_dpm_table_in_backend->entries[input_level].clock = input_clk; - podn_vdd_dep_in_backend->entries[input_level].clk = input_clk; - podn_dpm_table_in_backend->entries[input_level].vddc = input_vol; - podn_vdd_dep_in_backend->entries[input_level].vddc = input_vol; - podn_vdd_dep_in_backend->entries[input_level].vddgfx = input_vol; - }else { +if (input[i] <0 || input[i] >= podn_dpm_table_in_backend->num_of_pl) { +pr_info ("invalid clock/voltage level\n" );return -EINVAL ; } + input_clk = input[i +1 ] *100 ; + input_vol = input[i +2 ]; +if (!smu7_check_clk_voltage_valid (hwmgr, type, input_clk, input_vol)) +return -EINVAL ; + } + +for (i =0 ; i < size; i +=3 ) { + input_level = input[i]; + input_clk = input[i +1 ] *100 ; + input_vol = input[i +2 ]; + podn_dpm_table_in_backend->entries[input_level].clock = input_clk; + podn_vdd_dep_in_backend->entries[input_level].clk = input_clk; + podn_dpm_table_in_backend->entries[input_level].vddc = input_vol; + podn_vdd_dep_in_backend->entries[input_level].vddc = input_vol; + podn_vdd_dep_in_backend->entries[input_level].vddgfx = input_vol; }return 0 ;
drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega10_hwmgr.c +23 -14
@@ -5645,11 +5645,9 @@ static int vega10_odn_edit_dpm_table(struct pp_hwmgr *hwmgr,if (PP_OD_EDIT_SCLK_VDDC_TABLE == type) { dpm_table = &data->dpm_table.gfx_table; podn_vdd_dep_table = &data->odn_dpm_table.vdd_dep_on_sclk; - data->need_update_dpm_table |=DPMTABLE_OD_UPDATE_SCLK ; }else if (PP_OD_EDIT_MCLK_VDDC_TABLE == type) { dpm_table = &data->dpm_table.mem_table; podn_vdd_dep_table = &data->odn_dpm_table.vdd_dep_on_mclk; - data->need_update_dpm_table |=DPMTABLE_OD_UPDATE_MCLK ; }else if (PP_OD_RESTORE_DEFAULT_TABLE == type) {memcpy (&(data->dpm_table), &(data->golden_dpm_table),sizeof (struct vega10_dpm_table ));vega10_odn_initial_default_setting (hwmgr);
@@ -5667,21 +5665,32 @@ static int vega10_odn_edit_dpm_table(struct pp_hwmgr *hwmgr, }for (i =0 ; i < size; i +=3 ) { -if (i +3 > size || input[i] >= podn_vdd_dep_table->count) { -pr_info ("invalid clock voltage input\n" ); -return 0 ; +if (i +3 > size) { +pr_info ("truncated clock/voltage input\n" ); +return -EINVAL ; } - input_level = input[i]; - input_clk = input[i+1 ] *100 ; - input_vol = input[i+2 ]; - -if (vega10_check_clk_voltage_valid (hwmgr, type, input_clk, input_vol)) { - dpm_table->dpm_levels[input_level].value = input_clk; - podn_vdd_dep_table->entries[input_level].clk = input_clk; - podn_vdd_dep_table->entries[input_level].vddc = input_vol; - }else { +if (input[i] <0 || input[i] >= podn_vdd_dep_table->count) { +pr_info ("invalid clock/voltage level\n" );return -EINVAL ; } + input_clk = input[i +1 ] *100 ; + input_vol = input[i +2 ]; +if (!vega10_check_clk_voltage_valid (hwmgr, type, input_clk, input_vol)) +return -EINVAL ; + } + +if (type ==PP_OD_EDIT_SCLK_VDDC_TABLE ) + data->need_update_dpm_table |=DPMTABLE_OD_UPDATE_SCLK ; +else + data->need_update_dpm_table |=DPMTABLE_OD_UPDATE_MCLK ; + +for (i =0 ; i < size; i +=3 ) { + input_level = input[i]; + input_clk = input[i +1 ] *100 ; + input_vol = input[i +2 ]; + dpm_table->dpm_levels[input_level].value = input_clk; + podn_vdd_dep_table->entries[input_level].clk = input_clk; + podn_vdd_dep_table->entries[input_level].vddc = input_vol; }vega10_odn_update_soc_table (hwmgr, type);return 0 ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 8/1536 Revert "KVM: s390: use __kvm_faultin_pfn()"
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
This reverts commit 151690151a255c29115975ee474718b94a84ffb5.
--- arch/s390/kvm/kvm-s390.c | 126 +++++++++------------------------------ arch/s390/kvm/kvm-s390.h | 6 -- arch/s390/mm/gmap.c | 1 - 3 files changed, 27 insertions(+), 106 deletions(-)
arch/s390/kvm/kvm-s390.c +27 -99
@@ -4743,104 +4743,11 @@ static void kvm_s390_assert_primary_as(struct kvm_vcpu *vcpu) current->thread.gmap_int_code, current->thread.gmap_teid.val); } -/* -* __kvm_s390_handle_dat_fault() - handle a dat fault for the gmap of a vcpu -* @vcpu: the vCPU whose gmap is to be fixed up -* @gfn: the guest frame number used for memslots (including fake memslots) -* @gaddr: the gmap address, does not have to match @gfn for ucontrol gmaps -* @flags: FOLL_* flags -* -* Return: 0 on success, < 0 in case of error. -* Context: The mm lock must not be held before calling. May sleep. -*/ -int __kvm_s390_handle_dat_fault (struct kvm_vcpu *vcpu,gfn_t gfn,gpa_t gaddr,unsigned int flags) -{ -struct kvm_memory_slot *slot; -unsigned int fault_flags; -bool writable, unlocked; -unsigned long vmaddr; -struct page *page; -kvm_pfn_t pfn; -int rc; - - slot =kvm_vcpu_gfn_to_memslot (vcpu, gfn); -if (!slot || slot->flags &KVM_MEMSLOT_INVALID ) -return vcpu_post_run_addressing_exception (vcpu); - - fault_flags = flags &FOLL_WRITE ?FAULT_FLAG_WRITE :0 ; -if (vcpu->arch.gmap->pfault_enabled) - flags |=FOLL_NOWAIT ; - vmaddr =__gfn_to_hva_memslot (slot, gfn); - -try_again: - pfn =__kvm_faultin_pfn (slot, gfn, flags, &writable, &page); - -/* Access outside memory, inject addressing exception */ -if (is_noslot_pfn (pfn)) -return vcpu_post_run_addressing_exception (vcpu); -/* Signal pending: try again */ -if (pfn ==KVM_PFN_ERR_SIGPENDING ) -return -EAGAIN ; - -/* Needs I/O, try to setup async pfault (only possible with FOLL_NOWAIT) */ -if (pfn ==KVM_PFN_ERR_NEEDS_IO ) { -trace_kvm_s390_major_guest_pfault (vcpu); -if (kvm_arch_setup_async_pf (vcpu)) -return 0 ; - vcpu->stat.pfault_sync++; -/* Could not setup async pfault, try again synchronously */ - flags &= ~FOLL_NOWAIT ; - goto try_again; - } -/* Any other error */ -if (is_error_pfn (pfn)) -return -EFAULT ; - -/* Success */ -mmap_read_lock (vcpu->arch.gmap->mm); -/* Mark the userspace PTEs as young and/or dirty, to avoid page fault loops */ - rc =fixup_user_fault (vcpu->arch.gmap->mm, vmaddr, fault_flags, &unlocked); -if (!rc) - rc =__gmap_link (vcpu->arch.gmap, gaddr, vmaddr); - scoped_guard(spinlock, &vcpu->kvm->mmu_lock) { -kvm_release_faultin_page (vcpu->kvm, page, false, writable); - } -mmap_read_unlock (vcpu->arch.gmap->mm); -return rc; -} - -static int vcpu_dat_fault_handler (struct kvm_vcpu *vcpu,unsigned long gaddr,unsigned int flags) -{ -unsigned long gaddr_tmp; -gfn_t gfn; - - gfn =gpa_to_gfn (gaddr); -if (kvm_is_ucontrol (vcpu->kvm)) { -/* -* This translates the per-vCPU guest address into a -* fake guest address, which can then be used with the -* fake memslots that are identity mapping userspace. -* This allows ucontrol VMs to use the normal fault -* resolution path, like normal VMs. -*/ -mmap_read_lock (vcpu->arch.gmap->mm); - gaddr_tmp =__gmap_translate (vcpu->arch.gmap, gaddr); -mmap_read_unlock (vcpu->arch.gmap->mm); -if (gaddr_tmp == -EFAULT ) { - vcpu->run->exit_reason =KVM_EXIT_S390_UCONTROL ; - vcpu->run->s390_ucontrol.trans_exc_code = gaddr; - vcpu->run->s390_ucontrol.pgm_code =PGM_SEGMENT_TRANSLATION ; -return -EREMOTE ; - } - gfn =gpa_to_gfn (gaddr_tmp); - } -return __kvm_s390_handle_dat_fault (vcpu, gfn, gaddr, flags); -} -static int vcpu_post_run_handle_fault (struct kvm_vcpu *vcpu) {unsigned int flags =0 ;unsigned long gaddr; +int rc =0 ; gaddr = current->thread.gmap_teid.addr *PAGE_SIZE ;if (kvm_s390_cur_gmap_fault_is_write ())
@@ -4892,14 +4799,37 @@ static int vcpu_post_run_handle_fault(struct kvm_vcpu *vcpu)case PGM_REGION_SECOND_TRANS :case PGM_REGION_THIRD_TRANS :kvm_s390_assert_primary_as (vcpu); -return vcpu_dat_fault_handler (vcpu, gaddr, flags); +if (vcpu->arch.gmap->pfault_enabled) { + rc =gmap_fault (vcpu->arch.gmap, gaddr, flags |FAULT_FLAG_RETRY_NOWAIT ); +if (rc == -EFAULT ) +return vcpu_post_run_addressing_exception (vcpu); +if (rc == -EAGAIN ) { +trace_kvm_s390_major_guest_pfault (vcpu); +if (kvm_arch_setup_async_pf (vcpu)) +return 0 ; + vcpu->stat.pfault_sync++; + }else { +return rc; + } + } + rc =gmap_fault (vcpu->arch.gmap, gaddr, flags); +if (rc == -EFAULT ) { +if (kvm_is_ucontrol (vcpu->kvm)) { + vcpu->run->exit_reason =KVM_EXIT_S390_UCONTROL ; + vcpu->run->s390_ucontrol.trans_exc_code = gaddr; + vcpu->run->s390_ucontrol.pgm_code =0x10 ; +return -EREMOTE ; + } +return vcpu_post_run_addressing_exception (vcpu); + } +break ;default :KVM_BUG (1 , vcpu->kvm,"Unexpected program interrupt 0x%x, TEID 0x%016lx" , current->thread.gmap_int_code, current->thread.gmap_teid.val);send_sig (SIGSEGV , current,0 );break ; } -return 0 ; +return rc; }static int vcpu_post_run (struct kvm_vcpu *vcpu,int exit_reason)
@@ -5780,9 +5710,7 @@ long kvm_arch_vcpu_ioctl(struct file *filp, }#endif case KVM_S390_VCPU_FAULT : { - idx =srcu_read_lock (&vcpu->kvm->srcu); - r =vcpu_dat_fault_handler (vcpu, arg,0 ); -srcu_read_unlock (&vcpu->kvm->srcu, idx); + r =gmap_fault (vcpu->arch.gmap, arg,0 );break ; }case KVM_ENABLE_CAP :
arch/s390/kvm/kvm-s390.h +0 -6
@@ -408,12 +408,6 @@ void kvm_s390_vcpu_unsetup_cmma(struct kvm_vcpu *vcpu);void kvm_s390_set_cpu_timer (struct kvm_vcpu *vcpu,__u64 cputm);__u64 kvm_s390_get_cpu_timer (struct kvm_vcpu *vcpu);int kvm_s390_cpus_from_pv (struct kvm *kvm,u16 *rc,u16 *rrc); -int __kvm_s390_handle_dat_fault (struct kvm_vcpu *vcpu,gfn_t gfn,gpa_t gaddr,unsigned int flags); - -static inline int kvm_s390_handle_dat_fault (struct kvm_vcpu *vcpu,gpa_t gaddr,unsigned int flags) -{ -return __kvm_s390_handle_dat_fault (vcpu,gpa_to_gfn (gaddr), gaddr, flags); -}/* implemented in diag.c */ int kvm_s390_handle_diag (struct kvm_vcpu *vcpu);
arch/s390/mm/gmap.c +0 -1
@@ -635,7 +635,6 @@ int __gmap_link(struct gmap *gmap, unsigned long gaddr, unsigned long vmaddr)radix_tree_preload_end ();return rc; } -EXPORT_SYMBOL (__gmap_link);/** * gmap_fault - resolve a fault on a guest address
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 26/1536 drm/amdgpu: Gate debugfs MMIO access on kernel lockdown
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Asad Kamal <[email protected]>
[ Upstream commit 17ac73b24006700f50972d37e297dec1f523c14a ]
amdgpu_regs, amdgpu_regs2, and related debugfs nodes allow arbitrary MMIO read/write via RREG32/WREG32 without checking security_locked_down(). On kernel_lockdown=integrity systems this bypasses the same restrictions as /dev/mem and PCI config space sysfs.
Check LOCKDOWN_PCI_ACCESS (matching pci-sysfs) at the entry of every debugfs handler that performs direct register access.
v2: Use consistent check as per previous check to use LOCKDOWN_DEBUGFS(Lijo)
v3: Do not create any entry from amdgpu_debugfs_regs_init() if LOCKDOWN_PCI_ACCESS is active and log once. (Lijo)
--- drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c | 7 +++++++ 1 file changed, 7 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c +7 -0
@@ -26,6 +26,7 @@#include <linux/kthread.h> #include <linux/pci.h> #include <linux/uaccess.h> +#include <linux/security.h> #include <linux/pm_runtime.h> #include "amdgpu.h"
@@ -1646,6 +1647,12 @@ int amdgpu_debugfs_regs_init(struct amdgpu_device *adev)struct dentry *ent, *root = minor->debugfs_root;unsigned int i; +if (security_locked_down (LOCKDOWN_PCI_ACCESS )) { +drm_info (adev_to_drm (adev), +"amdgpu: HW debugfs nodes disabled (kernel lockdown)\n" ); +return 0 ; + } +for (i =0 ; i <ARRAY_SIZE (debugfs_regs); i++) { ent = debugfs_create_file(debugfs_regs_names[i], S_IFREG | 0400, root,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 27/1536 drm/amd/display: fix max dispclk_khz/dppclk_khz double 1000
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Charlene Liu <[email protected]>
[ Upstream commit f48124ff35357d05a98d9cd5cb7982e7e5509003 ]
[why]
Fix regresson caused by double roundup and index out of range
--- drivers/gpu/drm/amd/display/dc/dml2/dml21/dml21_wrapper.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/gpu/drm/amd/display/dc/dml2/dml21/dml21_wrapper.c +4 -4
@@ -175,16 +175,16 @@ static void dml21_calculate_rq_and_dlg_params(const struct dc *dc, struct dc_sta context->bw_ctx.bw.dcn.clk.bw_dispclk_khz = context->bw_ctx.bw.dcn.clk.dispclk_khz;if (in_ctx->v21.dml_init.soc_bb.clk_table.dispclk.num_clk_values >1 ) { context->bw_ctx.bw.dcn.clk.max_supported_dispclk_khz = - in_ctx->v21.dml_init.soc_bb.clk_table.dispclk.clk_values_khz[in_ctx->v21.dml_init.soc_bb.clk_table.dispclk.num_clk_values] *1000 ; + in_ctx->v21.dml_init.soc_bb.clk_table.dispclk.clk_values_khz[in_ctx->v21.dml_init.soc_bb.clk_table.dispclk.num_clk_values -1 ]; }else { - context->bw_ctx.bw.dcn.clk.max_supported_dispclk_khz = in_ctx->v21.dml_init.soc_bb.clk_table.dispclk.clk_values_khz[0 ] *1000 ; + context->bw_ctx.bw.dcn.clk.max_supported_dispclk_khz = in_ctx->v21.dml_init.soc_bb.clk_table.dispclk.clk_values_khz[0 ]; }if (in_ctx->v21.dml_init.soc_bb.clk_table.dppclk.num_clk_values >1 ) { context->bw_ctx.bw.dcn.clk.max_supported_dppclk_khz = - in_ctx->v21.dml_init.soc_bb.clk_table.dppclk.clk_values_khz[in_ctx->v21.dml_init.soc_bb.clk_table.dppclk.num_clk_values] *1000 ; + in_ctx->v21.dml_init.soc_bb.clk_table.dppclk.clk_values_khz[in_ctx->v21.dml_init.soc_bb.clk_table.dppclk.num_clk_values -1 ]; }else { - context->bw_ctx.bw.dcn.clk.max_supported_dppclk_khz = in_ctx->v21.dml_init.soc_bb.clk_table.dppclk.clk_values_khz[0 ] *1000 ; + context->bw_ctx.bw.dcn.clk.max_supported_dppclk_khz = in_ctx->v21.dml_init.soc_bb.clk_table.dppclk.clk_values_khz[0 ]; }/* get global mall allocation */
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 28/1536 drm/radeon: avoid double free in r600 DPM cleanup
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ruoyu Wang <[email protected]>
[ Upstream commit d3f30034f861a585f8e487ae1555d9f288a96f87 ]
r600_parse_extended_power_table() uses manual kfree() calls for some early allocation failures, but the freed pointers are left in the dynamic power-management state. If device teardown later calls r600_free_extended_power_table(), those stale pointers can be freed again.
Use the common extended power table cleanup helper for those early failure paths as well, and clear each pointer after freeing it so repeated cleanup stays safe.
--- drivers/gpu/drm/radeon/r600_dpm.c | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-)
drivers/gpu/drm/radeon/r600_dpm.c +15 -6
@@ -933,7 +933,7 @@ int r600_parse_extended_power_table(struct radeon_device *rdev) ret =r600_parse_clk_voltage_dep_table (&rdev->pm.dpm.dyn_state.vddci_dependency_on_mclk, dep_table);if (ret) { -kfree (rdev->pm.dpm.dyn_state.vddc_dependency_on_sclk.entries); +r600_free_extended_power_table (rdev);return ret; } }
@@ -944,8 +944,7 @@ int r600_parse_extended_power_table(struct radeon_device *rdev) ret =r600_parse_clk_voltage_dep_table (&rdev->pm.dpm.dyn_state.vddc_dependency_on_mclk, dep_table);if (ret) { -kfree (rdev->pm.dpm.dyn_state.vddc_dependency_on_sclk.entries); -kfree (rdev->pm.dpm.dyn_state.vddci_dependency_on_mclk.entries); +r600_free_extended_power_table (rdev);return ret; } }
@@ -956,9 +955,7 @@ int r600_parse_extended_power_table(struct radeon_device *rdev) ret =r600_parse_clk_voltage_dep_table (&rdev->pm.dpm.dyn_state.mvdd_dependency_on_mclk, dep_table);if (ret) { -kfree (rdev->pm.dpm.dyn_state.vddc_dependency_on_sclk.entries); -kfree (rdev->pm.dpm.dyn_state.vddci_dependency_on_mclk.entries); -kfree (rdev->pm.dpm.dyn_state.vddc_dependency_on_mclk.entries); +r600_free_extended_power_table (rdev);return ret; } }
@@ -1298,17 +1295,29 @@ void r600_free_extended_power_table(struct radeon_device *rdev)struct radeon_dpm_dynamic_state *dyn_state = &rdev->pm.dpm.dyn_state;kfree (dyn_state->vddc_dependency_on_sclk.entries); + dyn_state->vddc_dependency_on_sclk.entries =NULL ;kfree (dyn_state->vddci_dependency_on_mclk.entries); + dyn_state->vddci_dependency_on_mclk.entries =NULL ;kfree (dyn_state->vddc_dependency_on_mclk.entries); + dyn_state->vddc_dependency_on_mclk.entries =NULL ;kfree (dyn_state->mvdd_dependency_on_mclk.entries); + dyn_state->mvdd_dependency_on_mclk.entries =NULL ;kfree (dyn_state->cac_leakage_table.entries); + dyn_state->cac_leakage_table.entries =NULL ;kfree (dyn_state->phase_shedding_limits_table.entries); + dyn_state->phase_shedding_limits_table.entries =NULL ;kfree (dyn_state->ppm_table); + dyn_state->ppm_table =NULL ;kfree (dyn_state->cac_tdp_table); + dyn_state->cac_tdp_table =NULL ;kfree (dyn_state->vce_clock_voltage_dependency_table.entries); + dyn_state->vce_clock_voltage_dependency_table.entries =NULL ;kfree (dyn_state->uvd_clock_voltage_dependency_table.entries); + dyn_state->uvd_clock_voltage_dependency_table.entries =NULL ;kfree (dyn_state->samu_clock_voltage_dependency_table.entries); + dyn_state->samu_clock_voltage_dependency_table.entries =NULL ;kfree (dyn_state->acp_clock_voltage_dependency_table.entries); + dyn_state->acp_clock_voltage_dependency_table.entries =NULL ; } enum radeon_pcie_gen r600_get_pcie_gen_support(struct radeon_device *rdev,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 29/1536 drm/amdgpu: add buf length check
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Gangliang Xie <[email protected]>
[ Upstream commit 473f99e4a262776141366f7fb10f101d0f22b019 ]
add buf length check before using it to access data
--- drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c +4 -1
@@ -166,7 +166,8 @@ static ssize_t ta_if_load_debugfs_write(struct file *fp, const char *buf, size_tif (ret)return -EFAULT ; -if (ta_bin_len >PSP_1_MEG ) +if (ta_bin_len <sizeof (struct common_firmware_header ) || + ta_bin_len >PSP_1_MEG )return -EINVAL ; copy_pos +=sizeof (uint32_t );
@@ -321,6 +322,8 @@ static ssize_t ta_if_invoke_debugfs_write(struct file *fp, const char *buf, size ret =copy_from_user ((void *)&shared_buf_len, &buf[copy_pos],sizeof (uint32_t ));if (ret)return -EFAULT ; +if (!shared_buf_len || shared_buf_len >PSP_1_MEG ) +return -EINVAL ; copy_pos +=sizeof (uint32_t ); shared_buf =memdup_user (&buf[copy_pos], shared_buf_len);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 30/1536 drm/amdgpu: add bounds check to prevent array overflow
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: YiPeng Chai <[email protected]>
[ Upstream commit db15c49a17b8fab9ada38f3a548e5353d7d6b1a8 ]
Add bounds check to prevent array overflow.
v2:
Add warning messages.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 7 +++++++ 1 file changed, 7 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +7 -0
@@ -4248,6 +4248,13 @@ static void amdgpu_register_bad_pages_mca_notifier(struct amdgpu_device *adev)* Use this list instead of mgpu_info to find the amdgpu * device on which the UMC error was reported. */ +if (mce_adev_list.num_gpu >=MAX_GPU_INSTANCE ) { +dev_warn_ratelimited (adev->dev, +"mce_adev_list full, skip notifier registration (max=%d)\n" , +MAX_GPU_INSTANCE ); +return ; + } + mce_adev_list.devs[mce_adev_list.num_gpu++] = adev;/*
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 31/1536 gpio: pca9570: Use I2C match data
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 415c63896b76fd98883e190bc7518383cb01779c ]
The driver stores chip metadata in both the OF match table and the I2C id table, but probe currently reads it with device_get_match_data(). That helper only returns firmware-node match data, so an I2C-id/modalias match can leave chip_data NULL before the driver dereferences it to read ngpio.
Use i2c_get_match_data() so the I2C id table driver_data is consumed when firmware match data is not present.
--- drivers/gpio/gpio-pca9570.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpio/gpio-pca9570.c +1 -1
@@ -127,7 +127,7 @@ static int pca9570_probe(struct i2c_client *client) gpio->chip.get = pca9570_get; gpio->chip.set = pca9570_set; gpio->chip.base =-1 ; - gpio->chip_data =device_get_match_data (&client->dev); + gpio->chip_data =i2c_get_match_data (client); gpio->chip.ngpio = gpio->chip_data->ngpio; gpio->chip.can_sleep = true;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 32/1536 w1: ds2482: add OF device match table
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kryštof Černý <[email protected]>
[ Upstream commit 53f33fd74d3993af0fbb5494b5be709f6ca6b712 ]
Add an of_device_id table and hook it into the i2c driver so the ds2482/ds2484 can be matched and auto-probed from Device Tree.
This allows automatic module loading when instantiated via DT.
--- drivers/w1/masters/ds2482.c | 8 ++++++++ 1 file changed, 8 insertions(+)
drivers/w1/masters/ds2482.c +8 -0
@@ -551,9 +551,17 @@ static const struct i2c_device_id ds2482_id[] = { };MODULE_DEVICE_TABLE (i2c, ds2482_id); +static const struct of_device_id ds2482_of_match[] = { + { .compatible ="maxim,ds2482" , }, + { .compatible ="maxim,ds2484" , }, + { } +}; +MODULE_DEVICE_TABLE (of, ds2482_of_match); +static struct i2c_driver ds2482_driver = { .driver = { .name ="ds2482" , + .of_match_table = ds2482_of_match, }, .probe = ds2482_probe, .remove = ds2482_remove,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 33/1536 media: cec: stm32: return an error when log-address wait times out
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 3bc2e4a26465386332ee1a40219d8dafba335b0b ]
stm32_cec_adap_log_addr() waits for TXSOM to clear before disabling CEC and updating the logical address registers. The wait result is ignored, so a timeout can still be reported as a successful logical address update.
Return the polling error before touching the address registers. Compute the address mask only for valid logical addresses so the invalid-address path does not evaluate a shift based on CEC_LOG_ADDR_INVALID.
--- drivers/media/cec/platform/stm32/stm32-cec.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-)
drivers/media/cec/platform/stm32/stm32-cec.c +11 -5
@@ -194,18 +194,24 @@ static int stm32_cec_adap_enable(struct cec_adapter *adap, bool enable)static int stm32_cec_adap_log_addr (struct cec_adapter *adap,u8 logical_addr) {struct stm32_cec *cec = adap->priv; -u32 oar = (1 << logical_addr) <<16 ;u32 val; +int ret;/* Poll every 100µs the register CEC_CR to wait end of transmission */ -regmap_read_poll_timeout (cec->regmap,CEC_CR , val, !(val &TXSOM ), -100 ,CEC_XFER_TIMEOUT_MS *1000 ); + ret =regmap_read_poll_timeout (cec->regmap,CEC_CR , val, !(val &TXSOM ), +100 ,CEC_XFER_TIMEOUT_MS *1000 ); +if (ret) +return ret; +regmap_update_bits (cec->regmap,CEC_CR ,CECEN ,0 ); -if (logical_addr ==CEC_LOG_ADDR_INVALID ) +if (logical_addr ==CEC_LOG_ADDR_INVALID ) {regmap_update_bits (cec->regmap,CEC_CFGR ,OAR ,0 ); -else + }else { +u32 oar =BIT (logical_addr) <<16 ; +regmap_update_bits (cec->regmap,CEC_CFGR , oar, oar); + }regmap_update_bits (cec->regmap,CEC_CR ,CECEN ,CECEN );
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 34/1536 irqdomain: Plug leak in irq_domain_alloc_irqs_locked() error path
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kemeng Shi <[email protected]>
[ Upstream commit 13856e22217fbf7c1200633716ff87ccb50fd89a ]
When irq_domain_trim_hierarchy() fails in irq_domain_alloc_irqs_locked(), the error handling path fails to undo the hierarchy allocations.
Add the missing cleanup.
[ tglx: Massage change log ]
--- kernel/irq/irqdomain.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
kernel/irq/irqdomain.c +3 -1
@@ -1632,7 +1632,7 @@ static int irq_domain_alloc_irqs_locked(struct irq_domain *domain, int irq_base,for (i =0 ; i < nr_irqs; i++) { ret =irq_domain_trim_hierarchy (virq + i);if (ret) - goto out_free_irq_data; + goto out_free_irqs; }for (i =0 ; i < nr_irqs; i++)
@@ -1640,6 +1640,8 @@ static int irq_domain_alloc_irqs_locked(struct irq_domain *domain, int irq_base,return virq; +out_free_irqs: +irq_domain_free_irqs_hierarchy (domain, virq, nr_irqs); out_free_irq_data:irq_domain_free_irq_data (virq, nr_irqs); out_free_desc:
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 35/1536 ASoC: sma1303: remove fault-check sysfs group on remove
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit ce3733792d38ade8df8ce288a96ff0c6ad858bf3 ]
sma1303_i2c_probe() creates a sysfs group that exposes the fault-check controls. The check_fault_status store callback can queue check_fault_work.
sma1303_i2c_remove() only cancels the delayed work. It does not remove the sysfs group, so the controls can remain published after remove while their callbacks still use the driver data and can queue the work again.
Remove the sysfs group before cancelling the delayed work.
--- sound/soc/codecs/sma1303.c | 2 ++ 1 file changed, 2 insertions(+)
sound/soc/codecs/sma1303.c +2 -0
@@ -1787,6 +1787,8 @@ static void sma1303_i2c_remove(struct i2c_client *client)struct sma1303_priv *sma1303 = (struct sma1303_priv *)i2c_get_clientdata (client); +if (sma1303->attr_grp) +sysfs_remove_group (sma1303->kobj, sma1303->attr_grp);cancel_delayed_work_sync (&sma1303->check_fault_work); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 9/1536 Revert "KVM: s390: move pv gmap functions into kvm"
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
This reverts commit 0962b3d34c742be43c7488a7cad839e73ae08005.
--- arch/s390/include/asm/gmap.h | 1 - arch/s390/include/asm/uv.h | 6 +- arch/s390/kernel/uv.c | 292 +++++++++++++++++++++++++++++++---- arch/s390/kvm/Makefile | 2 +- arch/s390/kvm/gmap.c | 212 ------------------------- arch/s390/kvm/gmap.h | 17 -- arch/s390/kvm/intercept.c | 3 +- arch/s390/kvm/kvm-s390.c | 1 - arch/s390/kvm/pv.c | 21 --- arch/s390/mm/gmap.c | 28 ---- 10 files changed, 268 insertions(+), 315 deletions(-) delete mode 100644 arch/s390/kvm/gmap.c delete mode 100644 arch/s390/kvm/gmap.h
arch/s390/include/asm/gmap.h +0 -1
@@ -152,7 +152,6 @@ int s390_replace_asce(struct gmap *gmap);void s390_uv_destroy_pfns (unsigned long count,unsigned long *pfns);int __s390_uv_destroy_range (struct mm_struct *mm,unsigned long start,unsigned long end,bool interruptible); -int kvm_s390_wiggle_split_folio (struct mm_struct *mm,struct folio *folio,bool split);/** * s390_uv_destroy_range - Destroy a range of pages in the given mm.
arch/s390/include/asm/uv.h +3 -3
@@ -476,12 +476,12 @@ static inline int is_prot_virt_host(void) }int uv_pin_shared (unsigned long paddr); +int gmap_make_secure (struct gmap *gmap,unsigned long gaddr,void *uvcb); +int gmap_destroy_page (struct gmap *gmap,unsigned long gaddr);int uv_destroy_folio (struct folio *folio);int uv_destroy_pte (pte_t pte);int uv_convert_from_secure_pte (pte_t pte); -int make_folio_secure (struct folio *folio,struct uv_cb_header *uvcb); -int uv_convert_from_secure (unsigned long paddr); -int uv_convert_from_secure_folio (struct folio *folio); +int gmap_convert_to_secure (struct gmap *gmap,unsigned long gaddr);void setup_uv (void );
arch/s390/kernel/uv.c +263 -29
342 lines not on this page · raw message
arch/s390/kvm/Makefile +1 -1
@@ -8,7 +8,7 @@ include $(srctree)/virt/kvm/Makefile.kvm ccflags-y := -Ivirt/kvm -Iarch/s390/kvm kvm-y += kvm-s390.o intercept.o interrupt.o priv.o sigp.o -kvm-y += diag.o gaccess.o guestdbg.o vsie.o pv.o gmap.o +kvm-y += diag.o gaccess.o guestdbg.o vsie.o pv.o kvm-$(CONFIG_VFIO_PCI_ZDEV_KVM) += pci.o obj-$(CONFIG_KVM) += kvm.o
arch/s390/kvm/gmap.c deleted +0 -212
212 lines not on this page · raw message
arch/s390/kvm/gmap.h deleted +0 -17
@@ -1,17 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0 */ -/* -* KVM guest address space mapping code -* -* Copyright IBM Corp. 2007, 2016, 2025 -* Author(s): Martin Schwidefsky <[email protected]> -* Claudio Imbrenda <[email protected]> -*/ - -#ifndef ARCH_KVM_S390_GMAP_H -#define ARCH_KVM_S390_GMAP_H - -int gmap_make_secure (struct gmap *gmap,unsigned long gaddr,void *uvcb); -int gmap_convert_to_secure (struct gmap *gmap,unsigned long gaddr); -int gmap_destroy_page (struct gmap *gmap,unsigned long gaddr); - -#endif
arch/s390/kvm/intercept.c +1 -2
@@ -21,7 +21,6 @@#include "gaccess.h" #include "trace.h" #include "trace-s390.h" -#include "gmap.h" u8 kvm_s390_get_ilen (struct kvm_vcpu *vcpu) {
@@ -550,7 +549,7 @@ static int handle_pv_uvc(struct kvm_vcpu *vcpu)* If the unpin did not succeed, the guest will exit again for the UVC * and we will retry the unpin. */ -if (rc == -EINVAL || rc == -ENXIO ) +if (rc == -EINVAL )return 0 ;/* * If we got -EAGAIN here, we simply return it. It will eventually
arch/s390/kvm/kvm-s390.c +0 -1
@@ -49,7 +49,6 @@#include "kvm-s390.h" #include "gaccess.h" #include "pci.h" -#include "gmap.h" #define CREATE_TRACE_POINTS #include "trace.h"
arch/s390/kvm/pv.c +0 -21
@@ -17,7 +17,6 @@#include <linux/sched/mm.h> #include <linux/mmu_notifier.h> #include "kvm-s390.h" -#include "gmap.h" bool kvm_s390_pv_is_protected (struct kvm *kvm) {
@@ -639,28 +638,10 @@ static int unpack_one(struct kvm *kvm, unsigned long addr, u64 tweak, .tweak[1] = offset, };int ret =gmap_make_secure (kvm->arch.gmap, addr, &uvcb); -unsigned long vmaddr; -bool unlocked; *rc = uvcb.header.rc; *rrc = uvcb.header.rrc; -if (ret == -ENXIO ) { -mmap_read_lock (kvm->mm); - vmaddr =gfn_to_hva (kvm,gpa_to_gfn (addr)); -if (kvm_is_error_hva (vmaddr)) { - ret = -EFAULT ; - }else { - ret =fixup_user_fault (kvm->mm, vmaddr,FAULT_FLAG_WRITE , &unlocked); -if (!ret) - ret =__gmap_link (kvm->arch.gmap, addr, vmaddr); - } -mmap_read_unlock (kvm->mm); -if (!ret) -return -EAGAIN ; -return ret; - } -if (ret && ret != -EAGAIN )KVM_UV_EVENT (kvm,3 ,"PROTVIRT VM UNPACK: failed addr %llx with rc %x rrc %x" , uvcb.gaddr, *rc, *rrc);
@@ -679,8 +660,6 @@ int kvm_s390_pv_unpack(struct kvm *kvm, unsigned long addr, unsigned long size,KVM_UV_EVENT (kvm,3 ,"PROTVIRT VM UNPACK: start addr %lx size %lx" , addr, size); -guard (srcu)(&kvm->srcu); -while (offset < size) { ret =unpack_one (kvm, addr, tweak, offset, rc, rrc);if (ret == -EAGAIN ) {
arch/s390/mm/gmap.c +0 -28
@@ -2982,31 +2982,3 @@ int s390_replace_asce(struct gmap *gmap)return 0 ; }EXPORT_SYMBOL_GPL (s390_replace_asce); - -/** -* kvm_s390_wiggle_split_folio() - try to drain extra references to a folio and optionally split -* @mm: the mm containing the folio to work on -* @folio: the folio -* @split: whether to split a large folio -* -* Context: Must be called while holding an extra reference to the folio; -* the mm lock should not be held. -*/ -int kvm_s390_wiggle_split_folio (struct mm_struct *mm,struct folio *folio,bool split) -{ -int rc; - -lockdep_assert_not_held (&mm->mmap_lock); -folio_wait_writeback (folio); -lru_add_drain_all (); -if (split) { -folio_lock (folio); - rc =split_folio (folio); -folio_unlock (folio); - -if (rc != -EBUSY ) -return rc; - } -return -EAGAIN ; -} -EXPORT_SYMBOL_GPL (kvm_s390_wiggle_split_folio);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 10/1536 mm/damon/core: error damos_commit_quota_goal() for zero target_value
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: SJ Park <[email protected]>
commit 610c4438fb66e06d9e693c0ad3b2c1be54c0d61f upstream.
Patch series "mm/damon: move zero damos quota target_value handling to the core layer".
Having zero DAMOS quota target value can cause division by zero. DAMON API callers are checking the target value parameters to avoid that. It is easy to make mistakes in some of the multiple API callers. Move that to the core layer.
Patch 1 adds the corner case handling into the core layer DAMON parameters validation logic. Patches 2 and 3 remove no more needed DAMON API callers side handling of the corner case in DAMON_LRU_SORT and DMON_SAMPLIE_MTIER, respectively.
This patch (of 3):
If a DAMOS scheme has a damos_quota_goal of zero target_value, damos_quota_goal() could trigger division-by-zero error. Hence each DAMON API callers should do the zero target_value validation. It is easy to make mistakes. Actually such bugs in DAMON_LRU_SORT and DAMON_SAMPLE_MTIER were found and fixed [1].
It is better to handle the corner case only once in the core layer, instead of multiple places in all DAMON API callers. One straightforward option is using an alternative denominator for the corner case in the damos_quota_goal(). However, the zero target_value is meaningless. In this case, the quota goal is always evaluated as achieved or over-achieved. The quota will only keep being reduced.
Simply avoid using zero target_value by adding a check in the core layer DAMOS quota goal parameters validation/commit path, damos_commit_quota_goal(). Update it to return an error in the case. Also update its caller to propagate the error.
Notes for stable kernel porting. The upstream commit doesn't have
Fixes: and therefore not ported to stable kernels. It turned out it fixes commit 8b549a4fd3c5 ("mm/damon/sysfs-schemes: commit damos quota goals user input to DAMOS") which was merged into v6.8. The user impact is a race condition that can result in divide-by-zero. Hence backport. Reproducing the issue requires sysfs write permission, certain DAMON ABI usages that are supposed to be uncommon, and a rare race timing, though. The issue was discovered [2] by Sashiko as a part [3] of its bug report.
Also, the upstream commit on this stable kernel can fix the issue for parameters commit paths but DAMON start path. That's because DAMON start path does not invoke damon_commit_quota_goals(). To fix the path with minimum change, add a new small validation of quota goal target value before damon_start() call.
[2] https://sashiko.dev/#/bug/linux-7f814c9a-986f-4103-a55a-ef9537dcf62b
[3] https://lore.kernel.org/[email protected]
--- mm/damon/core.c | 18 +++++++++++++----- mm/damon/sysfs.c | 19 +++++++++++++++++++ 2 files changed, 32 insertions(+), 5 deletions(-)
mm/damon/core.c +13 -5
@@ -698,14 +698,17 @@ static struct damos_quota_goal *damos_nth_quota_goal(return NULL ; } -static void damos_commit_quota_goal ( +static int damos_commit_quota_goal (struct damos_quota_goal *dst,struct damos_quota_goal *src) { +if (!src->target_value) +return -EINVAL ; dst->metric = src->metric; dst->target_value = src->target_value;if (dst->metric ==DAMOS_QUOTA_USER_INPUT ) dst->current_value = src->current_value;/* keep last_psi_total as is, since it will be updated in next cycle */ +return 0 ; }/**
@@ -723,18 +726,23 @@ static void damos_commit_quota_goal(int damos_commit_quota_goals (struct damos_quota *dst,struct damos_quota *src) {struct damos_quota_goal *dst_goal, *next, *src_goal, *new_goal; -int i =0 , j =0 ; +int i =0 , j =0 , err;damos_for_each_quota_goal_safe (dst_goal, next, dst) { src_goal =damos_nth_quota_goal (i++, src); -if (src_goal) -damos_commit_quota_goal (dst_goal, src_goal); -else +if (src_goal) { + err =damos_commit_quota_goal (dst_goal, src_goal); +if (err) +return err; + }else {damos_destroy_quota_goal (dst_goal); + } }damos_for_each_quota_goal_safe (src_goal, next, src) {if (j++ < i)continue ; +if (!src_goal->target_value) +return -EINVAL ; new_goal =damos_new_quota_goal ( src_goal->metric, src_goal->target_value);if (!new_goal)
mm/damon/sysfs.c +19 -0
@@ -1497,6 +1497,20 @@ static struct damon_ctx *damon_sysfs_build_ctx(return ctx; } +static bool damon_sysfs_valid_start_ctx (struct damon_ctx *ctx) +{ +struct damos *s; +struct damos_quota_goal *g; + +damon_for_each_scheme (s, ctx) { +damos_for_each_quota_goal (g, (&s->quota)) { +if (!g->target_value) +return false; + } + } +return true; +} +static int damon_sysfs_turn_damon_on (struct damon_sysfs_kdamond *kdamond) {struct damon_ctx *ctx;
@@ -1517,6 +1531,11 @@ static int damon_sysfs_turn_damon_on(struct damon_sysfs_kdamond *kdamond) ctx =damon_sysfs_build_ctx (kdamond->contexts->contexts_arr[0 ]);if (IS_ERR (ctx))return PTR_ERR (ctx); +if (!damon_sysfs_valid_start_ctx (ctx)) { +damon_sysfs_destroy_targets (ctx); +damon_destroy_ctx (ctx); +return -EINVAL ; + } err =damon_start (&ctx,1 , false);if (err) {damon_destroy_ctx (ctx);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 11/1536 mm: vmscan: fix dirty folios throttling on cgroup v1 for MGLRU
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Baolin Wang <[email protected]>
[ Upstream commit 13b6b620910436c29dea398382e83c9499fd13e4 ]
The balance_dirty_pages() won't do the dirty folios throttling on cgroupv1. See commit 9badce000e2c ("cgroup, writeback: don't enable cgroup writeback on traditional hierarchies").
Moreover, after commit 6b0dfabb3555 ("fs: Remove aops->writepage"), we no longer attempt to write back filesystem folios through reclaim.
On large memory systems, the flusher may not be able to write back quickly enough. Consequently, MGLRU will encounter many folios that are already under writeback. Since we cannot reclaim these dirty folios, the system may run out of memory and trigger the OOM killer.
Hence, for cgroup v1, let's throttle reclaim after waking up the flusher, which is similar to commit 81a70c21d917 ("mm/cgroup/reclaim: fix dirty pages throttling on cgroup v1"), to avoid unnecessary OOM.
The following test program can easily reproduce the OOM issue. With this patch applied, the test passes successfully.
$mkdir /sys/fs/cgroup/memory/test
$echo 256M > /sys/fs/cgroup/memory/test/memory.limit_in_bytes $echo $$ > /sys/fs/cgroup/memory/test/cgroup.procs $dd if=/dev/zero of=/mnt/data.bin bs=1M count=800
--- mm/vmscan.c | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-)
mm/vmscan.c +16 -1
@@ -4809,9 +4809,24 @@ static bool try_to_shrink_lruvec(struct lruvec *lruvec, struct scan_control *sc)* If too many file cache in the coldest generation can't be evicted * due to being dirty, wake up the flusher. */ -if (sc->nr.unqueued_dirty && sc->nr.unqueued_dirty == sc->nr.file_taken) +if (sc->nr.unqueued_dirty && sc->nr.unqueued_dirty == sc->nr.file_taken) { +struct pglist_data *pgdat =lruvec_pgdat (lruvec); +wakeup_flusher_threads (WB_REASON_VMSCAN ); +/* +* For cgroupv1 dirty throttling is achieved by waking up +* the kernel flusher here and later waiting on folios +* which are in writeback to finish (see shrink_folio_list()). +* +* Flusher may not be able to issue writeback quickly +* enough for cgroupv1 writeback throttling to work +* on a large system. +*/ +if (!writeback_throttling_sane (sc)) +reclaim_throttle (pgdat,VMSCAN_THROTTLE_WRITEBACK ); + } +/* whether this lruvec should be rotated */ return nr_to_scan <0 ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 12/1536 mm/damon/sysfs: put target pids for damon_start() failure
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: SJ Park <[email protected]>
damon_sysfs_turn_damon_on() allocates and sets up damon_ctx to start. If it is for virtual address space monitoring, the setup increases the reference counts of the target pids. After the setup, the function invokes damon_start(). If damon_start() fails, it deallocates the damon_ctx object without decreasing the reference counts of target pids. As a result, pids can be leaked.
Fix the leak by putting pids using damon_sysfs_destroy_targets() before deallocating the damon_ctx object.
--- mm/damon/sysfs.c | 1 + 1 file changed, 1 insertion(+)
mm/damon/sysfs.c +1 -0
@@ -1538,6 +1538,7 @@ static int damon_sysfs_turn_damon_on(struct damon_sysfs_kdamond *kdamond) } err =damon_start (&ctx,1 , false);if (err) { +damon_sysfs_destroy_targets (ctx);damon_destroy_ctx (ctx);return err; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 13/1536 mm/damon/sysfs: put target pids for apply_inputs() failure
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: SJ Park <[email protected]>
damon_sysfs_build_ctx() invokes damon_sysfs_apply_inputs() for setting damon_ctx object with user inputs. If it is configured for virtual address spaces monitoring, the setup also increases reference counts of monitoring target pids. If the setup is failed, damon_sysfs_build_ctx() deallocates the damon_ctx object without decreasing the reference counts of the pids. If the failure happened after increasing reference counts of pids, the pids can be leaked.
Fix the leaks by decreasing the pid reference counts before deallocating the damon_ctx object.
The issue was discovered [1] by Sashiko.
[1] https://lore.kernel.org/[email protected]
--- mm/damon/sysfs.c | 1 + 1 file changed, 1 insertion(+)
mm/damon/sysfs.c +1 -0
@@ -1486,6 +1486,7 @@ static struct damon_ctx *damon_sysfs_build_ctx( err =damon_sysfs_apply_inputs (ctx, sys_ctx);if (err) { +damon_sysfs_destroy_targets (ctx);damon_destroy_ctx (ctx);return ERR_PTR (err); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 14/1536 iio: hid-sensor: als: scale each channel individually
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Daniel Schaefer <[email protected]>
[ Upstream commit cad928dad9a4c26aa56b4223dc2a29bca517fb5f ]
Some sensors have multiple channels (not just brightness but color ALS sensors) with different scaling factors.
--- drivers/iio/light/hid-sensor-als.c | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-)
drivers/iio/light/hid-sensor-als.c +12 -10
@@ -33,9 +33,9 @@ struct als_state {u32 illum[CHANNEL_SCAN_INDEX_MAX ];u64 timestamp__aligned(8) ; } scan; -int scale_pre_decml; -int scale_post_decml; -int scale_precision; +int scale_pre_decml[CHANNEL_SCAN_INDEX_MAX ]; +int scale_post_decml[CHANNEL_SCAN_INDEX_MAX ]; +int scale_precision[CHANNEL_SCAN_INDEX_MAX ];int value_offset;int num_channels;s64 timestamp;
@@ -186,9 +186,11 @@ static int als_read_raw(struct iio_dev *indio_dev, ret_type =IIO_VAL_INT ;break ;case IIO_CHAN_INFO_SCALE : - *val = als_state->scale_pre_decml; - *val2 = als_state->scale_post_decml; - ret_type = als_state->scale_precision; +if (chan->scan_index >=CHANNEL_SCAN_INDEX_MAX ) +return -EINVAL ; + *val = als_state->scale_pre_decml[chan->scan_index]; + *val2 = als_state->scale_post_decml[chan->scan_index]; + ret_type = als_state->scale_precision[chan->scan_index];break ;case IIO_CHAN_INFO_OFFSET : *val = als_state->value_offset;
@@ -337,6 +339,10 @@ static int als_parse_report(struct platform_device *pdev,als_adjust_channel_bit_mask (channels, index, st->als[i].size); ++index; + st->scale_precision[i] =hid_sensor_format_scale (usage_id, + &st->als[i], &st->scale_pre_decml[i], + &st->scale_post_decml[i]); +dev_dbg (&pdev->dev,"als %x:%x\n" , st->als[i].index, st->als[i].report_id); }
@@ -346,10 +352,6 @@ static int als_parse_report(struct platform_device *pdev,if (index) ret =0 ; - st->scale_precision =hid_sensor_format_scale (usage_id, - &st->als[CHANNEL_SCAN_INDEX_INTENSITY ], - &st->scale_pre_decml, &st->scale_post_decml); -return ret; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 15/1536 platform: cznic: turris-omnia-mcu: Add missing MODULE_DEVICE_TABLE()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ridham Khurana <[email protected]>
[ Upstream commit 59797443846bc2451c35816026bbb79d281c9f23 ]
The driver wires of_omnia_mcu_match into the i2c_driver's .of_match_table but never exports it with MODULE_DEVICE_TABLE(), so no module alias is generated and the module is not autoloaded when the MCU is probed from the device tree.
Found by code inspection. Not tested on the hardware itself; with the module built, the alias lookup
$ modprobe -R 'of:Nsystem-controllerT(null)Ccznic,turris-omnia-mcu'
reports no match before this change and resolves to turris_omnia_mcu after it.
--- drivers/platform/cznic/turris-omnia-mcu-base.c | 1 + 1 file changed, 1 insertion(+)
drivers/platform/cznic/turris-omnia-mcu-base.c +1 -0
@@ -396,6 +396,7 @@ static const struct of_device_id of_omnia_mcu_match[] = { { .compatible = "cznic,turris-omnia-mcu" }, {} }; +MODULE_DEVICE_TABLE (of, of_omnia_mcu_match);static struct i2c_driver omnia_mcu_driver = { .probe = omnia_mcu_probe,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 6/1536 Revert "KVM: s390: pv: fix race when making a page secure"
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
This reverts commit 45a6af5413239dcd0d0084e41ea04ce685c4d3c2.
--- arch/s390/include/asm/gmap.h | 1 + arch/s390/include/asm/uv.h | 2 +- arch/s390/kernel/uv.c | 136 ++--------------------------------- arch/s390/kvm/gmap.c | 103 ++++++++++++++++++++++++-- arch/s390/kvm/kvm-s390.c | 25 +++---- arch/s390/mm/gmap.c | 28 ++++++++ 6 files changed, 144 insertions(+), 151 deletions(-)
arch/s390/include/asm/gmap.h +1 -0
@@ -150,6 +150,7 @@ int s390_replace_asce(struct gmap *gmap);void s390_uv_destroy_pfns (unsigned long count,unsigned long *pfns);int __s390_uv_destroy_range (struct mm_struct *mm,unsigned long start,unsigned long end,bool interruptible); +int kvm_s390_wiggle_split_folio (struct mm_struct *mm,struct folio *folio,bool split);unsigned long *gmap_table_walk (struct gmap *gmap,unsigned long gaddr,int level);/**
arch/s390/include/asm/uv.h +1 -1
@@ -479,7 +479,7 @@ int uv_pin_shared(unsigned long paddr);int uv_destroy_folio (struct folio *folio);int uv_destroy_pte (pte_t pte);int uv_convert_from_secure_pte (pte_t pte); -int make_hva_secure (struct mm_struct *mm,unsigned long hva,struct uv_cb_header *uvcb); +int make_folio_secure (struct folio *folio,struct uv_cb_header *uvcb);int uv_convert_from_secure (unsigned long paddr);int uv_convert_from_secure_folio (struct folio *folio);
arch/s390/kernel/uv.c +7 -129
169 lines not on this page · raw message
arch/s390/kvm/gmap.c +97 -6
122 lines not on this page · raw message
arch/s390/kvm/kvm-s390.c +10 -15
@@ -4841,7 +4841,6 @@ static int vcpu_post_run_handle_fault(struct kvm_vcpu *vcpu) {unsigned int flags =0 ;unsigned long gaddr; -int rc; gaddr = current->thread.gmap_teid.addr *PAGE_SIZE ;if (kvm_s390_cur_gmap_fault_is_write ())
@@ -4851,6 +4850,16 @@ static int vcpu_post_run_handle_fault(struct kvm_vcpu *vcpu)case 0 : vcpu->stat.exit_null++;break ; +case PGM_NON_SECURE_STORAGE_ACCESS : +kvm_s390_assert_primary_as (vcpu); +/* +* This is normal operation; a page belonging to a protected +* guest has not been imported yet. Try to import the page into +* the protected guest. +*/ +if (gmap_convert_to_secure (vcpu->arch.gmap, gaddr) == -EINVAL ) +send_sig (SIGSEGV , current,0 ); +break ;case PGM_SECURE_STORAGE_ACCESS :case PGM_SECURE_STORAGE_VIOLATION :kvm_s390_assert_primary_as (vcpu);
@@ -4875,20 +4884,6 @@ static int vcpu_post_run_handle_fault(struct kvm_vcpu *vcpu)send_sig (SIGSEGV , current,0 ); }break ; -case PGM_NON_SECURE_STORAGE_ACCESS : -kvm_s390_assert_primary_as (vcpu); -/* -* This is normal operation; a page belonging to a protected -* guest has not been imported yet. Try to import the page into -* the protected guest. -*/ - rc =gmap_convert_to_secure (vcpu->arch.gmap, gaddr); -if (rc == -EINVAL ) -send_sig (SIGSEGV , current,0 ); -if (rc != -ENXIO ) -break ; - flags =FAULT_FLAG_WRITE ; - fallthrough;case PGM_PROTECTION :case PGM_SEGMENT_TRANSLATION :case PGM_PAGE_TRANSLATION :
arch/s390/mm/gmap.c +28 -0
@@ -2943,3 +2943,31 @@ int s390_replace_asce(struct gmap *gmap)return 0 ; }EXPORT_SYMBOL_GPL (s390_replace_asce); + +/** +* kvm_s390_wiggle_split_folio() - try to drain extra references to a folio and optionally split +* @mm: the mm containing the folio to work on +* @folio: the folio +* @split: whether to split a large folio +* +* Context: Must be called while holding an extra reference to the folio; +* the mm lock should not be held. +*/ +int kvm_s390_wiggle_split_folio (struct mm_struct *mm,struct folio *folio,bool split) +{ +int rc; + +lockdep_assert_not_held (&mm->mmap_lock); +folio_wait_writeback (folio); +lru_add_drain_all (); +if (split) { +folio_lock (folio); + rc =split_folio (folio); +folio_unlock (folio); + +if (rc != -EBUSY ) +return rc; + } +return -EAGAIN ; +} +EXPORT_SYMBOL_GPL (kvm_s390_wiggle_split_folio);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 37/1536 ASoC: tlv320aic26: remove keyclick sysfs file
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit ae375f8d063d71e598c0d7e14fc056154c84d7a7 ]
aic26_probe() creates the keyclick sysfs file on the component device. The file callback uses the ASoC component pointer stored in the driver private data.
There is no matching remove callback, so the sysfs file can remain after the component is removed while its backing component state is gone.
Add a component remove callback that removes the keyclick file.
--- sound/soc/codecs/tlv320aic26.c | 6 ++++++ 1 file changed, 6 insertions(+)
sound/soc/codecs/tlv320aic26.c +6 -0
@@ -320,8 +320,14 @@ static int aic26_probe(struct snd_soc_component *component)return 0 ; } +static void aic26_remove (struct snd_soc_component *component) +{ +device_remove_file (component->dev, &dev_attr_keyclick); +} +static const struct snd_soc_component_driver aic26_soc_component_dev = { .probe = aic26_probe, + .remove = aic26_remove, .controls = aic26_snd_controls, .num_controls =ARRAY_SIZE (aic26_snd_controls), .dapm_widgets = tlv320aic26_dapm_widgets,
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 46/1536 spi: bcm63xx: return error from failed controller suspend
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jiawen Liu <[email protected]>
[ Upstream commit bbbc1ef5b35341c5122418a14f8924688a4bb954 ]
spi_controller_suspend() can fail if the SPI core cannot stop the controller. bcm63xx_spi_suspend() ignored that error, disabled the controller clock, and returned success.
Return the suspend error before tearing down the clock.
--- drivers/spi/spi-bcm63xx.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/spi/spi-bcm63xx.c +4 -1
@@ -643,8 +643,11 @@ static int bcm63xx_spi_suspend(struct device *dev) {struct spi_controller *host =dev_get_drvdata (dev);struct bcm63xx_spi *bs =spi_controller_get_devdata (host); +int ret; -spi_controller_suspend (host); + ret =spi_controller_suspend (host); +if (ret) +return ret;clk_disable_unprepare (bs->clk);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 47/1536 spi: bcm63xx-hsspi: return error from failed controller suspend
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jiawen Liu <[email protected]>
[ Upstream commit 3b5414d76a0381db77b9694537254af7acfa187a ]
spi_controller_suspend() can fail if the SPI core cannot stop the controller. bcm63xx_hsspi_suspend() ignored that error, disabled the PLL and core clocks, and returned success.
Return the suspend error before disabling the clocks.
--- drivers/spi/spi-bcm63xx-hsspi.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/spi/spi-bcm63xx-hsspi.c +5 -1
@@ -895,8 +895,12 @@ static int bcm63xx_hsspi_suspend(struct device *dev) {struct spi_controller *host =dev_get_drvdata (dev);struct bcm63xx_hsspi *bs =spi_controller_get_devdata (host); +int ret; + + ret =spi_controller_suspend (host); +if (ret) +return ret; -spi_controller_suspend (host);clk_disable_unprepare (bs->pll_clk);clk_disable_unprepare (bs->clk);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 48/1536 drm/panel-edp: Add BOE NE160QDM-NY1 panel
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Damon Ding <[email protected]>
[ Upstream commit be4f10d44757211fd656fa57f37034657f26c883 ]
Add an entry for the BOE NE160QDM-NY1 eDP panel. The panel's AUX backlight functionality is verified and working on the RK3576 EVB1 board.
edid-decode (hex):
00 ff ff ff ff ff ff 00 09 e5 85 09 00 00 00 00 1c 1e 01 04 b5 22 15 78 03 7c e5 a4 55 4c 9f 26 0f 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 6b 6e 00 a0 a0 40 84 60 30 20 36 00 58 d7 10 00 00 1a 00 00 00 fd 0c 3c a5 1f 1f 4e 01 0a 20 20 20 20 20 20 00 00 00 fe 00 42 4f 45 20 43 51 0a 20 20 20 20 20 20 00 00 00 fe 00 4e 45 31 36 30 51 44 4d 2d 4e 59 31 0a 01 ed
02 03 1d 00 e3 05 80 00 e6 06 05 01 6a 6a 24 6d 1a 00 00 02 03 3c a5 00 04 6a 24 6a 24 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ff
--- drivers/gpu/drm/panel/panel-edp.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/panel/panel-edp.c +1 -0
@@ -1905,6 +1905,7 @@ static const struct edp_panel_entry edp_panels[] = {EDP_PANEL_ENTRY ('B' ,'O' ,'E' ,0x095f , &delay_200_500_e50,"NE135FBM-N41 v8.1" ),EDP_PANEL_ENTRY ('B' ,'O' ,'E' ,0x096e , &delay_200_500_e50_po2e200,"NV116WHM-T07 V8.0" ),EDP_PANEL_ENTRY ('B' ,'O' ,'E' ,0x0979 , &delay_200_500_e50,"NV116WHM-N49 V8.0" ), +EDP_PANEL_ENTRY ('B' ,'O' ,'E' ,0x0985 , &delay_200_500_e50,"NE160QDM-NY1" ),EDP_PANEL_ENTRY ('B' ,'O' ,'E' ,0x098d , &boe_nv110wtm_n61.delay,"NV110WTM-N61" ),EDP_PANEL_ENTRY ('B' ,'O' ,'E' ,0x0993 , &delay_200_500_e80,"NV116WHM-T14 V8.0" ), EDP_PANEL_ENTRY('B', 'O', 'E', 0x09ad, &delay_200_500_e80, "NV116WHM-N47"),
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 49/1536 spi: nxp-fspi: disable runtime PM on probe failures
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jiawen Liu <[email protected]>
[ Upstream commit 5d14285d60ba95561609a293064654a0c7d7d928 ]
nxp_fspi_probe() enables runtime PM and autosuspend before several operations that can fail.
Some failure paths returned directly before the devm cleanup action was installed, leaving runtime PM enabled.
Route those failures through a common runtime PM cleanup path. Use pm_runtime_resume_and_get() for the initial clock enable.
--- drivers/spi/spi-nxp-fspi.c | 31 ++++++++++++++++++++++--------- 1 file changed, 22 insertions(+), 9 deletions(-)
drivers/spi/spi-nxp-fspi.c +22 -9
@@ -1252,9 +1252,11 @@ static int nxp_fspi_probe(struct platform_device *pdev)pm_runtime_use_autosuspend (dev);/* enable clock */ - ret =pm_runtime_get_sync (f->dev); -if (ret <0 ) -return dev_err_probe (dev, ret,"Failed to enable clock" ); + ret =pm_runtime_resume_and_get (f->dev); +if (ret <0 ) { + ret =dev_err_probe (dev, ret,"Failed to enable clock" ); + goto err_disable_pm; + }/* Clear potential interrupts */ reg =fspi_readl (f, f->iobase +FSPI_INTR );
@@ -1264,18 +1266,24 @@ static int nxp_fspi_probe(struct platform_device *pdev)nxp_fspi_default_setup (f); ret =pm_runtime_put_sync (dev); -if (ret <0 ) -return dev_err_probe (dev, ret,"Failed to disable clock" ); +if (ret <0 ) { + ret =dev_err_probe (dev, ret,"Failed to disable clock" ); + goto err_disable_pm; + }init_completion (&f->c); ret =devm_request_irq (dev, irq, nxp_fspi_irq_handler,0 , pdev->name, f); -if (ret) -return dev_err_probe (dev, ret,"Failed to request irq\n" ); +if (ret) { + ret =dev_err_probe (dev, ret,"Failed to request irq\n" ); + goto err_disable_pm; + } ret =devm_mutex_init (dev, &f->lock); -if (ret) -return dev_err_probe (dev, ret,"Failed to initialize lock\n" ); +if (ret) { + ret =dev_err_probe (dev, ret,"Failed to initialize lock\n" ); + goto err_disable_pm; + } ctlr->bus_num =-1 ; ctlr->num_chipselect =NXP_FSPI_MAX_CHIPSELECT ;
@@ -1289,6 +1297,11 @@ static int nxp_fspi_probe(struct platform_device *pdev)device_set_node (&ctlr->dev, fwnode);return devm_spi_register_controller (&pdev->dev, ctlr); + +err_disable_pm: +pm_runtime_dont_use_autosuspend (dev); +pm_runtime_disable (dev); +return ret; }static void nxp_fspi_remove (struct platform_device *pdev)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 50/1536 spi: bcmbca-hsspi: return error from failed controller suspend
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jiawen Liu <[email protected]>
[ Upstream commit faa878d4805ca375738294bc52eae310eb287b16 ]
spi_controller_suspend() can fail if pending transfers cannot stop. bcmbca_hsspi_suspend() ignored the error and still disabled the PLL and core clocks.
Return the error before disabling the clocks.
--- drivers/spi/spi-bcmbca-hsspi.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/spi/spi-bcmbca-hsspi.c +5 -1
@@ -586,8 +586,12 @@ static int bcmbca_hsspi_suspend(struct device *dev) {struct spi_controller *host =dev_get_drvdata (dev);struct bcmbca_hsspi *bs =spi_controller_get_devdata (host); +int ret; + + ret =spi_controller_suspend (host); +if (ret) +return ret; -spi_controller_suspend (host);clk_disable_unprepare (bs->pll_clk);clk_disable_unprepare (bs->clk);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 51/1536 wifi: ath12k: avoid setting 320MHz support on non 6GHz band
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Nicolas Escande <[email protected]>
[ Upstream commit eaf478b3ea68e1b5df659acd24c4df5850e12325 ]
On a split phy qcn9274 (2.4GHz + 5GHz low), "iw phy" reports 320MHz related features on the 5GHz band while it should not:
Wiphy phy1
[...]
Band 2:
[...]
EHT Iftypes: managed
[...]
EHT PHY Capabilities: (0xe2ffdbe018778000):
320MHz in 6GHz Supported
[...]
Beamformee SS (320MHz): 7
[...]
Number Of Sounding Dimensions (320MHz): 3
[...]
EHT MCS/NSS: (0x22222222222222222200000000):This is also reflected in the beacons sent by a mesh interface started on that band. They erroneously advertise 320MHz support too.
This should not happen as IEEE Std 802.11-2024, subclause 9.4.2.323.3 says we should not set the 320MHz related fields when not operating on a 6GHz band. For example it says about Bit 0 "Support For 320 MHz In 6 GHz"
"Reserved if the EHT Capabilities element is indicating capabilities for
the 2.4 GHz or 5 GHz bands."
Fix this by clearing the related bits when converting from WMI eht phy capabilities to mac80211 phy capabilities, for bands other than 6GHz.
Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.3.1-00218-QCAHKSWPL_SILICONZ-1
--- drivers/net/wireless/ath/ath12k/wmi.c | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-)
drivers/net/wireless/ath/ath12k/wmi.c +16 -1
@@ -4426,6 +4426,7 @@ static void ath12k_wmi_eht_caps_parse(struct ath12k_pdev *pdev, u32 band, __le32 cap_info_internal) {struct ath12k_band_cap *cap_band = &pdev->cap.band[band]; +u8 *phy_cap = (u8 *)&cap_band->eht_cap_phy_info[0 ];u32 support_320mhz;u8 i;
@@ -4439,8 +4440,22 @@ static void ath12k_wmi_eht_caps_parse(struct ath12k_pdev *pdev, u32 band,for (i =0 ; i <WMI_MAX_EHTCAP_PHY_SIZE ; i++) cap_band->eht_cap_phy_info[i] =le32_to_cpu (cap_phy_info[i]); -if (band ==NL80211_BAND_6GHZ ) +if (band ==NL80211_BAND_6GHZ ) { cap_band->eht_cap_phy_info[0 ] |= support_320mhz; + }else { +/* +* Firmware may report 6 GHz/320 MHz specific capabilities for +* non-6 GHz bands, so explicitly clear them. +*/ + phy_cap[0 ] &= ~IEEE80211_EHT_PHY_CAP0_320MHZ_IN_6GHZ ; + phy_cap[1 ] &= ~IEEE80211_EHT_PHY_CAP1_BEAMFORMEE_SS_320MHZ_MASK ; + phy_cap[2 ] &= ~IEEE80211_EHT_PHY_CAP2_SOUNDING_DIM_320MHZ_MASK ; + phy_cap[3 ] &= ~IEEE80211_EHT_PHY_CAP3_SOUNDING_DIM_320MHZ_MASK ; + phy_cap[6 ] &= ~IEEE80211_EHT_PHY_CAP6_MCS15_SUPP_320MHZ ; + phy_cap[6 ] &= ~IEEE80211_EHT_PHY_CAP6_EHT_DUP_6GHZ_SUPP ; + phy_cap[7 ] &= ~IEEE80211_EHT_PHY_CAP7_NON_OFDMA_UL_MU_MIMO_320MHZ ; + phy_cap[7 ] &= ~IEEE80211_EHT_PHY_CAP7_MU_BEAMFORMER_320MHZ ; + } cap_band->eht_mcs_20_only =le32_to_cpu (supp_mcs[0 ]); cap_band->eht_mcs_80 =le32_to_cpu (supp_mcs[1 ]);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 52/1536 i2c: acpi: Force ELAN1300 touchpads to 100 kHz
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Abhijeeth Babu <[email protected]>
[ Upstream commit 9e9762e578db7556bea644bb5a8a2435f63544d1 ]
The ELAN1300 touchpad with HID ID 04F3:3104 on the ASUS VivoBook X513UA_KM513UA exhibits severe pointer jumps and erratic movement when the I2C bus operates at 400 kHz.
The system DSDT describes the touchpad using an I2cSerialBusV2 resource with a speed of 0x00061A80, corresponding to 400 kHz, on the AMDI0010:03 controller.
At this speed, libinput repeatedly reports:
kernel bug: Touch jump detected and discarded
Add ELAN1300 to i2c_acpi_force_100khz_device_ids so that it operates at 100 kHz.
Before the change, nine touch-jump events were recorded, with additional messages suppressed by libinput's rate limiter. With the bus forced to 100 kHz, no touch-jump events have been observed and the touchpad operates normally.
The affected system uses BIOS X513UA.319 dated 2023-05-09.
--- drivers/i2c/i2c-core-acpi.c | 1 + 1 file changed, 1 insertion(+)
drivers/i2c/i2c-core-acpi.c +1 -0
@@ -372,6 +372,7 @@ static const struct acpi_device_id i2c_acpi_force_100khz_device_ids[] = {*/ { "DLL0945", 0 }, { "ELAN06FA", 0 }, + { "ELAN1300", 0 }, {} };
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 53/1536 drm/amdgpu: Add checks to vbios fetch through ATRM
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lijo Lazar <[email protected]>
[ Upstream commit 8c3fcfc14fc1320a1155acb2dd7656fce7003bc0 ]
Check if a valid buffer object is returned after ATRM call. Also, match the buffer length against requested size before copying.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c +8 -2
@@ -280,8 +280,14 @@ static int amdgpu_atrm_call(acpi_handle atrm_handle, uint8_t *bios, } obj = (union acpi_object *)buffer.pointer; -memcpy (bios+offset, obj->buffer.pointer, obj->buffer.length); - len = obj->buffer.length; +if (!obj || obj->type !=ACPI_TYPE_BUFFER ) { +DRM_ERROR ("ATRM returned an invalid object\n" ); +kfree (buffer.pointer); +return -EINVAL ; + } + + len =min_t (size_t, obj->buffer.length, len); +memcpy (bios+offset, obj->buffer.pointer, len);kfree (buffer.pointer);return len; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 54/1536 drm/amdgpu: Validate ATIF buffer length before use
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lijo Lazar <[email protected]>
[ Upstream commit b978b7d43963bbb3e2d850288f7c21ac11c3b751 ]
Add a min_size parameter to amdgpu_atif_call() to validate that the returned ACPI buffer is of type ACPI_TYPE_BUFFER, holds at least a u16 size field, does not claim more data than was actually returned, and meets the minimum size required by the calling function. Each caller passes its required minimum via sizeof() or offsetof() of the expected output struct and drops its own size check.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c | 68 ++++++++++++------------ 1 file changed, 34 insertions(+), 34 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c +34 -34
@@ -138,13 +138,15 @@ static struct amdgpu_acpi_priv {* @atif: atif structure * @function: the ATIF function to execute * @params: ATIF function params +* @min_size: minimum size of the expected output buffer in bytes * * Executes the requested ATIF function (all asics). * Returns a pointer to the acpi output buffer. */ static union acpi_object *amdgpu_atif_call (struct amdgpu_atif *atif,int function, -struct acpi_buffer *params) +struct acpi_buffer *params, +size_t min_size) {acpi_status status;union acpi_object *obj;
@@ -187,6 +189,28 @@ static union acpi_object *amdgpu_atif_call(struct amdgpu_atif *atif,return NULL ; } +if (obj->buffer.length <sizeof (u16)) { +DRM_DEBUG_DRIVER ("ATIF buffer too small to hold size field: %u\n" , + obj->buffer.length); +kfree (obj); +return NULL ; + } + +if (obj->buffer.length < *(u16 *)obj->buffer.pointer) { +DRM_DEBUG_DRIVER ("ATIF buffer length mismatch: reported %u, actual %u\n" , + *(u16 *)obj->buffer.pointer, + obj->buffer.length); +kfree (obj); +return NULL ; + } + +if (*(u16 *)obj->buffer.pointer < min_size) { +DRM_DEBUG_DRIVER ("ATIF buffer too small: expected %zu, got %u\n" , + min_size, *(u16 *)obj->buffer.pointer); +kfree (obj); +return NULL ; + } +return obj; }
@@ -248,19 +272,14 @@ static int amdgpu_atif_verify_interface(struct amdgpu_atif *atif)size_t size;int err =0 ; - info =amdgpu_atif_call (atif,ATIF_FUNCTION_VERIFY_INTERFACE ,NULL ); + info =amdgpu_atif_call (atif,ATIF_FUNCTION_VERIFY_INTERFACE ,NULL , +sizeof (output));if (!info)return -EIO ;memset (&output,0 ,sizeof (output)); - size = *(u16 *) info->buffer.pointer; -if (size <12 ) { -DRM_INFO ("ATIF buffer is too small: %zu\n" , size); - err = -EINVAL ; - goto out; - } - size =min (sizeof (output), size); + size =min (sizeof (output), (size_t )*(u16 *)info->buffer.pointer);memcpy (&output, info->buffer.pointer, size);
@@ -270,7 +289,6 @@ static int amdgpu_atif_verify_interface(struct amdgpu_atif *atif)amdgpu_atif_parse_notification (&atif->notifications, output.notification_mask);amdgpu_atif_parse_functions (&atif->functions, output.function_bits); -out:kfree (info);return err; }
@@ -295,20 +313,14 @@ static int amdgpu_atif_get_notification_params(struct amdgpu_atif *atif)int err =0 ; info =amdgpu_atif_call (atif,ATIF_FUNCTION_GET_SYSTEM_PARAMETERS , -NULL ); +NULL , offsetof(struct atif_system_params , command_code));if (!info) { err = -EIO ; goto out; } - size = *(u16 *) info->buffer.pointer; -if (size <10 ) { - err = -EINVAL ; - goto out; - } -memset (¶ms,0 ,sizeof (params)); - size =min (sizeof (params), size); + size =min (sizeof (params), (size_t )*(u16 *)info->buffer.pointer);memcpy (¶ms, info->buffer.pointer, size); DRM_DEBUG_DRIVER("SYSTEM_PARAMS: mask = %#x, flags = %#x\n",
@@ -371,20 +383,14 @@ static int amdgpu_atif_query_backlight_caps(struct amdgpu_atif *atif) info =amdgpu_atif_call (atif,ATIF_FUNCTION_QUERY_BRIGHTNESS_TRANSFER_CHARACTERISTICS , - ¶ms); + ¶ms, offsetof(struct atif_qbtc_output , data_points));if (!info) { err = -EIO ; goto out; } - size = *(u16 *) info->buffer.pointer; -if (size <10 ) { - err = -EINVAL ; - goto out; - } -memset (&characteristics,0 ,sizeof (characteristics)); - size =min (sizeof (characteristics), size); + size =min (sizeof (characteristics), (size_t )*(u16 *)info->buffer.pointer);memcpy (&characteristics, info->buffer.pointer, size); atif->backlight_caps.caps_valid = true;
@@ -418,24 +424,18 @@ static int amdgpu_atif_get_sbios_requests(struct amdgpu_atif *atif,int count =0 ; info =amdgpu_atif_call (atif,ATIF_FUNCTION_GET_SYSTEM_BIOS_REQUESTS , -NULL ); +NULL ,sizeof (*req));if (!info)return -EIO ; - size = *(u16 *)info->buffer.pointer; -if (size <0xd ) { - count = -EINVAL ; - goto out; - }memset (req,0 ,sizeof (*req)); - size =min (sizeof (*req), size); + size =min (sizeof (*req), (size_t )*(u16 *)info->buffer.pointer);memcpy (req, info->buffer.pointer, size);DRM_DEBUG_DRIVER ("SBIOS pending requests: %#x\n" , req->pending); count =hweight32 (req->pending); -out:kfree (info);return count; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 55/1536 drm/amd/pm: validate vega10 profile mode inputs
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lijo Lazar <[email protected]>
[ Upstream commit bf939f2a1687ef4ab815640096357f8ef5bd5fb6 ]
Check for out of range profile modes and custom params that exceed 8 bits.
--- drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega10_hwmgr.c | 9 +++++++++ 1 file changed, 9 insertions(+)
drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega10_hwmgr.c +9 -0
@@ -5406,6 +5406,11 @@ static int vega10_set_power_profile_mode(struct pp_hwmgr *hwmgr, long *input, uiuint8_t min_active_level;uint32_t power_profile_mode = input[size]; +if (power_profile_mode >PP_SMC_POWER_PROFILE_CUSTOM ) { +pr_err ("Invalid power profile mode %u\n" , power_profile_mode); +return -EINVAL ; + } +if (power_profile_mode ==PP_SMC_POWER_PROFILE_CUSTOM ) {if (size !=0 && size !=4 )return -EINVAL ;
@@ -5421,6 +5426,10 @@ static int vega10_set_power_profile_mode(struct pp_hwmgr *hwmgr, long *input, uireturn -EINVAL ; } +if ((input[0 ] & ~0xFF ) || (input[1 ] & ~0xFF ) || + (input[2 ] & ~0xFF ) || (input[3 ] & ~0xFF )) +return -EINVAL ; + data->custom_profile_mode[0 ] = busy_set_point = input[0 ]; data->custom_profile_mode[1 ] =FPS = input[1 ]; data->custom_profile_mode[2 ] = use_rlc_busy = input[2 ];
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 38/1536 ASoC: hdac_hdmi: Fix resource cleanup on probe failure
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Haoxiang Li <[email protected]>
[ Upstream commit 785903b7770f19ea05b8a76081dff691c56fa771 ]
hdac_hdmi_dev_probe() gets the HDA link before allocating and initializing the HDMI codec private data. Several later error paths return directly without dropping the link reference, leaving the hlink refcount unbalanced.
Release the link reference on probe failures. Also turn display power off if the failure happens after it has been enabled.
This issue was dicussed in:
https://lore.kernel.org/all/[email protected]/
I think the paths fixed here are probe failure paths: the device has not been fully initialized or bound, and runtime PM suspend cannot be relied on to balance the reference taken during probe.
--- sound/soc/codecs/hdac_hdmi.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-)
sound/soc/codecs/hdac_hdmi.c +8 -2
@@ -2164,8 +2164,10 @@ static int hdac_hdmi_dev_probe(struct hdac_device *hdev)snd_hdac_ext_bus_link_get (hdev->bus, hlink); hdmi_priv =devm_kzalloc (&hdev->dev,sizeof (*hdmi_priv),GFP_KERNEL ); -if (hdmi_priv ==NULL ) +if (hdmi_priv ==NULL ) { +snd_hdac_ext_bus_link_put (hdev->bus, hlink);return -ENOMEM ; + }snd_hdac_register_chmap_ops (hdev, &hdmi_priv->chmap); hdmi_priv->chmap.ops.get_chmap = hdac_hdmi_get_chmap;
@@ -2174,8 +2176,10 @@ static int hdac_hdmi_dev_probe(struct hdac_device *hdev) hdmi_priv->chmap.ops.get_spk_alloc = hdac_hdmi_get_spk_alloc; hdmi_priv->hdev = hdev; -if (!hdac_id) +if (!hdac_id) { +snd_hdac_ext_bus_link_put (hdev->bus, hlink);return -ENODEV ; + }if (hdac_id->driver_data) hdmi_priv->drv_data =
@@ -2200,6 +2204,8 @@ static int hdac_hdmi_dev_probe(struct hdac_device *hdev)if (ret <0 ) {dev_err (&hdev->dev,"Failed in parse and map nid with err: %d\n" , ret); +snd_hdac_ext_bus_link_put (hdev->bus, hlink); +snd_hdac_display_power (hdev->bus, hdev->addr, false);return ret; }snd_hdac_refresh_widgets (hdev);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 56/1536 drm/amdgpu: Support some Barco AMD based graphics adapters
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Matthew Jacob <[email protected]>
[ Upstream commit 3dc4d68ee26a7ac12069ff0562ad8935106c79b6 ]
These adapters typically are only supported by Barco on the Windows platform. However, with these changes in the linux driver, multiple monitor support should work correctly.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c +4 -0
@@ -1904,6 +1904,7 @@ static const struct pci_device_id pciidlist[] = { {0x1002, 0x6646, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_BONAIRE|AMD_IS_MOBILITY}, {0x1002, 0x6647, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_BONAIRE|AMD_IS_MOBILITY}, {0x1002, 0x6649, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_BONAIRE}, + {0x1002, 0x664D, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_BONAIRE}, {0x1002, 0x6650, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_BONAIRE}, {0x1002, 0x6651, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_BONAIRE}, {0x1002, 0x6658, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_BONAIRE},
@@ -1973,6 +1974,7 @@ static const struct pci_device_id pciidlist[] = { {0x1002, 0x6930, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TONGA}, {0x1002, 0x6938, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TONGA}, {0x1002, 0x6939, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TONGA}, + {0x1002, 0x693B, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TONGA},/* fiji */ {0x1002, 0x7300, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_FIJI}, {0x1002, 0x730F, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_FIJI},
@@ -2001,6 +2003,7 @@ static const struct pci_device_id pciidlist[] = { {0x1002, 0x67C4, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS10}, {0x1002, 0x67C7, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS10}, {0x1002, 0x67D0, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS10}, + {0x1002, 0x67D4, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS10}, {0x1002, 0x67DF, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS10}, {0x1002, 0x67C8, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS10}, {0x1002, 0x67C9, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS10},
@@ -2014,6 +2017,7 @@ static const struct pci_device_id pciidlist[] = { {0x1002, 0x6985, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12}, {0x1002, 0x6986, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12}, {0x1002, 0x6987, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12}, + {0x1002, 0x698F, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12}, {0x1002, 0x6995, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12}, {0x1002, 0x6997, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12}, {0x1002, 0x699F, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_POLARIS12},
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 57/1536 drm/amdgpu: Guard reads in pcie state readout
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Lijo Lazar <[email protected]>
[ Upstream commit 230753e46a4a9d04dad6a9b5dbaeb7fd52add7d0 ]
Internal US/DS switch may not be exposed in passthrough. Guard the upstream port reads to avoid a NULL dereference.
--- drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c | 59 +++++++++++++++------- 1 file changed, 42 insertions(+), 17 deletions(-)
drivers/gpu/drm/amd/amdgpu/aqua_vanjaram.c +42 -17
@@ -757,6 +757,29 @@ static struct aqua_reg_list pcie_reg_addrs[] = { { smreg_0x1A380088, 6, DW_ADDR_INCR }, }; +/* +* Return the GPU's internal US switch port, or NULL if it is not visible +* (e.g. passthrough) or the EP is parented under an unrelated bridge. +*/ +static struct pci_dev *aqua_vanjaram_get_us_pdev (struct amdgpu_device *adev) +{ +struct pci_dev *ds_pdev, *us_pdev; + + ds_pdev =pci_upstream_bridge (adev->pdev); +if (!ds_pdev || ds_pdev->vendor !=PCI_VENDOR_ID_ATI || +pci_pcie_type (ds_pdev) !=PCI_EXP_TYPE_DOWNSTREAM ) +return NULL ; + + us_pdev =pci_upstream_bridge (ds_pdev); +if (!us_pdev || + (us_pdev->vendor !=PCI_VENDOR_ID_ATI && + us_pdev->vendor !=PCI_VENDOR_ID_AMD ) || +pci_pcie_type (us_pdev) !=PCI_EXP_TYPE_UPSTREAM ) +return NULL ; + +return us_pdev; +} +static ssize_t aqua_vanjaram_read_pcie_state (struct amdgpu_device *adev,void *buf,size_t max_size) {
@@ -764,7 +787,7 @@ static ssize_t aqua_vanjaram_read_pcie_state(struct amdgpu_device *adev,uint32_t start_addr, incrx, num_regs, szbuf;struct amdgpu_regs_pcie_v1_0 *pcie_regs;struct amdgpu_smn_reg_data *reg_data; -struct pci_dev *us_pdev, *ds_pdev; +struct pci_dev *us_pdev;int aer_cap, r, n;if (!buf || !max_size)
@@ -796,25 +819,27 @@ static ssize_t aqua_vanjaram_read_pcie_state(struct amdgpu_device *adev, } } - ds_pdev =pci_upstream_bridge (adev->pdev); - us_pdev =pci_upstream_bridge (ds_pdev); + us_pdev =aqua_vanjaram_get_us_pdev (adev); +if (us_pdev) { +pcie_capability_read_word (us_pdev,PCI_EXP_DEVSTA , + &pcie_regs->device_status); +pcie_capability_read_word (us_pdev,PCI_EXP_LNKSTA , + &pcie_regs->link_status); + + aer_cap =pci_find_ext_capability (us_pdev,PCI_EXT_CAP_ID_ERR ); +if (aer_cap) { +pci_read_config_dword (us_pdev, + aer_cap +PCI_ERR_COR_STATUS , + &pcie_regs->pcie_corr_err_status); +pci_read_config_dword (us_pdev, + aer_cap +PCI_ERR_UNCOR_STATUS , + &pcie_regs->pcie_uncorr_err_status); + } -pcie_capability_read_word (us_pdev,PCI_EXP_DEVSTA , - &pcie_regs->device_status); -pcie_capability_read_word (us_pdev,PCI_EXP_LNKSTA , - &pcie_regs->link_status); - - aer_cap =pci_find_ext_capability (us_pdev,PCI_EXT_CAP_ID_ERR ); -if (aer_cap) { -pci_read_config_dword (us_pdev, aer_cap +PCI_ERR_COR_STATUS , - &pcie_regs->pcie_corr_err_status); -pci_read_config_dword (us_pdev, aer_cap +PCI_ERR_UNCOR_STATUS , - &pcie_regs->pcie_uncorr_err_status); +pci_read_config_dword (us_pdev,PCI_PRIMARY_BUS , + &pcie_regs->sub_bus_number_latency); } -pci_read_config_dword (us_pdev,PCI_PRIMARY_BUS , - &pcie_regs->sub_bus_number_latency); - pcie_reg_state->common_header.structure_size = szbuf; pcie_reg_state->common_header.format_revision =1 ; pcie_reg_state->common_header.content_revision =0 ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 58/1536 drm/amd/pm: Validate Vega hwmgr PowerPlay table bounds
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yang Wang <[email protected]>
[ Upstream commit 3a8d8e0b7f61cd759d5d4870b6220161f8a5b114 ]
The Vega hwmgr PowerPlay table parsers read fixed table fields, state array entries, or SMC PPT fields before validating that the VBIOS table buffer covers those structures. A truncated table can therefore lead to out-of-bounds reads during hwmgr initialization.
Reject tables smaller than the fixed PowerPlay table. For Vega10, also validate the state array offset and entry range before dereferencing the state array.
--- .../powerplay/hwmgr/vega10_processpptables.c | 59 ++++++++++++------- .../powerplay/hwmgr/vega12_processpptables.c | 7 +++ .../powerplay/hwmgr/vega20_processpptables.c | 7 +++ 3 files changed, 52 insertions(+), 21 deletions(-)
drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega10_processpptables.c +38 -21
@@ -63,14 +63,17 @@ static const void *get_powerplay_table(struct pp_hwmgr *hwmgr)return table_address; } -static int check_powerplay_tables ( -struct pp_hwmgr *hwmgr, -const ATOM_Vega10_POWERPLAYTABLE *powerplay_table) +static int get_vega10_state_array (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +const ATOM_Vega10_State_Array **state_array) {const ATOM_Vega10_State_Array *state_arrays; +u16 state_array_offset; +size_t state_array_size; +size_t table_size = hwmgr->soft_pp_table_size; - state_arrays = (ATOM_Vega10_State_Array *)(((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usStateArrayOffset)); +PP_ASSERT_WITH_CODE ((table_size >=sizeof (*powerplay_table)), +"Invalid PowerPlay Table!" , return -1 ); PP_ASSERT_WITH_CODE((powerplay_table->sHeader.format_revision >= ATOM_Vega10_TABLE_REVISION_VEGA10),
@@ -79,12 +82,34 @@ static int check_powerplay_tables( "State table is not set!", return -1);PP_ASSERT_WITH_CODE (powerplay_table->sHeader.structuresize >0 ,"Invalid PowerPlay Table!" , return -1 ); + + state_array_offset =le16_to_cpu (powerplay_table->usStateArrayOffset); +PP_ASSERT_WITH_CODE ((state_array_offset <= + table_size -sizeof (*state_arrays)), +"Invalid PowerPlay Table!" , return -1 ); + + state_arrays = (ATOM_Vega10_State_Array *)(((unsigned long )powerplay_table) + + state_array_offset);PP_ASSERT_WITH_CODE (state_arrays->ucNumEntries >0 ,"Invalid PowerPlay Table!" , return -1 ); + state_array_size =struct_size (state_arrays, states, state_arrays->ucNumEntries); +PP_ASSERT_WITH_CODE ((state_array_size <= table_size - state_array_offset), +"Invalid PowerPlay Table!" , return -1 ); + + *state_array = state_arrays; +return 0 ; } +static int check_powerplay_tables (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table) +{ +const ATOM_Vega10_State_Array *state_arrays; + +return get_vega10_state_array (hwmgr, powerplay_table, &state_arrays); +} +static int set_platform_caps (struct pp_hwmgr *hwmgr,uint32_t powerplay_caps) { set_hw_cap(
@@ -1249,15 +1274,14 @@ int vega10_get_number_of_powerplay_table_entries(struct pp_hwmgr *hwmgr) {const ATOM_Vega10_State_Array *state_arrays;const ATOM_Vega10_POWERPLAYTABLE *pp_table =get_powerplay_table (hwmgr); +int result;PP_ASSERT_WITH_CODE ((pp_table !=NULL ),"Missing PowerPlay Table!" , return -1 ); -PP_ASSERT_WITH_CODE ((pp_table->sHeader.format_revision >= - ATOM_Vega10_TABLE_REVISION_VEGA10), -"Incorrect PowerPlay table revision!" , return -1 ); - state_arrays = (ATOM_Vega10_State_Array *)(((unsigned long )pp_table) + -le16_to_cpu (pp_table->usStateArrayOffset)); + result =get_vega10_state_array (hwmgr, pp_table, &state_arrays); +PP_ASSERT_WITH_CODE ((result ==0 ), + "Invalid PowerPlay Table State Array.", return result);return (uint32_t )(state_arrays->ucNumEntries); }
@@ -1308,17 +1332,11 @@ int vega10_get_powerplay_table_entry(struct pp_hwmgr *hwmgr,if (pp_table->sHeader.format_revision >= ATOM_Vega10_TABLE_REVISION_VEGA10) { - state_arrays = (ATOM_Vega10_State_Array *) - (((unsigned long )pp_table) + -le16_to_cpu (pp_table->usStateArrayOffset)); - -PP_ASSERT_WITH_CODE (pp_table->usStateArrayOffset >0 , -"Invalid PowerPlay Table State Array Offset." , - return -1 ); -PP_ASSERT_WITH_CODE (state_arrays->ucNumEntries >0 , + result =get_vega10_state_array (hwmgr, pp_table, &state_arrays); +PP_ASSERT_WITH_CODE ((result ==0 ),"Invalid PowerPlay Table State Array." , - return -1 ); -PP_ASSERT_WITH_CODE ((entry_index <= state_arrays->ucNumEntries), + return result); +PP_ASSERT_WITH_CODE ((entry_index < state_arrays->ucNumEntries),"Invalid PowerPlay Table State Array Entry." , return -1 );
@@ -1360,4 +1378,3 @@ int vega10_baco_set_cap(struct pp_hwmgr *hwmgr) PHM_PlatformCaps_BACO);return result; } -
drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega12_processpptables.c +7 -0
@@ -64,6 +64,13 @@ static int check_powerplay_tables(struct pp_hwmgr *hwmgr, const ATOM_Vega12_POWERPLAYTABLE *powerplay_table) { + size_t smc_pptable_size = +offsetofend (ATOM_Vega12_POWERPLAYTABLE, smcPPTable); +size_t table_size = hwmgr->soft_pp_table_size; + +PP_ASSERT_WITH_CODE ((table_size >= smc_pptable_size), +"Invalid PowerPlay Table!" , return -1 ); +PP_ASSERT_WITH_CODE ((powerplay_table->sHeader.format_revision >=ATOM_VEGA12_TABLE_REVISION_VEGA12 ),"Unsupported PPTable format!" , return -1 );
drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega20_processpptables.c +7 -0
@@ -638,6 +638,13 @@ static int check_powerplay_tables(struct pp_hwmgr *hwmgr, const ATOM_Vega20_POWERPLAYTABLE *powerplay_table) { + size_t smc_pptable_size = +offsetofend (ATOM_Vega20_POWERPLAYTABLE, smcPPTable); +size_t table_size = hwmgr->soft_pp_table_size; + +PP_ASSERT_WITH_CODE ((table_size >= smc_pptable_size), +"Invalid PowerPlay Table!" , return -1 ); +PP_ASSERT_WITH_CODE ((powerplay_table->sHeader.format_revision >=ATOM_VEGA20_TABLE_REVISION_VEGA20 ),"Unsupported PPTable format!" , return -1 );
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 59/1536 drm/amd/pm: Validate pp_table header before reading size
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yang Wang <[email protected]>
[ Upstream commit a17e79d01f22182a9fcbe79fcbe2ad1477d43e0f ]
smu_sys_set_pp_table() reads usStructureSize from the uploaded pp_table buffer before validating that the buffer contains a complete ATOM_COMMON_TABLE_HEADER. A short write can therefore make the driver read past the supplied sysfs buffer.
Reject empty or header-short uploads before dereferencing the header pointer.
Keep the existing structure-size check for the full uploaded table.
--- drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-)
drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c +11 -8
@@ -596,25 +596,28 @@ static int smu_sys_set_pp_table(void *handle, {struct smu_context *smu = handle;struct smu_table_context *smu_table = &smu->smu_table; -ATOM_COMMON_TABLE_HEADER *header = (ATOM_COMMON_TABLE_HEADER *)buf; +ATOM_COMMON_TABLE_HEADER *header; +void *hardcode_pptable;int ret =0 ;if (!smu->pm_enabled || !smu->adev->pm.dpm_enabled)return -EOPNOTSUPP ; +if (!buf || size <sizeof (*header)) +return -EINVAL ; + + header = (ATOM_COMMON_TABLE_HEADER *)buf;if (header->usStructureSize != size) {dev_err (smu->adev->dev,"pp table size not matched !\n" );return -EIO ; } -if (!smu_table->hardcode_pptable || smu_table->power_play_table_size < size) { -kfree (smu_table->hardcode_pptable); - smu_table->hardcode_pptable =kzalloc (size,GFP_KERNEL ); -if (!smu_table->hardcode_pptable) -return -ENOMEM ; - } + hardcode_pptable =kmemdup (buf, size,GFP_KERNEL ); +if (!hardcode_pptable) +return -ENOMEM ; -memcpy (smu_table->hardcode_pptable, buf, size); +kfree (smu_table->hardcode_pptable); + smu_table->hardcode_pptable = hardcode_pptable; smu_table->power_play_table = smu_table->hardcode_pptable; smu_table->power_play_table_size = size;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 60/1536 drm/amd/pm: Use uploaded size for legacy custom PPTable
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yang Wang <[email protected]>
[ Upstream commit 055a40c32f3a2dcd4d1a6f85ff4c231cf35f1b53 ]
The legacy powerplay path used to allocate hardcode_pp_table from the original VBIOS PPTable size, copy only the uploaded bytes into it, and keep soft_pp_table_size unchanged. If a custom PPTable is shorter than the original table, later code can still treat the stale tail as valid table data.
Treat the uploaded buffer as the complete custom PPTable: duplicate the uploaded buffer directly, replace hardcode_pp_table atomically, and set soft_pp_table_size to the uploaded size.
--- .../gpu/drm/amd/pm/powerplay/amd_powerplay.c | 21 +++++++------------ 1 file changed, 8 insertions(+), 13 deletions(-)
drivers/gpu/drm/amd/pm/powerplay/amd_powerplay.c +8 -13
@@ -679,25 +679,20 @@ static int amd_powerplay_reset(void *handle)static int pp_dpm_set_pp_table (void *handle,const char *buf,size_t size) {struct pp_hwmgr *hwmgr = handle; +void *hardcode_pp_table;int ret = -ENOMEM ; -if (!hwmgr || !hwmgr->pm_en) -return -EINVAL ; - -if (size > hwmgr->soft_pp_table_size) +if (!hwmgr || !hwmgr->pm_en || !buf || !size || size >U32_MAX )return -EINVAL ; -if (!hwmgr->hardcode_pp_table) { - hwmgr->hardcode_pp_table =kmemdup (hwmgr->soft_pp_table, - hwmgr->soft_pp_table_size, -GFP_KERNEL ); -if (!hwmgr->hardcode_pp_table) -return ret; - } - -memcpy (hwmgr->hardcode_pp_table, buf, size); + hardcode_pp_table =kmemdup (buf, size,GFP_KERNEL ); +if (!hardcode_pp_table) +return ret; +kfree (hwmgr->hardcode_pp_table); + hwmgr->hardcode_pp_table = hardcode_pp_table; hwmgr->soft_pp_table = hwmgr->hardcode_pp_table; + hwmgr->soft_pp_table_size = size; ret =amd_powerplay_reset (handle);if (ret)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 61/1536 drm/amd/pm: Validate Tonga PowerPlay state array bounds
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yang Wang <[email protected]>
[ Upstream commit 1ac24df78c566d767a5ef05a1fe0ecc55bac248d ]
process_pptables_v1_0.c builds the Tonga state array pointer from usStateArrayOffset before checking that the table buffer covers the referenced data. A truncated PowerPlay table can therefore lead to out-of-bounds reads while validating the state array.
Validate the fixed table size first, then check the state array offset and entry range before dereferencing the state array.
--- .../powerplay/hwmgr/process_pptables_v1_0.c | 62 ++++++++++++------- 1 file changed, 40 insertions(+), 22 deletions(-)
drivers/gpu/drm/amd/pm/powerplay/hwmgr/process_pptables_v1_0.c +40 -22
@@ -1113,15 +1113,17 @@ static int init_thermal_controller(* @powerplay_table: Pointer to the PowerPlay Table. * Exception: 2 if the powerplay table is incorrect. */ -static int check_powerplay_tables ( -struct pp_hwmgr *hwmgr, -const ATOM_Tonga_POWERPLAYTABLE *powerplay_table - ) +static int get_tonga_state_array (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const ATOM_Tonga_State_Array **state_array) {const ATOM_Tonga_State_Array *state_arrays; +u16 state_array_offset; +size_t state_array_size; +size_t table_size = hwmgr->soft_pp_table_size; - state_arrays = (ATOM_Tonga_State_Array *)(((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usStateArrayOffset)); +PP_ASSERT_WITH_CODE ((table_size >=sizeof (*powerplay_table)), +"Invalid PowerPlay Table!" , return -1 ); PP_ASSERT_WITH_CODE((ATOM_Tonga_TABLE_REVISION_TONGA <= powerplay_table->sHeader.ucTableFormatRevision),
@@ -1130,12 +1132,34 @@ static int check_powerplay_tables( "State table is not set!", return -1);PP_ASSERT_WITH_CODE ((0 < powerplay_table->sHeader.usStructureSize),"Invalid PowerPlay Table!" , return -1 ); + + state_array_offset =le16_to_cpu (powerplay_table->usStateArrayOffset); +PP_ASSERT_WITH_CODE ((state_array_offset <= + table_size -sizeof (*state_arrays)), +"Invalid PowerPlay Table!" , return -1 ); + + state_arrays = (ATOM_Tonga_State_Array *)(((unsigned long )powerplay_table) + + state_array_offset);PP_ASSERT_WITH_CODE ((0 < state_arrays->ucNumEntries),"Invalid PowerPlay Table!" , return -1 ); + state_array_size =struct_size (state_arrays, entries, state_arrays->ucNumEntries); +PP_ASSERT_WITH_CODE ((state_array_size <= table_size - state_array_offset), +"Invalid PowerPlay Table!" , return -1 ); + + *state_array = state_arrays; +return 0 ; } +static int check_powerplay_tables (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table) +{ +const ATOM_Tonga_State_Array *state_arrays; + +return get_tonga_state_array (hwmgr, powerplay_table, &state_arrays); +} +static int pp_tables_v1_0_initialize (struct pp_hwmgr *hwmgr) {int result =0 ;
@@ -1239,17 +1263,16 @@ const struct pp_table_func pptable_v1_0_funcs = {int get_number_of_powerplay_table_entries_v1_0 (struct pp_hwmgr *hwmgr) { -ATOM_Tonga_State_Array const *state_arrays; +const ATOM_Tonga_State_Array *state_arrays;const ATOM_Tonga_POWERPLAYTABLE *pp_table =get_powerplay_table (hwmgr); +int result;PP_ASSERT_WITH_CODE ((NULL != pp_table),"Missing PowerPlay Table!" , return -1 ); -PP_ASSERT_WITH_CODE ((pp_table->sHeader.ucTableFormatRevision >= - ATOM_Tonga_TABLE_REVISION_TONGA), -"Incorrect PowerPlay table revision!" , return -1 ); - state_arrays = (ATOM_Tonga_State_Array *)(((unsigned long )pp_table) + -le16_to_cpu (pp_table->usStateArrayOffset)); + result =get_tonga_state_array (hwmgr, pp_table, &state_arrays); +PP_ASSERT_WITH_CODE ((result ==0 ), + "Invalid PowerPlay Table State Array.", return result);return (uint32_t )(state_arrays->ucNumEntries); }
@@ -1380,15 +1403,11 @@ int get_powerplay_table_entry_v1_0(struct pp_hwmgr *hwmgr,if (pp_table->sHeader.ucTableFormatRevision >= ATOM_Tonga_TABLE_REVISION_TONGA) { - state_arrays = (ATOM_Tonga_State_Array *)(((unsigned long )pp_table) + -le16_to_cpu (pp_table->usStateArrayOffset)); - -PP_ASSERT_WITH_CODE ((0 < pp_table->usStateArrayOffset), -"Invalid PowerPlay Table State Array Offset." , return -1 ); -PP_ASSERT_WITH_CODE ((0 < state_arrays->ucNumEntries), -"Invalid PowerPlay Table State Array." , return -1 ); -PP_ASSERT_WITH_CODE ((entry_index <= state_arrays->ucNumEntries), -"Invalid PowerPlay Table State Array Entry." , return -1 ); + result =get_tonga_state_array (hwmgr, pp_table, &state_arrays); +PP_ASSERT_WITH_CODE ((result ==0 ), + "Invalid PowerPlay Table State Array.", return result); +PP_ASSERT_WITH_CODE ((entry_index < state_arrays->ucNumEntries), +"Invalid PowerPlay Table State Array Entry." , return -1 ); state_entry = GET_FLEXIBLE_ARRAY_MEMBER_ADDR( ATOM_Tonga_State, entries,
@@ -1414,4 +1433,3 @@ int get_powerplay_table_entry_v1_0(struct pp_hwmgr *hwmgr,return result; } -
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 62/1536 drm/amd/pm: Guard VBIOS AC timing table walk
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Xiang Liu <[email protected]>
[ Upstream commit 2bf6867e5953a140fc91c3159987656e44ed29fb ]
Reject AC timing blocks with a stride smaller than a dword before walking VBIOS data. A zero stride can otherwise keep reg_data pinned on a nonmatching MEM_ID forever.
Also bound the data-block and END marker reads by the returned VRAM_Info table size so malformed index/data sizes do not push the timing walk past the table.
--- .../drm/amd/pm/powerplay/hwmgr/ppatomctrl.c | 28 +++++++++++++++---- 1 file changed, 22 insertions(+), 6 deletions(-)
drivers/gpu/drm/amd/pm/powerplay/hwmgr/ppatomctrl.c +22 -6
@@ -47,16 +47,22 @@ union voltage_object_info {static int atomctrl_retrieve_ac_timing (uint8_t index,ATOM_INIT_REG_BLOCK *reg_block, +u8 *table_end,pp_atomctrl_mc_reg_table *table) {uint32_t i, j; +u16 stride =le16_to_cpu (reg_block->usRegDataBlkSize);uint8_t tmem_id;ATOM_MEMORY_SETTING_DATA_BLOCK *reg_data = (ATOM_MEMORY_SETTING_DATA_BLOCK *) ((uint8_t *)reg_block + (2 *sizeof (uint16_t )) +le16_to_cpu (reg_block->usRegIndexTblSize));uint8_t num_ranges =0 ; -while (*(uint32_t *)reg_data !=END_OF_REG_DATA_BLOCK && +if (stride <sizeof (uint32_t )) +return -EINVAL ; + +while ((uint8_t *)reg_data +sizeof (uint32_t ) <= table_end && + *(uint32_t *)reg_data !=END_OF_REG_DATA_BLOCK && num_ranges <VBIOS_MAX_AC_TIMING_ENTRIES ) { tmem_id = (uint8_t )((*(uint32_t *)reg_data &MEM_ID_MASK ) >>MEM_ID_SHIFT );
@@ -68,6 +74,10 @@ static int atomctrl_retrieve_ac_timing(for (i =0 , j =1 ; i < table->last; i++) {if ((table->mc_reg_address[i].uc_pre_reg_data &LOW_NIBBLE_MASK ) ==DATA_FROM_TABLE ) { +if ((uint8_t *)reg_data + + (j +1 ) *sizeof (uint32_t ) > table_end) +return -EINVAL ; + table->mc_reg_table_entry[num_ranges].mc_data[i] = (uint32_t )*((uint32_t *)reg_data + j); j++;
@@ -82,11 +92,13 @@ static int atomctrl_retrieve_ac_timing( } reg_data = (ATOM_MEMORY_SETTING_DATA_BLOCK *) - ((uint8_t *)reg_data +le16_to_cpu (reg_block->usRegDataBlkSize)) ; + ((uint8_t *)reg_data + stride); } -PP_ASSERT_WITH_CODE ((*(uint32_t *)reg_data ==END_OF_REG_DATA_BLOCK ), -"Invalid VramInfo table." , return -1 ); +if ((uint8_t *)reg_data +sizeof (uint32_t ) > table_end || + *(uint32_t *)reg_data !=END_OF_REG_DATA_BLOCK ) +return -EINVAL ; + table->num_entries = num_ranges;return 0 ;
@@ -137,6 +149,7 @@ int atomctrl_initialize_mc_reg_table( {ATOM_VRAM_INFO_HEADER_V2_1 *vram_info;ATOM_INIT_REG_BLOCK *reg_block; +u8 *table_end;int result =0 ;u8 frev, crev;u16 size;
@@ -158,6 +171,7 @@ int atomctrl_initialize_mc_reg_table( }if (0 == result) { + table_end = (uint8_t *)vram_info + size; reg_block = (ATOM_INIT_REG_BLOCK *) ((uint8_t *)vram_info +le16_to_cpu (vram_info->usMemClkPatchTblOffset)); result =atomctrl_set_mc_reg_address_table (reg_block, table);
@@ -165,7 +179,7 @@ int atomctrl_initialize_mc_reg_table(if (0 == result) { result =atomctrl_retrieve_ac_timing (module_index, - reg_block, table); + reg_block, table_end, table); }return result;
@@ -178,6 +192,7 @@ int atomctrl_initialize_mc_reg_table_v2_2( {ATOM_VRAM_INFO_HEADER_V2_2 *vram_info;ATOM_INIT_REG_BLOCK *reg_block; +u8 *table_end;int result =0 ;u8 frev, crev;u16 size;
@@ -199,6 +214,7 @@ int atomctrl_initialize_mc_reg_table_v2_2( }if (0 == result) { + table_end = (uint8_t *)vram_info + size; reg_block = (ATOM_INIT_REG_BLOCK *) ((uint8_t *)vram_info +le16_to_cpu (vram_info->usMemClkPatchTblOffset)); result =atomctrl_set_mc_reg_address_table (reg_block, table);
@@ -206,7 +222,7 @@ int atomctrl_initialize_mc_reg_table_v2_2(if (0 == result) { result =atomctrl_retrieve_ac_timing (module_index, - reg_block, table); + reg_block, table_end, table); }return result;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 63/1536 drm/amd/pm: Validate Tonga PPTable subtable bounds
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yang Wang <[email protected]>
[ Upstream commit 53ef33c084c5778cc2dcd1efff25e31b6e231141 ]
v1:
Tonga PPTable parsing also relies on VBIOS offsets, revision fields and entry counts for several subtables. Malformed data can cause out-of-bounds reads, while voltage lookup tables can overrun their fixed-size destination arrays.
Add common bounds helpers and validate fixed subtables, dynamic entry arrays and revision-specific layouts before consuming voltage lookup, dependency, PCIE, power-tune, hard-limit, thermal, fan, GPIO, PPM and VCE state data.
v2:
correct to handle get_tonga_ppm_table() return value.
--- .../powerplay/hwmgr/process_pptables_v1_0.c | 606 +++++++++++++++--- 1 file changed, 521 insertions(+), 85 deletions(-)
drivers/gpu/drm/amd/pm/powerplay/hwmgr/process_pptables_v1_0.c +521 -85
@@ -150,6 +150,368 @@ static const void *get_powerplay_table(struct pp_hwmgr *hwmgr)return table_address; } +static bool tonga_pp_table_has_space (struct pp_hwmgr *hwmgr,size_t offset, +size_t size) +{ +size_t table_size = hwmgr->soft_pp_table_size; + +return offset <= table_size && size <= table_size - offset; +} + +static int get_tonga_subtable (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +u16 table_offset,size_t table_size,const void **table) +{ +PP_ASSERT_WITH_CODE ((table_offset !=0 ), +"Invalid PowerPlay Table!" , return -1 ); +PP_ASSERT_WITH_CODE ((tonga_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + + *table = (const void *)(((unsigned long )powerplay_table) + table_offset); + +return 0 ; +} + +static int validate_tonga_table_entries (struct pp_hwmgr *hwmgr, +u16 table_offset,size_t entries_offset, +u8 num_entries,size_t entry_size) +{ +size_t table_size; + +PP_ASSERT_WITH_CODE ((num_entries !=0 ), +"Invalid PowerPlay Table!" , return -1 ); + + table_size = entries_offset + num_entries * entry_size; +PP_ASSERT_WITH_CODE ((tonga_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + +return 0 ; +} + +static int get_tonga_voltage_lookup_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +u16 table_offset,uint32_t max_levels, +const ATOM_Tonga_Voltage_Lookup_Table **lookup_table) +{ +const ATOM_Tonga_Voltage_Lookup_Table *table; +size_t table_size; +int ret; + + ret =get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + +PP_ASSERT_WITH_CODE ((table->ucNumEntries !=0 && + table->ucNumEntries <= max_levels), +"Invalid PowerPlay Table!" , return -1 ); + + table_size = offsetof(ATOM_Tonga_Voltage_Lookup_Table , entries) + + table->ucNumEntries *sizeof (ATOM_Tonga_Voltage_Lookup_Record); +PP_ASSERT_WITH_CODE ((tonga_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + + *lookup_table = table; + +return 0 ; +} + +static int get_tonga_mclk_dependency_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const ATOM_Tonga_MCLK_Dependency_Table **mclk_dep_table) +{ +const ATOM_Tonga_MCLK_Dependency_Table *table; +u16 table_offset; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usMclkDependencyTableOffset); + ret =get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + + ret =validate_tonga_table_entries (hwmgr, table_offset, + offsetof(ATOM_Tonga_MCLK_Dependency_Table , + entries), + table->ucNumEntries, +sizeof (ATOM_Tonga_MCLK_Dependency_Record)); +if (ret) +return ret; + + *mclk_dep_table = table; + +return 0 ; +} + +static int get_tonga_mm_dependency_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const ATOM_Tonga_MM_Dependency_Table **mm_dep_table) +{ +const ATOM_Tonga_MM_Dependency_Table *table; +u16 table_offset; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usMMDependencyTableOffset); + ret =get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + + ret =validate_tonga_table_entries (hwmgr, table_offset, + offsetof(ATOM_Tonga_MM_Dependency_Table , + entries), + table->ucNumEntries, +sizeof (ATOM_Tonga_MM_Dependency_Record)); +if (ret) +return ret; + + *mm_dep_table = table; + +return 0 ; +} + +static int get_tonga_sclk_dependency_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const PPTable_Generic_SubTable_Header **sclk_dep_table) +{ +const PPTable_Generic_SubTable_Header *header; +u16 table_offset; +size_t entries_offset; +size_t entry_size; +u8 num_entries; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usSclkDependencyTableOffset); + ret =get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*header), (const void **)&header); +if (ret) +return ret; + +if (header->ucRevId <1 ) { +const ATOM_Tonga_SCLK_Dependency_Table *table = + (const ATOM_Tonga_SCLK_Dependency_Table *)header; + + entries_offset = offsetof(ATOM_Tonga_SCLK_Dependency_Table , entries); + entry_size =sizeof (ATOM_Tonga_SCLK_Dependency_Record); + num_entries = table->ucNumEntries; + }else { +const ATOM_Polaris_SCLK_Dependency_Table *table = + (const ATOM_Polaris_SCLK_Dependency_Table *)header; + + entries_offset = offsetof(ATOM_Polaris_SCLK_Dependency_Table , entries); + entry_size =sizeof (ATOM_Polaris_SCLK_Dependency_Record); + num_entries = table->ucNumEntries; + } + + ret =validate_tonga_table_entries (hwmgr, table_offset, entries_offset, + num_entries, entry_size); +if (ret) +return ret; + + *sclk_dep_table = header; + +return 0 ; +} + +static int get_tonga_pcie_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const PPTable_Generic_SubTable_Header **pcie_table) +{ +const PPTable_Generic_SubTable_Header *header; +u16 table_offset; +size_t entries_offset; +size_t entry_size; +u8 num_entries; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usPCIETableOffset); + ret =get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*header), (const void **)&header); +if (ret) +return ret; + +if (header->ucRevId <1 ) { +const ATOM_Tonga_PCIE_Table *table = + (const ATOM_Tonga_PCIE_Table *)header; + + entries_offset = offsetof(ATOM_Tonga_PCIE_Table , entries); + entry_size =sizeof (ATOM_Tonga_PCIE_Record); + num_entries = table->ucNumEntries; + }else { +const ATOM_Polaris10_PCIE_Table *table = + (const ATOM_Polaris10_PCIE_Table *)header; + + entries_offset = offsetof(ATOM_Polaris10_PCIE_Table , entries); + entry_size =sizeof (ATOM_Polaris10_PCIE_Record); + num_entries = table->ucNumEntries; + } + + ret =validate_tonga_table_entries (hwmgr, table_offset, entries_offset, + num_entries, entry_size); +if (ret) +return ret; + + *pcie_table = header; + +return 0 ; +} + +static int get_tonga_hard_limit_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const ATOM_Tonga_Hard_Limit_Table **hard_limit_table) +{ +const ATOM_Tonga_Hard_Limit_Table *table; +u16 table_offset; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usHardLimitTableOffset); + ret =get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + + ret =validate_tonga_table_entries (hwmgr, table_offset, + offsetof(ATOM_Tonga_Hard_Limit_Table , + entries), + table->ucNumEntries, +sizeof (ATOM_Tonga_Hard_Limit_Record)); +if (ret) +return ret; + + *hard_limit_table = table; + +return 0 ; +} + +static int get_tonga_thermal_controller_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const ATOM_Tonga_Thermal_Controller **thermal_controller) +{ +u16 table_offset; + + table_offset =le16_to_cpu (powerplay_table->usThermalControllerOffset); + +return get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (**thermal_controller), + (const void **)thermal_controller); +} + +static int get_tonga_fan_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const PPTable_Generic_SubTable_Header **fan_table) +{ +const PPTable_Generic_SubTable_Header *header; +u16 table_offset; +size_t table_size; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usFanTableOffset); + ret =get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*header), (const void **)&header); +if (ret) +return ret; + +if (header->ucRevId <8 ) + table_size =sizeof (ATOM_Tonga_Fan_Table); +else if (header->ucRevId ==8 ) + table_size =sizeof (ATOM_Fiji_Fan_Table); +else + table_size =sizeof (ATOM_Polaris_Fan_Table); + +PP_ASSERT_WITH_CODE ((tonga_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + + *fan_table = header; + +return 0 ; +} + +static int get_tonga_power_tune_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const PPTable_Generic_SubTable_Header **power_tune_table) +{ +const PPTable_Generic_SubTable_Header *header; +u16 table_offset; +size_t table_size; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usPowerTuneTableOffset); + ret =get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*header), (const void **)&header); +if (ret) +return ret; + +if (header->ucRevId <3 ) + table_size =sizeof (ATOM_Tonga_PowerTune_Table); +else if (header->ucRevId <4 ) + table_size =sizeof (ATOM_Fiji_PowerTune_Table); +else + table_size =sizeof (ATOM_Polaris_PowerTune_Table); + +PP_ASSERT_WITH_CODE ((tonga_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + + *power_tune_table = header; + +return 0 ; +} + +static int get_tonga_ppm_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const ATOM_Tonga_PPM_Table **ppm_table) +{ +u16 table_offset; + + table_offset =le16_to_cpu (powerplay_table->usPPMTableOffset); + +return get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (**ppm_table), (const void **)ppm_table); +} + +static int get_tonga_gpio_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const ATOM_Tonga_GPIO_Table **gpio_table) +{ +u16 table_offset; + + table_offset =le16_to_cpu (powerplay_table->usGPIOTableOffset); + +return get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (**gpio_table), (const void **)gpio_table); +} + +static int get_tonga_vce_state_table (struct pp_hwmgr *hwmgr, +const ATOM_Tonga_POWERPLAYTABLE *powerplay_table, +const ATOM_Tonga_VCE_State_Table **vce_state_table) +{ +const ATOM_Tonga_VCE_State_Table *table; +u16 table_offset; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usVCEStateTableOffset); + ret =get_tonga_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + + ret =validate_tonga_table_entries (hwmgr, table_offset, + offsetof(ATOM_Tonga_VCE_State_Table , + entries), + table->ucNumEntries, +sizeof (ATOM_Tonga_VCE_State_Record)); +if (ret) +return ret; + + *vce_state_table = table; + +return 0 ; +} + static int get_vddc_lookup_table( struct pp_hwmgr *hwmgr, phm_ppt_v1_voltage_lookup_table **lookup_table,
@@ -198,7 +560,7 @@ static int get_vddc_lookup_table(*/ static int get_platform_power_management_table (struct pp_hwmgr *hwmgr, -ATOM_Tonga_PPM_Table *atom_ppm_table) +const ATOM_Tonga_PPM_Table *atom_ppm_table) {struct phm_ppm_table *ptr =kzalloc (sizeof (*ptr),GFP_KERNEL ); struct phm_ppt_v1_information *pp_table_information =
@@ -246,7 +608,7 @@ static int init_dpm_2_parameters( {int result =0 ;struct phm_ppt_v1_information *pp_table_information = (struct phm_ppt_v1_information *)(hwmgr->pptable); -ATOM_Tonga_PPM_Table *atom_ppm_table; +const ATOM_Tonga_PPM_Table *atom_ppm_table;uint32_t disable_ppm =0 ;uint32_t disable_power_control =0 ;
@@ -275,30 +637,39 @@ static int init_dpm_2_parameters( }if (0 != powerplay_table->usVddcLookupTableOffset) { -const ATOM_Tonga_Voltage_Lookup_Table *pVddcCACTable = - (ATOM_Tonga_Voltage_Lookup_Table *)(((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usVddcLookupTableOffset)); - - result =get_vddc_lookup_table (hwmgr, - &pp_table_information->vddc_lookup_table, pVddcCACTable,16 ); +const ATOM_Tonga_Voltage_Lookup_Table *pVddcCACTable; + + result =get_tonga_voltage_lookup_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usVddcLookupTableOffset), +16 , &pVddcCACTable); +if (!result) + result =get_vddc_lookup_table (hwmgr, + &pp_table_information->vddc_lookup_table, + pVddcCACTable,16 ); } -if (0 != powerplay_table->usVddgfxLookupTableOffset) { -const ATOM_Tonga_Voltage_Lookup_Table *pVddgfxCACTable = - (ATOM_Tonga_Voltage_Lookup_Table *)(((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usVddgfxLookupTableOffset)); +if (!result &&0 != powerplay_table->usVddgfxLookupTableOffset) { +const ATOM_Tonga_Voltage_Lookup_Table *pVddgfxCACTable; - result =get_vddc_lookup_table (hwmgr, - &pp_table_information->vddgfx_lookup_table, pVddgfxCACTable,16 ); + result =get_tonga_voltage_lookup_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usVddgfxLookupTableOffset), +16 , &pVddgfxCACTable); +if (!result) + result =get_vddc_lookup_table (hwmgr, + &pp_table_information->vddgfx_lookup_table, + pVddgfxCACTable,16 ); } disable_ppm =0 ;if (0 == disable_ppm) { - atom_ppm_table = (ATOM_Tonga_PPM_Table *) - (((unsigned long )powerplay_table) +le16_to_cpu (powerplay_table->usPPMTableOffset)); -if (0 != powerplay_table->usPPMTableOffset) { -if (get_platform_power_management_table (hwmgr, atom_ppm_table) ==0 ) { +int ret; + + ret =get_tonga_ppm_table (hwmgr, powerplay_table, + &atom_ppm_table); +if (!ret && +get_platform_power_management_table (hwmgr, + atom_ppm_table) ==0 ) {phm_cap_set (hwmgr->platform_descriptor.platformCaps, PHM_PlatformCaps_EnablePlatformPowerManagement); }
@@ -792,28 +1163,13 @@ static int init_clock_voltage_dependency(int result =0 ;struct phm_ppt_v1_information *pp_table_information = (struct phm_ppt_v1_information *)(hwmgr->pptable); - -const ATOM_Tonga_MM_Dependency_Table *mm_dependency_table = - (const ATOM_Tonga_MM_Dependency_Table *)(((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usMMDependencyTableOffset)); -const PPTable_Generic_SubTable_Header *pPowerTuneTable = - (const PPTable_Generic_SubTable_Header *)(((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usPowerTuneTableOffset)); -const ATOM_Tonga_MCLK_Dependency_Table *mclk_dep_table = - (const ATOM_Tonga_MCLK_Dependency_Table *)(((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usMclkDependencyTableOffset)); -const PPTable_Generic_SubTable_Header *sclk_dep_table = - (const PPTable_Generic_SubTable_Header *)(((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usSclkDependencyTableOffset)); -const ATOM_Tonga_Hard_Limit_Table *pHardLimits = - (const ATOM_Tonga_Hard_Limit_Table *)(((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usHardLimitTableOffset)); -const PPTable_Generic_SubTable_Header *pcie_table = - (const PPTable_Generic_SubTable_Header *)(((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usPCIETableOffset)); -const ATOM_Tonga_GPIO_Table *gpio_table = - (const ATOM_Tonga_GPIO_Table *)(((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usGPIOTableOffset)); +const ATOM_Tonga_MM_Dependency_Table *mm_dependency_table; +const PPTable_Generic_SubTable_Header *pPowerTuneTable; +const ATOM_Tonga_MCLK_Dependency_Table *mclk_dep_table; +const PPTable_Generic_SubTable_Header *sclk_dep_table; +const ATOM_Tonga_Hard_Limit_Table *pHardLimits; +const PPTable_Generic_SubTable_Header *pcie_table; +const ATOM_Tonga_GPIO_Table *gpio_table; pp_table_information->vdd_dep_on_sclk =NULL ; pp_table_information->vdd_dep_on_mclk =NULL ;
@@ -821,29 +1177,58 @@ static int init_clock_voltage_dependency( pp_table_information->pcie_table =NULL ; pp_table_information->gpio_table =NULL ; -if (powerplay_table->usMMDependencyTableOffset !=0 ) - result =get_mm_clock_voltage_table (hwmgr, - &pp_table_information->mm_dep_table, mm_dependency_table); +if (powerplay_table->usMMDependencyTableOffset !=0 ) { + result =get_tonga_mm_dependency_table (hwmgr, powerplay_table, + &mm_dependency_table); +if (!result) + result =get_mm_clock_voltage_table (hwmgr, + &pp_table_information->mm_dep_table, + mm_dependency_table); + } -if (result ==0 && powerplay_table->usPowerTuneTableOffset !=0 ) - result =get_cac_tdp_table (hwmgr, - &pp_table_information->cac_dtp_table, pPowerTuneTable); +if (result ==0 && powerplay_table->usPowerTuneTableOffset !=0 ) { + result =get_tonga_power_tune_table (hwmgr, powerplay_table, + &pPowerTuneTable); +if (!result) + result =get_cac_tdp_table (hwmgr, + &pp_table_information->cac_dtp_table, + pPowerTuneTable); + } -if (result ==0 && powerplay_table->usSclkDependencyTableOffset !=0 ) - result =get_sclk_voltage_dependency_table (hwmgr, - &pp_table_information->vdd_dep_on_sclk, sclk_dep_table); +if (result ==0 && powerplay_table->usSclkDependencyTableOffset !=0 ) { + result =get_tonga_sclk_dependency_table (hwmgr, powerplay_table, + &sclk_dep_table); +if (!result) + result =get_sclk_voltage_dependency_table (hwmgr, + &pp_table_information->vdd_dep_on_sclk, + sclk_dep_table); + } -if (result ==0 && powerplay_table->usMclkDependencyTableOffset !=0 ) - result =get_mclk_voltage_dependency_table (hwmgr, - &pp_table_information->vdd_dep_on_mclk, mclk_dep_table); +if (result ==0 && powerplay_table->usMclkDependencyTableOffset !=0 ) { + result =get_tonga_mclk_dependency_table (hwmgr, powerplay_table, + &mclk_dep_table); +if (!result) + result =get_mclk_voltage_dependency_table (hwmgr, + &pp_table_information->vdd_dep_on_mclk, + mclk_dep_table); + } -if (result ==0 && powerplay_table->usPCIETableOffset !=0 ) - result =get_pcie_table (hwmgr, - &pp_table_information->pcie_table, pcie_table); +if (result ==0 && powerplay_table->usPCIETableOffset !=0 ) { + result =get_tonga_pcie_table (hwmgr, powerplay_table, + &pcie_table); +if (!result) + result =get_pcie_table (hwmgr, + &pp_table_information->pcie_table, pcie_table); + } -if (result ==0 && powerplay_table->usHardLimitTableOffset !=0 ) - result =get_hard_limits (hwmgr, - &pp_table_information->max_clock_voltage_on_dc, pHardLimits); +if (result ==0 && powerplay_table->usHardLimitTableOffset !=0 ) { + result =get_tonga_hard_limit_table (hwmgr, powerplay_table, + &pHardLimits); +if (!result) + result =get_hard_limits (hwmgr, + &pp_table_information->max_clock_voltage_on_dc, + pHardLimits); + } hwmgr->dyn_state.max_clock_voltage_on_dc.sclk = pp_table_information->max_clock_voltage_on_dc.sclk;
@@ -864,9 +1249,13 @@ static int init_clock_voltage_dependency( result =get_valid_clk (hwmgr, &pp_table_information->valid_sclk_values, pp_table_information->vdd_dep_on_sclk); -if (!result && gpio_table) - result =get_gpio_table (hwmgr, &pp_table_information->gpio_table, - gpio_table); +if (!result && powerplay_table->usGPIOTableOffset) { + result =get_tonga_gpio_table (hwmgr, powerplay_table, + &gpio_table); +if (!result) + result =get_gpio_table (hwmgr, + &pp_table_information->gpio_table, gpio_table); + }return result; }
@@ -911,14 +1300,17 @@ static int init_thermal_controller( ) {const PPTable_Generic_SubTable_Header *fan_table; -ATOM_Tonga_Thermal_Controller *thermal_controller; +const ATOM_Tonga_Thermal_Controller *thermal_controller; +int ret; - thermal_controller = (ATOM_Tonga_Thermal_Controller *) - (((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usThermalControllerOffset));PP_ASSERT_WITH_CODE ((0 != powerplay_table->usThermalControllerOffset),"Thermal controller table not set!" , return -1 ); + ret =get_tonga_thermal_controller_table (hwmgr, powerplay_table, + &thermal_controller); +if (ret) +return ret; + hwmgr->thermal_controller.ucType = thermal_controller->ucType; hwmgr->thermal_controller.ucI2cLine = thermal_controller->ucI2cLine; hwmgr->thermal_controller.ucI2cAddress = thermal_controller->ucI2cAddress;
@@ -946,12 +1338,13 @@ static int init_thermal_controller(return 0 ; } - fan_table = (const PPTable_Generic_SubTable_Header *) - (((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usFanTableOffset)); -PP_ASSERT_WITH_CODE ((0 != powerplay_table->usFanTableOffset),"Fan table not set!" , return -1 ); + + ret =get_tonga_fan_table (hwmgr, powerplay_table, &fan_table); +if (ret) +return ret; +PP_ASSERT_WITH_CODE ((0 < fan_table->ucRevId),"Unsupported fan table format!" , return -1 );
@@ -1313,13 +1706,15 @@ static int ppt_get_num_of_vce_state_table_entries_v1_0(struct pp_hwmgr *hwmgr) {const ATOM_Tonga_POWERPLAYTABLE *pp_table =get_powerplay_table (hwmgr);const ATOM_Tonga_VCE_State_Table *vce_state_table; +int ret;if (pp_table ==NULL )return 0 ; - vce_state_table = (void *)pp_table + -le16_to_cpu (pp_table->usVCEStateTableOffset); + ret =get_tonga_vce_state_table (hwmgr, pp_table, &vce_state_table); +if (ret) +return 0 ;return vce_state_table->ucNumEntries; }
@@ -1328,18 +1723,39 @@ static int ppt_get_vce_state_table_entry_v1_0(struct pp_hwmgr *hwmgr, uint32_t i struct amd_vce_state *vce_state, void **clock_info, uint32_t *flag) { const ATOM_Tonga_VCE_State_Record *vce_state_record; -ATOM_Tonga_SCLK_Dependency_Record *sclk_dep_record; +ATOM_Tonga_SCLK_Dependency_Record *sclk_dep_record =NULL ; +ATOM_Polaris_SCLK_Dependency_Record *polaris_sclk_dep_record =NULL ;ATOM_Tonga_MCLK_Dependency_Record *mclk_dep_record;ATOM_Tonga_MM_Dependency_Record *mm_dep_record;const ATOM_Tonga_POWERPLAYTABLE *pptable =get_powerplay_table (hwmgr); -const ATOM_Tonga_VCE_State_Table *vce_state_table = (ATOM_Tonga_VCE_State_Table *)(((unsigned long )pptable) - +le16_to_cpu (pptable->usVCEStateTableOffset)); -const ATOM_Tonga_SCLK_Dependency_Table *sclk_dep_table = (ATOM_Tonga_SCLK_Dependency_Table *)(((unsigned long )pptable) - +le16_to_cpu (pptable->usSclkDependencyTableOffset)); -const ATOM_Tonga_MCLK_Dependency_Table *mclk_dep_table = (ATOM_Tonga_MCLK_Dependency_Table *)(((unsigned long )pptable) - +le16_to_cpu (pptable->usMclkDependencyTableOffset)); -const ATOM_Tonga_MM_Dependency_Table *mm_dep_table = (ATOM_Tonga_MM_Dependency_Table *)(((unsigned long )pptable) - +le16_to_cpu (pptable->usMMDependencyTableOffset)); +const ATOM_Tonga_VCE_State_Table *vce_state_table; +const PPTable_Generic_SubTable_Header *sclk_dep_table_header; +const ATOM_Tonga_SCLK_Dependency_Table *sclk_dep_table; +const ATOM_Tonga_MCLK_Dependency_Table *mclk_dep_table; +const ATOM_Tonga_MM_Dependency_Table *mm_dep_table; +int ret; + +if (!pptable) +return -EINVAL ; + + ret =get_tonga_vce_state_table (hwmgr, pptable, &vce_state_table); +if (ret) +return ret; + + ret =get_tonga_sclk_dependency_table (hwmgr, pptable, + &sclk_dep_table_header); +if (ret) +return ret; + sclk_dep_table = (const ATOM_Tonga_SCLK_Dependency_Table *) + sclk_dep_table_header; + + ret =get_tonga_mclk_dependency_table (hwmgr, pptable, &mclk_dep_table); +if (ret) +return ret; + + ret =get_tonga_mm_dependency_table (hwmgr, pptable, &mm_dep_table); +if (ret) +return ret; PP_ASSERT_WITH_CODE((i < vce_state_table->ucNumEntries), "Requested state entry ID is out of range!",
@@ -1348,10 +1764,27 @@ static int ppt_get_vce_state_table_entry_v1_0(struct pp_hwmgr *hwmgr, uint32_t i vce_state_record =GET_FLEXIBLE_ARRAY_MEMBER_ADDR ( ATOM_Tonga_VCE_State_Record, entries, vce_state_table, i); - sclk_dep_record =GET_FLEXIBLE_ARRAY_MEMBER_ADDR ( - ATOM_Tonga_SCLK_Dependency_Record, - entries, sclk_dep_table, - vce_state_record->ucSCLKIndex); +PP_ASSERT_WITH_CODE ((vce_state_record->ucSCLKIndex < + sclk_dep_table->ucNumEntries), +"Invalid PowerPlay Table!" , return -EINVAL ); +PP_ASSERT_WITH_CODE ((vce_state_record->ucVCEClockIndex < + mm_dep_table->ucNumEntries), +"Invalid PowerPlay Table!" , return -EINVAL ); +PP_ASSERT_WITH_CODE ((mclk_dep_table->ucNumEntries !=0 ), +"Invalid PowerPlay Table!" , return -EINVAL ); + +if (sclk_dep_table_header->ucRevId <1 ) + sclk_dep_record =GET_FLEXIBLE_ARRAY_MEMBER_ADDR ( + ATOM_Tonga_SCLK_Dependency_Record, + entries, sclk_dep_table, + vce_state_record->ucSCLKIndex); +else + polaris_sclk_dep_record =GET_FLEXIBLE_ARRAY_MEMBER_ADDR ( + ATOM_Polaris_SCLK_Dependency_Record, + entries, + (ATOM_Polaris_SCLK_Dependency_Table *) + sclk_dep_table_header, + vce_state_record->ucSCLKIndex); mm_dep_record = GET_FLEXIBLE_ARRAY_MEMBER_ADDR( ATOM_Tonga_MM_Dependency_Record, entries, mm_dep_table,
@@ -1360,7 +1793,10 @@ static int ppt_get_vce_state_table_entry_v1_0(struct pp_hwmgr *hwmgr, uint32_t i vce_state->evclk =le32_to_cpu (mm_dep_record->ulEClk); vce_state->ecclk =le32_to_cpu (mm_dep_record->ulEClk); - vce_state->sclk =le32_to_cpu (sclk_dep_record->ulSclk); +if (sclk_dep_record) + vce_state->sclk =le32_to_cpu (sclk_dep_record->ulSclk); +else + vce_state->sclk =le32_to_cpu (polaris_sclk_dep_record->ulSclk);if (vce_state_record->ucMCLKIndex >= mclk_dep_table->ucNumEntries) mclk_dep_record = GET_FLEXIBLE_ARRAY_MEMBER_ADDR(
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 64/1536 drm/amd/pm: Validate Vega10 PPTable subtable bounds
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yang Wang <[email protected]>
[ Upstream commit 9914149f99fd2ddcfd2a8c1053a57d96ec43448e ]
v1:
Vega10 PPTable parsing uses VBIOS-provided offsets, revision fields and entry counts to locate subtables. Malformed data can otherwise drive out-of-bounds reads from soft_pp_table_size, and voltage lookup tables can overrun their fixed-size destination arrays.
Add shared bounds helpers and validate fixed-size subtables, dynamic entry arrays and revision-specific layouts before consuming thermal, fan, power-tune, clock dependency, PCIE, hard-limit and voltage lookup data.
v2:
if ucRevId is not matched, fallback to default table size instead of returning -EINVAL.
--- .../powerplay/hwmgr/vega10_processpptables.c | 564 ++++++++++++++---- 1 file changed, 459 insertions(+), 105 deletions(-)
drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega10_processpptables.c +459 -105
@@ -63,6 +63,46 @@ static const void *get_powerplay_table(struct pp_hwmgr *hwmgr)return table_address; } +static bool vega10_pp_table_has_space (struct pp_hwmgr *hwmgr,size_t offset, +size_t size) +{ +size_t table_size = hwmgr->soft_pp_table_size; + +return offset <= table_size && size <= table_size - offset; +} + +static int get_vega10_subtable (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +u16 table_offset,size_t table_size,const void **table) +{ +PP_ASSERT_WITH_CODE ((table_offset !=0 ), +"Invalid PowerPlay Table!" , return -1 ); +PP_ASSERT_WITH_CODE ((vega10_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + + *table = (const void *)(((unsigned long )powerplay_table) + table_offset); + +return 0 ; +} + +static int validate_vega10_table_entries (struct pp_hwmgr *hwmgr, +u16 table_offset,size_t entries_offset, +u8 num_entries,size_t entry_size) +{ +size_t table_size; + +PP_ASSERT_WITH_CODE ((num_entries !=0 ), +"Invalid PowerPlay Table!" , return -1 ); + + table_size = entries_offset + num_entries * entry_size; +PP_ASSERT_WITH_CODE ((vega10_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + +return 0 ; +} +static int get_vega10_state_array (struct pp_hwmgr *hwmgr,const ATOM_Vega10_POWERPLAYTABLE *powerplay_table,const ATOM_Vega10_State_Array **state_array)
@@ -102,6 +142,293 @@ static int get_vega10_state_array(struct pp_hwmgr *hwmgr,return 0 ; } +static int get_vega10_gfxclk_dependency_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +const ATOM_Vega10_GFXCLK_Dependency_Table **gfxclk_dep_table) +{ +const ATOM_Vega10_GFXCLK_Dependency_Table *table; +u16 table_offset; +size_t table_size; +size_t entry_size; + + table_offset =le16_to_cpu (powerplay_table->usGfxclkDependencyTableOffset); +if (!table_offset) +return -EINVAL ; + +PP_ASSERT_WITH_CODE ((vega10_pp_table_has_space (hwmgr, table_offset, +sizeof (*table))), +"Invalid PowerPlay Table!" , return -1 ); + + table = (const ATOM_Vega10_GFXCLK_Dependency_Table *) + (((unsigned long )powerplay_table) + table_offset); +PP_ASSERT_WITH_CODE ((table->ucNumEntries !=0 ), +"Invalid PowerPlay Table!" , return -1 ); + +if (table->ucRevId ==0 ) + entry_size =sizeof (ATOM_Vega10_GFXCLK_Dependency_Record); +else if (table->ucRevId ==1 ) + entry_size =sizeof (ATOM_Vega10_GFXCLK_Dependency_Record_V2); +else +PP_ASSERT_WITH_CODE (false, +"Unsupported GFXClockDependencyTable Revision!" , + return -EINVAL ); + + table_size = offsetof(ATOM_Vega10_GFXCLK_Dependency_Table , entries) + + table->ucNumEntries * entry_size; +PP_ASSERT_WITH_CODE ((vega10_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + + *gfxclk_dep_table = table; + +return 0 ; +} + +static int get_vega10_clk_dependency_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +u16 table_offset, +const ATOM_Vega10_SOCCLK_Dependency_Table **clk_dep_table) +{ +const ATOM_Vega10_SOCCLK_Dependency_Table *table; +int ret; + + ret =get_vega10_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + + ret =validate_vega10_table_entries (hwmgr, table_offset, + offsetof(ATOM_Vega10_SOCCLK_Dependency_Table , + entries), + table->ucNumEntries, +sizeof (ATOM_Vega10_CLK_Dependency_Record)); +if (ret) +return ret; + + *clk_dep_table = table; + +return 0 ; +} + +static int get_vega10_mclk_dependency_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +const ATOM_Vega10_MCLK_Dependency_Table **mclk_dep_table) +{ +const ATOM_Vega10_MCLK_Dependency_Table *table; +u16 table_offset; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usMclkDependencyTableOffset); + ret =get_vega10_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + + ret =validate_vega10_table_entries (hwmgr, table_offset, + offsetof(ATOM_Vega10_MCLK_Dependency_Table , + entries), + table->ucNumEntries, +sizeof (ATOM_Vega10_MCLK_Dependency_Record)); +if (ret) +return ret; + + *mclk_dep_table = table; + +return 0 ; +} + +static int get_vega10_mm_dependency_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +const ATOM_Vega10_MM_Dependency_Table **mm_dep_table) +{ +const ATOM_Vega10_MM_Dependency_Table *table; +u16 table_offset; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usMMDependencyTableOffset); + ret =get_vega10_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + + ret =validate_vega10_table_entries (hwmgr, table_offset, + offsetof(ATOM_Vega10_MM_Dependency_Table , + entries), + table->ucNumEntries, +sizeof (ATOM_Vega10_MM_Dependency_Record)); +if (ret) +return ret; + + *mm_dep_table = table; + +return 0 ; +} + +static int get_vega10_pcie_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +const Vega10_PPTable_Generic_SubTable_Header **pcie_table) +{ +const ATOM_Vega10_PCIE_Table *table; +u16 table_offset; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usPCIETableOffset); + ret =get_vega10_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + +if (!table->ucNumEntries) { + *pcie_table = (const Vega10_PPTable_Generic_SubTable_Header *)table; +return 0 ; + } + + ret =validate_vega10_table_entries (hwmgr, table_offset, + offsetof(ATOM_Vega10_PCIE_Table , + entries), + table->ucNumEntries, +sizeof (ATOM_Vega10_PCIE_Record)); +if (ret) +return ret; + + *pcie_table = (const Vega10_PPTable_Generic_SubTable_Header *)table; + +return 0 ; +} + +static int get_vega10_hard_limit_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +const ATOM_Vega10_Hard_Limit_Table **hard_limit_table) +{ +const ATOM_Vega10_Hard_Limit_Table *table; +u16 table_offset; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usHardLimitTableOffset); + ret =get_vega10_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + + ret =validate_vega10_table_entries (hwmgr, table_offset, + offsetof(ATOM_Vega10_Hard_Limit_Table , + entries), + table->ucNumEntries, +sizeof (ATOM_Vega10_Hard_Limit_Record)); +if (ret) +return ret; + + *hard_limit_table = table; + +return 0 ; +} + +static int get_vega10_thermal_controller_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +const ATOM_Vega10_Thermal_Controller **thermal_controller) +{ +u16 table_offset; + + table_offset =le16_to_cpu (powerplay_table->usThermalControllerOffset); + +return get_vega10_subtable (hwmgr, powerplay_table, table_offset, +sizeof (**thermal_controller), + (const void **)thermal_controller); +} + +static int get_vega10_fan_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +const Vega10_PPTable_Generic_SubTable_Header **fan_table) +{ +const Vega10_PPTable_Generic_SubTable_Header *header; +u16 table_offset; +size_t table_size; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usFanTableOffset); + ret =get_vega10_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*header), (const void **)&header); +if (ret) +return ret; + +if (header->ucRevId ==10 ) + table_size =sizeof (ATOM_Vega10_Fan_Table); +else if (header->ucRevId ==0xb ) + table_size =sizeof (ATOM_Vega10_Fan_Table_V2); +else if (header->ucRevId >0xb ) + table_size =sizeof (ATOM_Vega10_Fan_Table_V3); +else + table_size =sizeof (*header); + +PP_ASSERT_WITH_CODE ((vega10_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + + *fan_table = header; + +return 0 ; +} + +static int get_vega10_power_tune_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +const Vega10_PPTable_Generic_SubTable_Header **power_tune_table) +{ +const Vega10_PPTable_Generic_SubTable_Header *header; +u16 table_offset; +size_t table_size; +int ret; + + table_offset =le16_to_cpu (powerplay_table->usPowerTuneTableOffset); + ret =get_vega10_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*header), (const void **)&header); +if (ret) +return ret; + +if (header->ucRevId ==5 ) + table_size =sizeof (ATOM_Vega10_PowerTune_Table); +else if (header->ucRevId ==6 ) + table_size =sizeof (ATOM_Vega10_PowerTune_Table_V2); +else + table_size =sizeof (ATOM_Vega10_PowerTune_Table_V3); + +PP_ASSERT_WITH_CODE ((vega10_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + + *power_tune_table = header; + +return 0 ; +} + +static int get_vega10_voltage_lookup_table (struct pp_hwmgr *hwmgr, +const ATOM_Vega10_POWERPLAYTABLE *powerplay_table, +u16 table_offset,uint32_t max_levels, +const ATOM_Vega10_Voltage_Lookup_Table **lookup_table) +{ +const ATOM_Vega10_Voltage_Lookup_Table *table; +size_t table_size; +int ret; + + ret =get_vega10_subtable (hwmgr, powerplay_table, table_offset, +sizeof (*table), (const void **)&table); +if (ret) +return ret; + +PP_ASSERT_WITH_CODE ((table->ucNumEntries !=0 && + table->ucNumEntries <= max_levels), +"Invalid PowerPlay Table!" , return -1 ); + + table_size = offsetof(ATOM_Vega10_Voltage_Lookup_Table , entries) + + table->ucNumEntries *sizeof (ATOM_Vega10_Voltage_Lookup_Record); +PP_ASSERT_WITH_CODE ((vega10_pp_table_has_space (hwmgr, table_offset, + table_size)), +"Invalid PowerPlay Table!" , return -1 ); + + *lookup_table = table; + +return 0 ; +} +static int check_powerplay_tables (struct pp_hwmgr *hwmgr,const ATOM_Vega10_POWERPLAYTABLE *powerplay_table) {
@@ -149,14 +476,16 @@ static int init_thermal_controller(const ATOM_Vega10_Fan_Table *fan_table_v1;const ATOM_Vega10_Fan_Table_V2 *fan_table_v2;const ATOM_Vega10_Fan_Table_V3 *fan_table_v3; - - thermal_controller = (ATOM_Vega10_Thermal_Controller *) - (((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usThermalControllerOffset)); +int ret;PP_ASSERT_WITH_CODE ((powerplay_table->usThermalControllerOffset !=0 ),"Thermal controller table not set!" , return -EINVAL ); + ret =get_vega10_thermal_controller_table (hwmgr, powerplay_table, + &thermal_controller); +if (ret) +return ret; + hwmgr->thermal_controller.ucType = thermal_controller->ucType; hwmgr->thermal_controller.ucI2cLine = thermal_controller->ucI2cLine; hwmgr->thermal_controller.ucI2cAddress = thermal_controller->ucI2cAddress;
@@ -185,9 +514,9 @@ static int init_thermal_controller(if (!powerplay_table->usFanTableOffset)return 0 ; - header = (const Vega10_PPTable_Generic_SubTable_Header *) - (((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usFanTableOffset)); + ret =get_vega10_fan_table (hwmgr, powerplay_table, &header); +if (ret) +return ret;if (header->ucRevId ==10 ) { fan_table_v1 = (ATOM_Vega10_Fan_Table *)header;
@@ -332,12 +661,15 @@ static int init_over_drive_limits(struct pp_hwmgr *hwmgr, const ATOM_Vega10_POWERPLAYTABLE *powerplay_table) { - const ATOM_Vega10_GFXCLK_Dependency_Table *gfxclk_dep_table = - (const ATOM_Vega10_GFXCLK_Dependency_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usGfxclkDependencyTableOffset)); + const ATOM_Vega10_GFXCLK_Dependency_Table *gfxclk_dep_table;bool is_acg_enabled = false;ATOM_Vega10_GFXCLK_Dependency_Record_V2 *patom_record_v2; +int ret; + + ret =get_vega10_gfxclk_dependency_table (hwmgr, powerplay_table, + &gfxclk_dep_table); +if (ret) +return ret;if (gfxclk_dep_table->ucRevId ==1 ) { patom_record_v2 =
@@ -900,51 +1232,13 @@ static int init_powerplay_extended_tables(int result =0 ;struct phm_ppt_v2_information *pp_table_info = (struct phm_ppt_v2_information *)(hwmgr->pptable); - -const ATOM_Vega10_MM_Dependency_Table *mm_dependency_table = - (const ATOM_Vega10_MM_Dependency_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usMMDependencyTableOffset)); -const Vega10_PPTable_Generic_SubTable_Header *power_tune_table = - (const Vega10_PPTable_Generic_SubTable_Header *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usPowerTuneTableOffset)); -const ATOM_Vega10_SOCCLK_Dependency_Table *socclk_dep_table = - (const ATOM_Vega10_SOCCLK_Dependency_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usSocclkDependencyTableOffset)); -const ATOM_Vega10_GFXCLK_Dependency_Table *gfxclk_dep_table = - (const ATOM_Vega10_GFXCLK_Dependency_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usGfxclkDependencyTableOffset)); -const ATOM_Vega10_DCEFCLK_Dependency_Table *dcefclk_dep_table = - (const ATOM_Vega10_DCEFCLK_Dependency_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usDcefclkDependencyTableOffset)); -const ATOM_Vega10_MCLK_Dependency_Table *mclk_dep_table = - (const ATOM_Vega10_MCLK_Dependency_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usMclkDependencyTableOffset)); -const ATOM_Vega10_Hard_Limit_Table *hard_limits = - (const ATOM_Vega10_Hard_Limit_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usHardLimitTableOffset)); -const Vega10_PPTable_Generic_SubTable_Header *pcie_table = - (const Vega10_PPTable_Generic_SubTable_Header *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usPCIETableOffset)); -const ATOM_Vega10_PIXCLK_Dependency_Table *pixclk_dep_table = - (const ATOM_Vega10_PIXCLK_Dependency_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usPixclkDependencyTableOffset)); -const ATOM_Vega10_PHYCLK_Dependency_Table *phyclk_dep_table = - (const ATOM_Vega10_PHYCLK_Dependency_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usPhyClkDependencyTableOffset)); -const ATOM_Vega10_DISPCLK_Dependency_Table *dispclk_dep_table = - (const ATOM_Vega10_DISPCLK_Dependency_Table *) - (((unsigned long ) powerplay_table) + -le16_to_cpu (powerplay_table->usDispClkDependencyTableOffset)); +const ATOM_Vega10_MM_Dependency_Table *mm_dependency_table; +const Vega10_PPTable_Generic_SubTable_Header *power_tune_table; +const ATOM_Vega10_GFXCLK_Dependency_Table *gfxclk_dep_table; +const ATOM_Vega10_MCLK_Dependency_Table *mclk_dep_table; +const ATOM_Vega10_Hard_Limit_Table *hard_limits; +const Vega10_PPTable_Generic_SubTable_Header *pcie_table; +const ATOM_Vega10_SOCCLK_Dependency_Table *clk_dep_table; pp_table_info->vdd_dep_on_socclk =NULL ; pp_table_info->vdd_dep_on_sclk =NULL ;
@@ -956,63 +1250,114 @@ static int init_powerplay_extended_tables( pp_table_info->vdd_dep_on_phyclk =NULL ; pp_table_info->vdd_dep_on_dispclk =NULL ; -if (powerplay_table->usMMDependencyTableOffset) - result =get_mm_clock_voltage_table (hwmgr, +if (powerplay_table->usMMDependencyTableOffset) { + result =get_vega10_mm_dependency_table (hwmgr, powerplay_table, + &mm_dependency_table); +if (!result) + result =get_mm_clock_voltage_table (hwmgr, &pp_table_info->mm_dep_table, mm_dependency_table); + } -if (!result && powerplay_table->usPowerTuneTableOffset) - result =get_tdp_table (hwmgr, +if (!result && powerplay_table->usPowerTuneTableOffset) { + result =get_vega10_power_tune_table (hwmgr, powerplay_table, + &power_tune_table); +if (!result) + result =get_tdp_table (hwmgr, &pp_table_info->tdp_table, power_tune_table); + } -if (!result && powerplay_table->usSocclkDependencyTableOffset) - result =get_socclk_voltage_dependency_table (hwmgr, +if (!result && powerplay_table->usSocclkDependencyTableOffset) { + result =get_vega10_clk_dependency_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usSocclkDependencyTableOffset), + &clk_dep_table); +if (!result) + result =get_socclk_voltage_dependency_table (hwmgr, &pp_table_info->vdd_dep_on_socclk, - socclk_dep_table); + (const ATOM_Vega10_SOCCLK_Dependency_Table *) + clk_dep_table); + } -if (!result && powerplay_table->usGfxclkDependencyTableOffset) - result =get_gfxclk_voltage_dependency_table (hwmgr, - &pp_table_info->vdd_dep_on_sclk, - gfxclk_dep_table); +if (!result && powerplay_table->usGfxclkDependencyTableOffset) { + result =get_vega10_gfxclk_dependency_table (hwmgr, + powerplay_table, &gfxclk_dep_table); +if (!result) + result =get_gfxclk_voltage_dependency_table (hwmgr, + &pp_table_info->vdd_dep_on_sclk, + gfxclk_dep_table); + } -if (!result && powerplay_table->usPixclkDependencyTableOffset) - result =get_pix_clk_voltage_dependency_table (hwmgr, +if (!result && powerplay_table->usPixclkDependencyTableOffset) { + result =get_vega10_clk_dependency_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usPixclkDependencyTableOffset), + &clk_dep_table); +if (!result) + result =get_pix_clk_voltage_dependency_table (hwmgr, &pp_table_info->vdd_dep_on_pixclk, (const ATOM_Vega10_PIXCLK_Dependency_Table *) - pixclk_dep_table); + clk_dep_table); + } -if (!result && powerplay_table->usPhyClkDependencyTableOffset) - result =get_pix_clk_voltage_dependency_table (hwmgr, +if (!result && powerplay_table->usPhyClkDependencyTableOffset) { + result =get_vega10_clk_dependency_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usPhyClkDependencyTableOffset), + &clk_dep_table); +if (!result) + result =get_pix_clk_voltage_dependency_table (hwmgr, &pp_table_info->vdd_dep_on_phyclk, (const ATOM_Vega10_PIXCLK_Dependency_Table *) - phyclk_dep_table); + clk_dep_table); + } -if (!result && powerplay_table->usDispClkDependencyTableOffset) - result =get_pix_clk_voltage_dependency_table (hwmgr, +if (!result && powerplay_table->usDispClkDependencyTableOffset) { + result =get_vega10_clk_dependency_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usDispClkDependencyTableOffset), + &clk_dep_table); +if (!result) + result =get_pix_clk_voltage_dependency_table (hwmgr, &pp_table_info->vdd_dep_on_dispclk, (const ATOM_Vega10_PIXCLK_Dependency_Table *) - dispclk_dep_table); + clk_dep_table); + } -if (!result && powerplay_table->usDcefclkDependencyTableOffset) - result =get_dcefclk_voltage_dependency_table (hwmgr, +if (!result && powerplay_table->usDcefclkDependencyTableOffset) { + result =get_vega10_clk_dependency_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usDcefclkDependencyTableOffset), + &clk_dep_table); +if (!result) + result =get_dcefclk_voltage_dependency_table (hwmgr, &pp_table_info->vdd_dep_on_dcefclk, - dcefclk_dep_table); + (const ATOM_Vega10_DCEFCLK_Dependency_Table *) + clk_dep_table); + } -if (!result && powerplay_table->usMclkDependencyTableOffset) - result =get_mclk_voltage_dependency_table (hwmgr, +if (!result && powerplay_table->usMclkDependencyTableOffset) { + result =get_vega10_mclk_dependency_table (hwmgr, powerplay_table, + &mclk_dep_table); +if (!result) + result =get_mclk_voltage_dependency_table (hwmgr, &pp_table_info->vdd_dep_on_mclk, mclk_dep_table); + } -if (!result && powerplay_table->usPCIETableOffset) - result =get_pcie_table (hwmgr, +if (!result && powerplay_table->usPCIETableOffset) { + result =get_vega10_pcie_table (hwmgr, powerplay_table, + &pcie_table); +if (!result) + result =get_pcie_table (hwmgr, &pp_table_info->pcie_table, pcie_table); + } -if (!result && powerplay_table->usHardLimitTableOffset) - result =get_hard_limits (hwmgr, +if (!result && powerplay_table->usHardLimitTableOffset) { + result =get_vega10_hard_limit_table (hwmgr, powerplay_table, + &hard_limits); +if (!result) + result =get_hard_limits (hwmgr, &pp_table_info->max_clock_voltage_on_dc, hard_limits); + } hwmgr->dyn_state.max_clock_voltage_on_dc.sclk = pp_table_info->max_clock_voltage_on_dc.sclk;
@@ -1140,30 +1485,39 @@ static int init_dpm_2_parameters( }if (powerplay_table->usVddcLookupTableOffset) { -const ATOM_Vega10_Voltage_Lookup_Table *vddc_table = - (ATOM_Vega10_Voltage_Lookup_Table *) - (((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usVddcLookupTableOffset)); - result =get_vddc_lookup_table (hwmgr, - &pp_table_info->vddc_lookup_table, vddc_table,8 ); +const ATOM_Vega10_Voltage_Lookup_Table *vddc_table; + + result =get_vega10_voltage_lookup_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usVddcLookupTableOffset), +8 , &vddc_table); +if (!result) + result =get_vddc_lookup_table (hwmgr, + &pp_table_info->vddc_lookup_table, + vddc_table,8 ); } -if (powerplay_table->usVddmemLookupTableOffset) { -const ATOM_Vega10_Voltage_Lookup_Table *vdd_mem_table = - (ATOM_Vega10_Voltage_Lookup_Table *) - (((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usVddmemLookupTableOffset)); - result =get_vddc_lookup_table (hwmgr, - &pp_table_info->vddmem_lookup_table, vdd_mem_table,4 ); +if (!result && powerplay_table->usVddmemLookupTableOffset) { +const ATOM_Vega10_Voltage_Lookup_Table *vdd_mem_table; + + result =get_vega10_voltage_lookup_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usVddmemLookupTableOffset), +4 , &vdd_mem_table); +if (!result) + result =get_vddc_lookup_table (hwmgr, + &pp_table_info->vddmem_lookup_table, + vdd_mem_table,4 ); } -if (powerplay_table->usVddciLookupTableOffset) { -const ATOM_Vega10_Voltage_Lookup_Table *vddci_table = - (ATOM_Vega10_Voltage_Lookup_Table *) - (((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usVddciLookupTableOffset)); - result =get_vddc_lookup_table (hwmgr, - &pp_table_info->vddci_lookup_table, vddci_table,4 ); +if (!result && powerplay_table->usVddciLookupTableOffset) { +const ATOM_Vega10_Voltage_Lookup_Table *vddci_table; + + result =get_vega10_voltage_lookup_table (hwmgr, powerplay_table, +le16_to_cpu (powerplay_table->usVddciLookupTableOffset), +4 , &vddci_table); +if (!result) + result =get_vddc_lookup_table (hwmgr, + &pp_table_info->vddci_lookup_table, + vddci_table,4 ); }return result;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 65/1536 drm/amd/pm: Validate legacy hwmgr PP table offsets
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yang Wang <[email protected]>
[ Upstream commit 0ceb6bc43e62f0e73b282c9de8f4bc4d5498f281 ]
processpptables.c walks several variable-length PPLIB tables by using offsets from the VBIOS PowerPlay table. Some paths dereference extended headers, state arrays, clock arrays, non-clock arrays, or VCE records before checking that the referenced data is inside the table buffer.
Add local bounds helpers and validate the relevant offsets and entry sizes before dereferencing them. This prevents truncated or malformed legacy PowerPlay tables from driving out-of-bounds reads during hwmgr initialization and table entry lookup.
--- .../amd/pm/powerplay/hwmgr/processpptables.c | 446 +++++++++++++----- 1 file changed, 316 insertions(+), 130 deletions(-)
drivers/gpu/drm/amd/pm/powerplay/hwmgr/processpptables.c +316 -130
@@ -47,26 +47,53 @@#define NUM_BITS_CLOCK_INFO_ARRAY_INDEX 6 +static bool pp_table_has_space (struct pp_hwmgr *hwmgr,size_t offset, +size_t size) +{ +size_t table_size = hwmgr->soft_pp_table_size; + +return offset <= table_size && size <= table_size - offset; +} + +static const ATOM_PPLIB_EXTENDEDHEADER * +get_extended_header (struct pp_hwmgr *hwmgr, +const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table, +size_t min_size) +{ +const ATOM_PPLIB_POWERPLAYTABLE3 *powerplay_table3; +const ATOM_PPLIB_EXTENDEDHEADER *extended_header; +u16 offset; + +if (le16_to_cpu (powerplay_table->usTableSize) < +sizeof (ATOM_PPLIB_POWERPLAYTABLE3 ) || + !pp_table_has_space (hwmgr,0 ,sizeof (ATOM_PPLIB_POWERPLAYTABLE3 ))) +return NULL ; + + powerplay_table3 = (const ATOM_PPLIB_POWERPLAYTABLE3 *)powerplay_table; + offset =le16_to_cpu (powerplay_table3->usExtendendedHeaderOffset); +if (!offset || !pp_table_has_space (hwmgr, offset, +sizeof (extended_header->usSize))) +return NULL ; + + extended_header = (const ATOM_PPLIB_EXTENDEDHEADER *) + (((unsigned long )powerplay_table) + offset); +if (le16_to_cpu (extended_header->usSize) < min_size || + !pp_table_has_space (hwmgr, offset, min_size)) +return NULL ; + +return extended_header; +} +static uint16_t get_vce_table_offset (struct pp_hwmgr *hwmgr,const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table) {uint16_t vce_table_offset =0 ; +const ATOM_PPLIB_EXTENDEDHEADER *extended_header; -if (le16_to_cpu (powerplay_table->usTableSize) >= -sizeof (ATOM_PPLIB_POWERPLAYTABLE3 )) { -const ATOM_PPLIB_POWERPLAYTABLE3 *powerplay_table3 = - (const ATOM_PPLIB_POWERPLAYTABLE3 *)powerplay_table; - -if (powerplay_table3->usExtendendedHeaderOffset >0 ) { -const ATOM_PPLIB_EXTENDEDHEADER *extended_header = - (const ATOM_PPLIB_EXTENDEDHEADER *) - (((unsigned long )powerplay_table3) + -le16_to_cpu (powerplay_table3->usExtendendedHeaderOffset)); -if (le16_to_cpu (extended_header->usSize) >= -SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V2 ) - vce_table_offset =le16_to_cpu (extended_header->usVCETableOffset); - } - } + extended_header =get_extended_header (hwmgr, powerplay_table, +SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V2 ); +if (extended_header) + vce_table_offset =le16_to_cpu (extended_header->usVCETableOffset);return vce_table_offset; }
@@ -93,7 +120,14 @@ static uint16_t get_vce_clock_info_array_size(struct pp_hwmgr *hwmgr,if (table_offset >0 ) {const VCEClockInfoArray *p = (const VCEClockInfoArray *) (((unsigned long ) powerplay_table) + table_offset); - table_size =sizeof (uint8_t ) + p->ucNumEntries *sizeof (VCEClockInfo); +size_t size; + +if (!pp_table_has_space (hwmgr, table_offset,sizeof (p->ucNumEntries))) +return 0 ; + + size =sizeof (uint8_t ) + p->ucNumEntries *sizeof (VCEClockInfo); +if (pp_table_has_space (hwmgr, table_offset, size)) + table_size = size; }return table_size;
@@ -104,10 +138,13 @@ static uint16_t get_vce_clock_voltage_limit_table_offset(struct pp_hwmgr *hwmgr, {uint16_t table_offset =get_vce_clock_info_array_offset (hwmgr, powerplay_table); +u16 table_size; -if (table_offset >0 ) -return table_offset +get_vce_clock_info_array_size (hwmgr, - powerplay_table); +if (table_offset >0 ) { + table_size =get_vce_clock_info_array_size (hwmgr, powerplay_table); +if (table_size) +return table_offset + table_size; + }return 0 ; }
@@ -121,8 +158,15 @@ static uint16_t get_vce_clock_voltage_limit_table_size(struct pp_hwmgr *hwmgr,if (table_offset >0 ) {const ATOM_PPLIB_VCE_Clock_Voltage_Limit_Table *ptable = (const ATOM_PPLIB_VCE_Clock_Voltage_Limit_Table *)(((unsigned long ) powerplay_table) + table_offset); +size_t size; - table_size =sizeof (uint8_t ) + ptable->numEntries *sizeof (ATOM_PPLIB_VCE_Clock_Voltage_Limit_Record); +if (!pp_table_has_space (hwmgr, table_offset,sizeof (ptable->numEntries))) +return 0 ; + + size =sizeof (uint8_t ) + + ptable->numEntries *sizeof (ATOM_PPLIB_VCE_Clock_Voltage_Limit_Record); +if (pp_table_has_space (hwmgr, table_offset, size)) + table_size = size; }return table_size; }
@@ -130,9 +174,13 @@ static uint16_t get_vce_clock_voltage_limit_table_size(struct pp_hwmgr *hwmgr,static uint16_t get_vce_state_table_offset (struct pp_hwmgr *hwmgr,const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table) {uint16_t table_offset =get_vce_clock_voltage_limit_table_offset (hwmgr, powerplay_table); +u16 table_size; -if (table_offset >0 ) -return table_offset +get_vce_clock_voltage_limit_table_size (hwmgr, powerplay_table); +if (table_offset >0 ) { + table_size =get_vce_clock_voltage_limit_table_size (hwmgr, powerplay_table); +if (table_size) +return table_offset + table_size; + }return 0 ; }
@@ -143,8 +191,12 @@ static const ATOM_PPLIB_VCE_State_Table *get_vce_state_table( {uint16_t table_offset =get_vce_state_table_offset (hwmgr, powerplay_table); -if (table_offset >0 ) -return (const ATOM_PPLIB_VCE_State_Table *)(((unsigned long ) powerplay_table) + table_offset); +if (table_offset >0 ) { +if (pp_table_has_space (hwmgr, table_offset, +sizeof (((ATOM_PPLIB_VCE_State_Table *)0 )->numEntries))) +return (const ATOM_PPLIB_VCE_State_Table *) + (((unsigned long )powerplay_table) + table_offset); + }return NULL ; }
@@ -153,21 +205,13 @@ static uint16_t get_uvd_table_offset(struct pp_hwmgr *hwmgr, const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table) {uint16_t uvd_table_offset =0 ; +const ATOM_PPLIB_EXTENDEDHEADER *extended_header; + + extended_header =get_extended_header (hwmgr, powerplay_table, +SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V3 ); +if (extended_header) + uvd_table_offset =le16_to_cpu (extended_header->usUVDTableOffset); -if (le16_to_cpu (powerplay_table->usTableSize) >= -sizeof (ATOM_PPLIB_POWERPLAYTABLE3 )) { -const ATOM_PPLIB_POWERPLAYTABLE3 *powerplay_table3 = - (const ATOM_PPLIB_POWERPLAYTABLE3 *)powerplay_table; -if (powerplay_table3->usExtendendedHeaderOffset >0 ) { -const ATOM_PPLIB_EXTENDEDHEADER *extended_header = - (const ATOM_PPLIB_EXTENDEDHEADER *) - (((unsigned long )powerplay_table3) + -le16_to_cpu (powerplay_table3->usExtendendedHeaderOffset)); -if (le16_to_cpu (extended_header->usSize) >= -SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V3 ) - uvd_table_offset =le16_to_cpu (extended_header->usUVDTableOffset); - } - }return uvd_table_offset; }
@@ -193,8 +237,14 @@ static uint16_t get_uvd_clock_info_array_size(struct pp_hwmgr *hwmgr,const UVDClockInfoArray *p = (const UVDClockInfoArray *) (((unsigned long ) powerplay_table) + table_offset); - table_size =sizeof (UCHAR ) + - p->ucNumEntries *sizeof (UVDClockInfo); +size_t size; + +if (!pp_table_has_space (hwmgr, table_offset,sizeof (p->ucNumEntries))) +return 0 ; + + size =sizeof (UCHAR ) + p->ucNumEntries *sizeof (UVDClockInfo); +if (pp_table_has_space (hwmgr, table_offset, size)) + table_size = size; }return table_size;
@@ -206,10 +256,13 @@ static uint16_t get_uvd_clock_voltage_limit_table_offset( {uint16_t table_offset =get_uvd_clock_info_array_offset (hwmgr, powerplay_table); +u16 table_size; -if (table_offset >0 ) -return table_offset + -get_uvd_clock_info_array_size (hwmgr, powerplay_table); +if (table_offset >0 ) { + table_size =get_uvd_clock_info_array_size (hwmgr, powerplay_table); +if (table_size) +return table_offset + table_size; + }return 0 ; }
@@ -218,21 +271,12 @@ static uint16_t get_samu_table_offset(struct pp_hwmgr *hwmgr, const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table) {uint16_t samu_table_offset =0 ; +const ATOM_PPLIB_EXTENDEDHEADER *extended_header; -if (le16_to_cpu (powerplay_table->usTableSize) >= -sizeof (ATOM_PPLIB_POWERPLAYTABLE3 )) { -const ATOM_PPLIB_POWERPLAYTABLE3 *powerplay_table3 = - (const ATOM_PPLIB_POWERPLAYTABLE3 *)powerplay_table; -if (powerplay_table3->usExtendendedHeaderOffset >0 ) { -const ATOM_PPLIB_EXTENDEDHEADER *extended_header = - (const ATOM_PPLIB_EXTENDEDHEADER *) - (((unsigned long )powerplay_table3) + -le16_to_cpu (powerplay_table3->usExtendendedHeaderOffset)); -if (le16_to_cpu (extended_header->usSize) >= -SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V4 ) - samu_table_offset =le16_to_cpu (extended_header->usSAMUTableOffset); - } - } + extended_header =get_extended_header (hwmgr, powerplay_table, +SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V4 ); +if (extended_header) + samu_table_offset =le16_to_cpu (extended_header->usSAMUTableOffset);return samu_table_offset; }
@@ -254,21 +298,12 @@ static uint16_t get_acp_table_offset(struct pp_hwmgr *hwmgr, const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table) {uint16_t acp_table_offset =0 ; +const ATOM_PPLIB_EXTENDEDHEADER *extended_header; -if (le16_to_cpu (powerplay_table->usTableSize) >= -sizeof (ATOM_PPLIB_POWERPLAYTABLE3 )) { -const ATOM_PPLIB_POWERPLAYTABLE3 *powerplay_table3 = - (const ATOM_PPLIB_POWERPLAYTABLE3 *)powerplay_table; -if (powerplay_table3->usExtendendedHeaderOffset >0 ) { -const ATOM_PPLIB_EXTENDEDHEADER *pExtendedHeader = - (const ATOM_PPLIB_EXTENDEDHEADER *) - (((unsigned long )powerplay_table3) + -le16_to_cpu (powerplay_table3->usExtendendedHeaderOffset)); -if (le16_to_cpu (pExtendedHeader->usSize) >= -SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V6 ) - acp_table_offset =le16_to_cpu (pExtendedHeader->usACPTableOffset); - } - } + extended_header =get_extended_header (hwmgr, powerplay_table, +SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V6 ); +if (extended_header) + acp_table_offset =le16_to_cpu (extended_header->usACPTableOffset);return acp_table_offset; }
@@ -290,21 +325,12 @@ static uint16_t get_cacp_tdp_table_offset( const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table) {uint16_t cacTdpTableOffset =0 ; +const ATOM_PPLIB_EXTENDEDHEADER *extended_header; -if (le16_to_cpu (powerplay_table->usTableSize) >= -sizeof (ATOM_PPLIB_POWERPLAYTABLE3 )) { -const ATOM_PPLIB_POWERPLAYTABLE3 *powerplay_table3 = - (const ATOM_PPLIB_POWERPLAYTABLE3 *)powerplay_table; -if (powerplay_table3->usExtendendedHeaderOffset >0 ) { -const ATOM_PPLIB_EXTENDEDHEADER *pExtendedHeader = - (const ATOM_PPLIB_EXTENDEDHEADER *) - (((unsigned long )powerplay_table3) + -le16_to_cpu (powerplay_table3->usExtendendedHeaderOffset)); -if (le16_to_cpu (pExtendedHeader->usSize) >= -SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V7 ) - cacTdpTableOffset =le16_to_cpu (pExtendedHeader->usPowerTuneTableOffset); - } - } + extended_header =get_extended_header (hwmgr, powerplay_table, +SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V7 ); +if (extended_header) + cacTdpTableOffset =le16_to_cpu (extended_header->usPowerTuneTableOffset);return cacTdpTableOffset; }
@@ -341,22 +367,13 @@ static uint16_t get_sclk_vdd_gfx_table_offset(struct pp_hwmgr *hwmgr, const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table) {uint16_t sclk_vdd_gfx_table_offset =0 ; +const ATOM_PPLIB_EXTENDEDHEADER *extended_header; -if (le16_to_cpu (powerplay_table->usTableSize) >= -sizeof (ATOM_PPLIB_POWERPLAYTABLE3 )) { -const ATOM_PPLIB_POWERPLAYTABLE3 *powerplay_table3 = - (const ATOM_PPLIB_POWERPLAYTABLE3 *)powerplay_table; -if (powerplay_table3->usExtendendedHeaderOffset >0 ) { -const ATOM_PPLIB_EXTENDEDHEADER *pExtendedHeader = - (const ATOM_PPLIB_EXTENDEDHEADER *) - (((unsigned long )powerplay_table3) + -le16_to_cpu (powerplay_table3->usExtendendedHeaderOffset)); -if (le16_to_cpu (pExtendedHeader->usSize) >= -SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V8 ) - sclk_vdd_gfx_table_offset = -le16_to_cpu (pExtendedHeader->usSclkVddgfxTableOffset); - } - } + extended_header =get_extended_header (hwmgr, powerplay_table, +SIZE_OF_ATOM_PPLIB_EXTENDEDHEADER_V8 ); +if (extended_header) + sclk_vdd_gfx_table_offset = +le16_to_cpu (extended_header->usSclkVddgfxTableOffset);return sclk_vdd_gfx_table_offset; }
@@ -770,20 +787,37 @@ static ULONG size_of_entry_v2(ULONG num_dpm_levels) }static const ATOM_PPLIB_STATE_V2 *get_state_entry_v2 ( +struct pp_hwmgr *hwmgr,const StateArray * pstate_arrays, +u16 state_array_offset,ULONG entry_index) {ULONG i;const ATOM_PPLIB_STATE_V2 *pstate; +size_t entry_offset; +size_t entry_size; + +if (entry_index >= pstate_arrays->ucNumEntries) +return NULL ; + entry_offset = state_array_offset +sizeof (pstate_arrays->ucNumEntries); pstate = pstate_arrays->states; -if (entry_index <= pstate_arrays->ucNumEntries) { -for (i =0 ; i < entry_index; i++) - pstate = (ATOM_PPLIB_STATE_V2 *)( - (unsigned long )pstate + -size_of_entry_v2 (pstate->ucNumDPMLevels)); +for (i =0 ; i <= entry_index; i++) { +if (!pp_table_has_space (hwmgr, entry_offset,sizeof (*pstate))) +return NULL ; + + entry_size =size_of_entry_v2 (pstate->ucNumDPMLevels); +if (!pp_table_has_space (hwmgr, entry_offset, entry_size)) +return NULL ; + +if (i == entry_index) +return pstate; + + entry_offset += entry_size; + pstate = (ATOM_PPLIB_STATE_V2 *)((unsigned long )pstate + entry_size); } -return pstate; + +return NULL ; }static const unsigned char soft_dummy_pp_table[] = {
@@ -851,6 +885,8 @@ int pp_tables_get_response_times(struct pp_hwmgr *hwmgr,PP_ASSERT_WITH_CODE (NULL != powerplay_tab,"Missing PowerPlay Table!" , return -EINVAL ); +PP_ASSERT_WITH_CODE (pp_table_has_space (hwmgr,0 ,sizeof (*powerplay_tab)), +"Invalid PowerPlay Table!" , return -EINVAL ); *vol_rep_time = (uint32_t )le16_to_cpu (powerplay_tab->usVoltageTime); *bb_rep_time = (uint32_t )le16_to_cpu (powerplay_tab->usBackbiasTime);
@@ -863,13 +899,21 @@ int pp_tables_get_num_of_entries(struct pp_hwmgr *hwmgr, {const StateArray *pstate_arrays;const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table =get_powerplay_table (hwmgr); +u16 state_array_offset;if (powerplay_table ==NULL )return -1 ; +if (!pp_table_has_space (hwmgr,0 ,sizeof (*powerplay_table))) +return -1 ;if (powerplay_table->sHeader.ucTableFormatRevision >=6 ) { + state_array_offset =le16_to_cpu (powerplay_table->usStateArrayOffset); +if (!pp_table_has_space (hwmgr, state_array_offset, +sizeof (pstate_arrays->ucNumEntries))) +return -1 ; + pstate_arrays = (StateArray *)(((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usStateArrayOffset)); + state_array_offset); *num_of_entries = (unsigned long )(pstate_arrays->ucNumEntries); }else
@@ -896,49 +940,128 @@ int pp_tables_get_entry(struct pp_hwmgr *hwmgr,const NonClockInfoArray *pnon_clock_arrays;const ATOM_PPLIB_STATE *pstate_entry; +u16 state_array_offset; +u16 clock_info_array_offset; +u16 non_clock_info_array_offset; +size_t clock_info_offset; +size_t non_clock_info_offset; +size_t state_entry_offset;if (powerplay_table ==NULL )return -1 ; +if (!pp_table_has_space (hwmgr,0 ,sizeof (*powerplay_table))) +return -1 ; ps->classification.bios_index = entry_index;if (powerplay_table->sHeader.ucTableFormatRevision >=6 ) { + state_array_offset =le16_to_cpu (powerplay_table->usStateArrayOffset); +if (!pp_table_has_space (hwmgr, state_array_offset, +sizeof (pstate_arrays->ucNumEntries))) +return -1 ; + pstate_arrays = (StateArray *)(((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usStateArrayOffset)); + state_array_offset); + +if (entry_index >= pstate_arrays->ucNumEntries) +return -1 ; -if (entry_index > pstate_arrays->ucNumEntries) + pstate_entry_v2 =get_state_entry_v2 (hwmgr, pstate_arrays, + state_array_offset, + entry_index); +if (!pstate_entry_v2) +return -1 ; + + clock_info_array_offset = +le16_to_cpu (powerplay_table->usClockInfoArrayOffset); +if (!pp_table_has_space (hwmgr, clock_info_array_offset, +sizeof (*pclock_arrays)))return -1 ; - pstate_entry_v2 =get_state_entry_v2 (pstate_arrays, entry_index); pclock_arrays = (ClockInfoArray *)(((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usClockInfoArrayOffset)); + clock_info_array_offset); +if (!pclock_arrays->ucEntrySize) +return -1 ; + + non_clock_info_array_offset = +le16_to_cpu (powerplay_table->usNonClockInfoArrayOffset); +if (!pp_table_has_space (hwmgr, non_clock_info_array_offset, +sizeof (*pnon_clock_arrays))) +return -1 ; pnon_clock_arrays = (NonClockInfoArray *)(((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usNonClockInfoArrayOffset)); + non_clock_info_array_offset); +if (!pnon_clock_arrays->ucEntrySize || + pnon_clock_arrays->ucEntrySize <ATOM_PPLIB_NONCLOCKINFO_VER1 || + (pnon_clock_arrays->ucEntrySize >ATOM_PPLIB_NONCLOCKINFO_VER1 && + pnon_clock_arrays->ucEntrySize <ATOM_PPLIB_NONCLOCKINFO_VER2 ) || + pstate_entry_v2->nonClockInfoIndex >= pnon_clock_arrays->ucNumEntries) +return -1 ; + non_clock_info_offset = non_clock_info_array_offset + + offsetof(NonClockInfoArray , nonClockInfo) + + pstate_entry_v2->nonClockInfoIndex * pnon_clock_arrays->ucEntrySize; +if (!pp_table_has_space (hwmgr, non_clock_info_offset, + pnon_clock_arrays->ucEntrySize)) +return -1 ; pnon_clock_info = (ATOM_PPLIB_NONCLOCK_INFO *)((unsigned long )(pnon_clock_arrays->nonClockInfo) + (pstate_entry_v2->nonClockInfoIndex * pnon_clock_arrays->ucEntrySize)); result =init_non_clock_fields (hwmgr, ps, pnon_clock_arrays->ucEntrySize, pnon_clock_info);for (i =0 ; i < pstate_entry_v2->ucNumDPMLevels; i++) { -const void *pclock_info = (const void *)( - (unsigned long )(pclock_arrays->clockInfo) + - (pstate_entry_v2->clockInfoIndex[i] * pclock_arrays->ucEntrySize)); +const void *pclock_info; + +if (pstate_entry_v2->clockInfoIndex[i] >= + pclock_arrays->ucNumEntries) +return -1 ; + + clock_info_offset = clock_info_array_offset + + offsetof(ClockInfoArray , clockInfo) + + pstate_entry_v2->clockInfoIndex[i] * pclock_arrays->ucEntrySize; +if (!pp_table_has_space (hwmgr, clock_info_offset, + pclock_arrays->ucEntrySize)) +return -1 ; + + pclock_info = (const void *) + ((unsigned long )(pclock_arrays->clockInfo) + + (pstate_entry_v2->clockInfoIndex[i] * + pclock_arrays->ucEntrySize)); res =func (hwmgr, &ps->hardware, i, pclock_info);if ((0 == result) && (0 != res)) result = res; } }else { -if (entry_index > powerplay_table->ucNumStates) +if (entry_index >= powerplay_table->ucNumStates || + !powerplay_table->ucStateEntrySize || + !powerplay_table->ucNonClockSize || + powerplay_table->ucNonClockSize <ATOM_PPLIB_NONCLOCKINFO_VER1 || + (powerplay_table->ucNonClockSize >ATOM_PPLIB_NONCLOCKINFO_VER1 && + powerplay_table->ucNonClockSize <ATOM_PPLIB_NONCLOCKINFO_VER2 ) || + !powerplay_table->ucClockInfoSize) +return -1 ; + + state_array_offset =le16_to_cpu (powerplay_table->usStateArrayOffset); + state_entry_offset = state_array_offset + + entry_index * powerplay_table->ucStateEntrySize; +if (!pp_table_has_space (hwmgr, state_entry_offset, + powerplay_table->ucStateEntrySize))return -1 ; pstate_entry = (ATOM_PPLIB_STATE *)((unsigned long )powerplay_table + -le16_to_cpu (powerplay_table->usStateArrayOffset) + + state_array_offset + entry_index * powerplay_table->ucStateEntrySize); + non_clock_info_array_offset = +le16_to_cpu (powerplay_table->usNonClockInfoArrayOffset); + non_clock_info_offset = non_clock_info_array_offset + + pstate_entry->ucNonClockStateIndex * powerplay_table->ucNonClockSize; +if (!pp_table_has_space (hwmgr, non_clock_info_offset, + powerplay_table->ucNonClockSize)) +return -1 ; + pnon_clock_info = (ATOM_PPLIB_NONCLOCK_INFO *)((unsigned long )powerplay_table + -le16_to_cpu (powerplay_table->usNonClockInfoArrayOffset) + + non_clock_info_array_offset + pstate_entry->ucNonClockStateIndex * powerplay_table->ucNonClockSize);
@@ -947,12 +1070,23 @@ int pp_tables_get_entry(struct pp_hwmgr *hwmgr, pnon_clock_info);for (i =0 ; i < powerplay_table->ucStateEntrySize-1 ; i++) { -const void *pclock_info = (const void *)((unsigned long )powerplay_table + -le16_to_cpu (powerplay_table->usClockInfoArrayOffset) + +const void *pclock_info; + + clock_info_array_offset = +le16_to_cpu (powerplay_table->usClockInfoArrayOffset); + clock_info_offset = clock_info_array_offset + + pstate_entry->ucClockStateIndices[i] * + powerplay_table->ucClockInfoSize; +if (!pp_table_has_space (hwmgr, clock_info_offset, + powerplay_table->ucClockInfoSize)) +return -1 ; + + pclock_info = (const void *)((unsigned long )powerplay_table + + clock_info_array_offset + pstate_entry->ucClockStateIndices[i] * powerplay_table->ucClockInfoSize); -int res =func (hwmgr, &ps->hardware, i, pclock_info); + res =func (hwmgr, &ps->hardware, i, pclock_info);if ((0 == result) && (0 != res)) result = res;
@@ -1667,21 +1801,70 @@ static int get_vce_state_table_entry(struct pp_hwmgr *hwmgr, unsigned long *flag) {const ATOM_PPLIB_POWERPLAYTABLE *powerplay_table =get_powerplay_table (hwmgr); +const ATOM_PPLIB_VCE_State_Table *vce_state_table; +const ATOM_PPLIB_VCE_State_Record *record; +const VCEClockInfoArray *vce_clock_info_array; +const VCEClockInfo *vce_clock_info; +const ClockInfoArray *clock_arrays; +u16 vce_state_table_offset; +u16 vce_clock_info_array_offset; +u16 clock_info_array_offset; +unsigned long clockInfoIndex; +size_t record_offset; +size_t vce_clock_info_offset; +size_t clock_info_offset; + +if (!powerplay_table || !pp_table_has_space (hwmgr,0 ,sizeof (*powerplay_table))) +return -1 ; -const ATOM_PPLIB_VCE_State_Table *vce_state_table =get_vce_state_table (hwmgr, powerplay_table); + vce_state_table_offset =get_vce_state_table_offset (hwmgr, powerplay_table); + vce_state_table =get_vce_state_table (hwmgr, powerplay_table); +if (!vce_state_table || i >= vce_state_table->numEntries) +return -1 ; + + record_offset = vce_state_table_offset + + offsetof(ATOM_PPLIB_VCE_State_Table , entries) + + i *sizeof (*record); +if (!pp_table_has_space (hwmgr, record_offset,sizeof (*record))) +return -1 ; + + record = &vce_state_table->entries[i]; + + vce_clock_info_array_offset = +get_vce_clock_info_array_offset (hwmgr, powerplay_table); +if (!pp_table_has_space (hwmgr, vce_clock_info_array_offset, +sizeof (vce_clock_info_array->ucNumEntries))) +return -1 ; -unsigned short vce_clock_info_array_offset =get_vce_clock_info_array_offset (hwmgr, powerplay_table); + vce_clock_info_array = (const VCEClockInfoArray *) + (((unsigned long )powerplay_table) + vce_clock_info_array_offset); +if (record->ucVCEClockInfoIndex >= vce_clock_info_array->ucNumEntries) +return -1 ; -const VCEClockInfoArray *vce_clock_info_array = (const VCEClockInfoArray *)(((unsigned long ) powerplay_table) + vce_clock_info_array_offset); + vce_clock_info_offset = vce_clock_info_array_offset + + offsetof(VCEClockInfoArray , entries) + + record->ucVCEClockInfoIndex *sizeof (*vce_clock_info); +if (!pp_table_has_space (hwmgr, vce_clock_info_offset,sizeof (*vce_clock_info))) +return -1 ; -const ClockInfoArray *clock_arrays = (ClockInfoArray *)(((unsigned long )powerplay_table) + -le16_to_cpu (powerplay_table->usClockInfoArrayOffset)); + vce_clock_info = &vce_clock_info_array->entries[record->ucVCEClockInfoIndex]; -const ATOM_PPLIB_VCE_State_Record *record = &vce_state_table->entries[i]; + clock_info_array_offset =le16_to_cpu (powerplay_table->usClockInfoArrayOffset); +if (!pp_table_has_space (hwmgr, clock_info_array_offset, +sizeof (*clock_arrays))) +return -1 ; -const VCEClockInfo *vce_clock_info = &vce_clock_info_array->entries[record->ucVCEClockInfoIndex]; + clock_arrays = (ClockInfoArray *)(((unsigned long )powerplay_table) + + clock_info_array_offset); + clockInfoIndex = record->ucClockInfoIndex &0x3F ; +if (!clock_arrays->ucEntrySize || clockInfoIndex >= clock_arrays->ucNumEntries) +return -1 ; -unsigned long clockInfoIndex = record->ucClockInfoIndex &0x3F ; + clock_info_offset = clock_info_array_offset + + offsetof(ClockInfoArray , clockInfo) + + clockInfoIndex * clock_arrays->ucEntrySize; +if (!pp_table_has_space (hwmgr, clock_info_offset, clock_arrays->ucEntrySize)) +return -1 ; *flag = (record->ucClockInfoIndex >>NUM_BITS_CLOCK_INFO_ARRAY_INDEX );
@@ -1705,6 +1888,10 @@ static int pp_tables_initialize(struct pp_hwmgr *hwmgr) hwmgr->need_pp_table_upload = true; powerplay_table =get_powerplay_table (hwmgr); +PP_ASSERT_WITH_CODE ((powerplay_table), +"Missing PowerPlay Table!" , return -1 ); +PP_ASSERT_WITH_CODE (pp_table_has_space (hwmgr,0 ,sizeof (*powerplay_table)), +"Invalid PowerPlay Table!" , return -1 ); result =init_powerplay_tables (hwmgr, powerplay_table);
@@ -1807,4 +1994,3 @@ const struct pp_table_func pptable_funcs = { .pptable_get_vce_state_table_entry = get_vce_state_table_entry, }; -
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 39/1536 regmap: maple: Workaround for another false-positive compiler warning
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Uwe Kleine-König (The Capable Hub) <[email protected]>
[ Upstream commit dffd32eb2b0e714a8ae23f98518ad7152cb06369 ]
Similar to the issue fixed in commit 542440fd7b30 ("regmap: maple: work around gcc-14.1 false-positive warning"), I see an uninitialized warning for upper_index and upper_last.
Happens with arc-linux-gnu-gcc (Debian 15.3.0-1) 15.3.0 on an allmodconfig for ARCH=arc.
--- drivers/base/regmap/regcache-maple.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/base/regmap/regcache-maple.c +1 -1
@@ -113,7 +113,7 @@ static int regcache_maple_drop(struct regmap *map, unsigned int min,unsigned long *entry, *lower, *upper;/* initialized to work around false-positive -Wuninitialized warning */ unsigned long lower_index =0 , lower_last =0 ; -unsigned long upper_index, upper_last; +unsigned long upper_index =0 , upper_last =0 ;int ret =0 ; lower =NULL ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 66/1536 drm/amdkfd: add sanity check in svm_range_is_valid
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Eric Huang <[email protected]>
[ Upstream commit aa7e29cf9a37092cf5057a612ee09f28df20258f ]
to prevent svm range to be overflow or underflow.
--- drivers/gpu/drm/amd/amdkfd/kfd_svm.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdkfd/kfd_svm.c +7 -1
@@ -3409,7 +3409,13 @@ svm_range_is_valid(struct kfd_process *p, uint64_t start, uint64_t size)unsigned long start_unchg = start; start <<=PAGE_SHIFT ; - end = start + (size <<PAGE_SHIFT ); + +if (size ==0 ) +return -EINVAL ; + +if (check_add_overflow (start, size <<PAGE_SHIFT , &end)) +return -EOVERFLOW ; + do { vma = vma_lookup(p->mm, start); if (!vma || (vma->vm_flags & device_vma))
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 67/1536 drm/panel-edp: Support MB116AS013 edp panel
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Haikun Zhou <[email protected]>
[ Upstream commit 844e71ba7d7a50c5ffa29d147afaeaafb19b39e4 ]
MB116AS01'3 raw edid:
00 ff ff ff ff ff ff 00 21 63 03 12 00 00 00 00 00 23 01 04 95 1a 0e 78 23 e7 05 9c 5b 56 93 27 21 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 36 1c 56 92 50 00 1c 30 60 18 a8 00 00 90 10 00 00 18 00 00 00 fd 00 28 3c 30 30 07 01 0a 20 20 20 20 20 20 00 00 00 fe 00 48 4b 43 20 4d 59 20 20 20 20 0a 20 20 00 00 00 fe 00 4d 42 31 31 36 41 53 30 31 27 33 20 20 01 cb
70 20 79 02 00 22 00 14 1c 1a 01 84 55 05 91 00 5f 00 17 00 ff 02 1b 00 09 00 07 00 2b 00 06 27 00 28 3b 00 00 81 00 13 72 1a 00 00 03 01 28 3c 00 00 00 00 00 00 3c 00 00 00 00 25 01 09 1c 1a 01 1c 1a 01 28 3c 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 e7 90
--- drivers/gpu/drm/panel/panel-edp.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/panel/panel-edp.c +1 -0
@@ -1957,6 +1957,7 @@ static const struct edp_panel_entry edp_panels[] = {EDP_PANEL_ENTRY ('C' ,'S' ,'W' ,0x1100 , &delay_200_500_e80_d50,"MNB601LS1-1" ),EDP_PANEL_ENTRY ('C' ,'S' ,'W' ,0x1104 , &delay_200_500_e50,"MNB601LS1-4" ), +EDP_PANEL_ENTRY ('H' ,'K' ,'C' ,0x1203 , &delay_200_500_e80,"MB116AS01'3" ),EDP_PANEL_ENTRY ('H' ,'K' ,'C' ,0x2d51 , &delay_200_500_e200,"Unknown" ),EDP_PANEL_ENTRY ('H' ,'K' ,'C' ,0x2d5b , &delay_200_500_e200,"MB116AN01" ), EDP_PANEL_ENTRY('H', 'K', 'C', 0x2d5c, &delay_200_500_e200, "MB116AN01-2"),
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 68/1536 libbpf: Skip bpf_object__probe_loading() when BPF token is in use
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yuan Chen <[email protected]>
[ Upstream commit d262a25d8b58b697b2a1a2fe4b0078446cc00e11 ]
bpf_object__probe_loading() tries to load trivial SOCKET_FILTER and TRACEPOINT programs to verify the BPF environment works. When a BPF token is in use with restricted program type permissions, these probe loads may fail because the token does not allow the specific program types, even though BPF loading is perfectly functional.
Fix by skipping the probe when a token FD is present: BPF token creation itself proves the kernel has a working BPF subsystem. Real BPF issues will be caught during actual program and map loading.
--- tools/lib/bpf/libbpf.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-)
tools/lib/bpf/libbpf.c +3 -7
@@ -4993,12 +4993,8 @@ bpf_object__probe_loading(struct bpf_object *obj) BPF_EXIT_INSN(), };int ret, insn_cnt =ARRAY_SIZE (insns); -LIBBPF_OPTS (bpf_prog_load_opts, opts, - .token_fd = obj->token_fd, - .prog_flags = obj->token_fd ? BPF_F_TOKEN_FD : 0, - ); -if (obj->gen_loader) +if (obj->gen_loader || obj->token_fd)return 0 ; ret =bump_rlimit_memlock ();
@@ -5006,9 +5002,9 @@ bpf_object__probe_loading(struct bpf_object *obj)pr_warn ("Failed to bump RLIMIT_MEMLOCK (err = %d), you might need to do it explicitly!\n" , ret);/* make sure basic loading works */ - ret =bpf_prog_load (BPF_PROG_TYPE_SOCKET_FILTER ,NULL ,"GPL" , insns, insn_cnt, &opts); + ret =bpf_prog_load (BPF_PROG_TYPE_SOCKET_FILTER ,NULL ,"GPL" , insns, insn_cnt,NULL );if (ret <0 ) - ret =bpf_prog_load (BPF_PROG_TYPE_TRACEPOINT ,NULL ,"GPL" , insns, insn_cnt, &opts); + ret =bpf_prog_load (BPF_PROG_TYPE_TRACEPOINT ,NULL ,"GPL" , insns, insn_cnt,NULL );if (ret <0 ) { ret = errno; cp =libbpf_strerror_r (ret, errmsg,sizeof (errmsg));
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 69/1536 net: usb: rtl8150: handle link status read failures
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yousef Alhouseen <[email protected]>
[ Upstream commit 8c9c5b9a689612dcb92a04a4218c975cd19f19d8 ]
set_carrier() ignores the result of the USB control transfer and tests the stack variable supplied as its receive buffer. If the device rejects or aborts the request, that variable remains uninitialized and the driver chooses an arbitrary carrier state.
Leave the existing carrier state unchanged when the link status cannot be read. A transient USB error should not be treated as link loss.
--- drivers/net/usb/rtl8150.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/net/usb/rtl8150.c +3 -1
@@ -734,7 +734,9 @@ static void set_carrier(struct net_device *netdev)rtl8150_t *dev =netdev_priv (netdev);short tmp; -get_registers (dev,CSCR ,2 , &tmp); +if (get_registers (dev,CSCR ,2 , &tmp)) +return ; +if (tmp &CSCR_LINK_STATUS )netif_carrier_on (netdev);else
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 70/1536 netfilter: ebtables: bound num_counters like nentries in do_replace()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jiayuan Chen <[email protected]>
[ Upstream commit 43ae85af154b27f9a0ff602f7a01e3a7583ffdab ]
do_replace_finish() allocates the counter buffer before it is validated:
counterstmp = vmalloc_array(repl->num_counters, sizeof(*counterstmp));
do_replace() only checks num_counters against INT_MAX / sizeof(struct ebt_counter), so vmalloc_array() can be asked for up to 134217726 * 16 = 2147483616 bytes (~2 GiB).
num_counters must in fact equal nentries: do_replace_finish() later rejects the request when repl->num_counters != t->private->nentries. get_counters() folds the per-CPU counters back into one entry per rule, so what userspace gets is bounded by nentries, never by nentries * nr_cpus. Apply the same upper bound used for nentries (MAX_EBT_ENTRIES) to the incoming num_counters so the over-sized allocation can no longer be requested.
The allocation is still kept outside the ebt_mutex, since vmalloc() may sleep and trigger reclaim; only the bound is tightened.
--- net/bridge/netfilter/ebtables.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
net/bridge/netfilter/ebtables.c +6 -6
@@ -39,6 +39,8 @@#define COUNTER_OFFSET (n) (SMP_ALIGN(n * sizeof(struct ebt_counter)))#define COUNTER_BASE (c, n, cpu) ((struct ebt_counter *)(((char *)c) + \ COUNTER_OFFSET(n) * cpu)) +#define MAX_EBT_ENTRIES (((INT_MAX - sizeof(struct ebt_table_info)) / \ + NR_CPUS - SMP_CACHE_BYTES) / sizeof(struct ebt_counter))struct ebt_pernet {struct list_head tables;
@@ -1126,10 +1128,9 @@ static int do_replace(struct net *net, sockptr_t arg, unsigned int len)return -EINVAL ;/* overflow check */ -if (tmp.nentries >= ((INT_MAX -sizeof (struct ebt_table_info )) / -NR_CPUS -SMP_CACHE_BYTES ) /sizeof (struct ebt_counter )) +if (tmp.nentries >=MAX_EBT_ENTRIES )return -ENOMEM ; -if (tmp.num_counters >=INT_MAX /sizeof (struct ebt_counter )) +if (tmp.num_counters >=MAX_EBT_ENTRIES )return -ENOMEM ; tmp.name[sizeof (tmp.name) -1 ] =0 ;
@@ -2269,10 +2270,9 @@ static int compat_copy_ebt_replace_from_user(struct ebt_replace *repl,if (tmp.entries_size ==0 )return -EINVAL ; -if (tmp.nentries >= ((INT_MAX -sizeof (struct ebt_table_info )) / -NR_CPUS -SMP_CACHE_BYTES ) /sizeof (struct ebt_counter )) +if (tmp.nentries >=MAX_EBT_ENTRIES )return -ENOMEM ; -if (tmp.num_counters >=INT_MAX /sizeof (struct ebt_counter )) +if (tmp.num_counters >=MAX_EBT_ENTRIES )return -ENOMEM ;memcpy (repl, &tmp, offsetof(struct ebt_replace , hook_entry));
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 71/1536 soundwire: dmi-quirks: Disable ghost Realtek on Asus Expertbook
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Charles Keepax <[email protected]>
[ Upstream commit 90af3209742db61a7f9d7d054a16165818cfc6d8 ]
The Asus Expertbook B9406CAA also has a Realtek device in the ACPI that doesn't exist in the physical hardware. This confuses the machine driver into attempting to create DAI links for the device. Add a quirk to remove this device.
--- drivers/soundwire/dmi-quirks.c | 7 +++++++ 1 file changed, 7 insertions(+)
drivers/soundwire/dmi-quirks.c +7 -0
@@ -178,6 +178,13 @@ static const struct dmi_system_id adr_remap_quirk_table[] = { .driver_data = (void *)hp_omen_16, },/* PTL devices */ + { + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"ASUS" ), + DMI_MATCH(DMI_BOARD_NAME, "B9406CAA"), + }, + .driver_data = (void *)ghost_realtek, + }, { .matches = { DMI_MATCH(DMI_SYS_VENDOR, "ASUS"),
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 72/1536 dmaengine: pl330: remove debugfs file on teardown
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 0d3e3376b289cdaff5b3b6c1581999926ff1000f ]
init_pl330_debugfs() creates a debugfs file with struct pl330_dmac as private data. pl330_remove() then unregisters the DMA device and frees the PL330 channel/thread state without removing that file.
Keep the debugfs dentry and remove it before tearing down the DMAC state used by the debugfs show callback.
--- drivers/dma/pl330.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-)
drivers/dma/pl330.c +16 -3
@@ -502,6 +502,7 @@ struct pl330_dmac {struct dma_pl330_chan *peripherals;/* keep at end */ int quirks; +struct dentry *dbgfs;struct reset_control *rstc;struct reset_control *rstc_ocp; };
@@ -2958,14 +2959,24 @@ DEFINE_SHOW_ATTRIBUTE(pl330_debugfs);static inline void init_pl330_debugfs (struct pl330_dmac *pl330) { -debugfs_create_file (dev_name (pl330->ddma.dev), -S_IFREG |0444 ,NULL , pl330, - &pl330_debugfs_fops); + pl330->dbgfs =debugfs_create_file (dev_name (pl330->ddma.dev), +S_IFREG |0444 ,NULL , pl330, + &pl330_debugfs_fops); +} + +static inline void deinit_pl330_debugfs (struct pl330_dmac *pl330) +{ +debugfs_remove (pl330->dbgfs); + pl330->dbgfs =NULL ; }#else static inline void init_pl330_debugfs (struct pl330_dmac *pl330) { } + +static inline void deinit_pl330_debugfs (struct pl330_dmac *pl330) +{ +}#endif /*
@@ -3211,6 +3222,8 @@ static void pl330_remove(struct amba_device *adev)struct dma_pl330_chan *pch, *_p;int i, irq; +deinit_pl330_debugfs (pl330); +pm_runtime_get_noresume (pl330->ddma.dev);if (adev->dev.of_node)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 73/1536 net: mvneta_bm: add suspend/resume support to prevent crash after resume
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yun Zhou <[email protected]>
[ Upstream commit 140be217df577961bea1ca36240439a463026cbd ]
The mvneta driver uses the hardware Buffer Manager (BM) for RX buffer allocation. During suspend, mvneta disables its clock, causing BM to lose all buffer address state. On resume, mvneta_bm_port_init() re- attaches the BM pool to the NIC, but BM hardware returns stale/garbage buffer addresses. When NAPI poll processes these buffers, DMA cache sync hits an invalid virtual address causing a kernel panic:
Unable to handle kernel paging request at virtual address b0000080 PC is at v7_dma_inv_range Call trace: v7_dma_inv_range from arch_sync_dma_for_cpu+0x94/0x158 arch_sync_dma_for_cpu from __dma_sync_single_for_cpu+0xc4/0x15c __dma_sync_single_for_cpu from mvneta_rx_swbm+0x6c8/0xf48 mvneta_rx_swbm from mvneta_poll+0x6fc/0x70c mvneta_poll from __napi_poll.constprop.0+0x2c/0x1e0 __napi_poll.constprop.0 from net_rx_action+0x160/0x2c4 net_rx_action from handle_softirqs+0xd8/0x2b8 handle_softirqs from run_ksoftirqd+0x30/0x94 run_ksoftirqd from smpboot_thread_fn+0x100/0x204 smpboot_thread_fn from kthread+0xf4/0x110 kthread from ret_from_fork+0x14/0x28
Fix by adding suspend/resume callbacks to the BM driver:
- suspend: drain all buffers (with DMA unmapping), free the BPPE regions, and reset pool state to FREE before stopping BM and gating the clock.
- resume: enable the clock, reinitialize BM defaults, and restore pool read/write pointers and size registers. Pool allocation and buffer refill are handled by mvneta_resume() through the normal mvneta_bm_port_init() path, which sees pools as FREE and performs full initialization identical to probe.
Add a device_link (DL_FLAG_AUTOREMOVE_CONSUMER) in mvneta_probe to guarantee BM resumes before mvneta and suspends after mvneta. If the link cannot be created, fall back to SW buffer management to avoid a potential crash on resume due to unordered PM transitions.
--- drivers/net/ethernet/marvell/mvneta.c | 18 ++++++ drivers/net/ethernet/marvell/mvneta_bm.c | 72 ++++++++++++++++++++++++ 2 files changed, 90 insertions(+)
drivers/net/ethernet/marvell/mvneta.c +18 -0
@@ -5645,6 +5645,24 @@ static int mvneta_probe(struct platform_device *pdev) "use SW buffer management\n");mvneta_bm_put (pp->bm_priv); pp->bm_priv =NULL ; + }else if (!device_link_add (&pdev->dev, + &pp->bm_priv->pdev->dev, +DL_FLAG_AUTOREMOVE_CONSUMER )) { +/* +* Link guarantees BM resumes before mvneta. +* Without it, BM may not be ready when +* mvneta_bm_port_init() runs on resume, +* causing stale buffer addresses and a crash. +* Fall back to SW management to be safe. +*/ +dev_warn (&pdev->dev, +"failed to link to BM, use SW buffer management\n" ); +mvneta_bm_pool_destroy (pp->bm_priv, + pp->pool_long,1 << pp->id); +mvneta_bm_pool_destroy (pp->bm_priv, + pp->pool_short,1 << pp->id); +mvneta_bm_put (pp->bm_priv); + pp->bm_priv =NULL ; } }/* Set RX packet offset correction for platforms, whose
drivers/net/ethernet/marvell/mvneta_bm.c +72 -0
96 lines not on this page · raw message
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 74/1536 dmaengine: dw-axi-dmac: fix __le32 on set of CH_CTL_H_LLI_VALID
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ben Dooks <[email protected]>
[ Upstream commit 89aba9c39bdda8a973a6ffed7c9e93321edcfc16 ]
When writing the lli->ctl_hi, this is an __le32 type so the value being orred should be convered to __le32 by cpu_to_le32.
Fixes 1deb96c0fa58a ("dmaegine: dw-axi-dmac: Support device_prep_dma_cyclic()") --
Note, the call to axi_chan_irq_clear() is passing lli->status_lo through which is also an __le32 but it does not seem to be set anywhere. Is this also a bug?
--- drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c +1 -1
@@ -1128,7 +1128,7 @@ static void axi_chan_block_xfer_complete(struct axi_dma_chan *chan) hw_desc = &desc->hw_desc[i];if (hw_desc->llp == llp) {axi_chan_irq_clear (chan, hw_desc->lli->status_lo); - hw_desc->lli->ctl_hi |=CH_CTL_H_LLI_VALID ; + hw_desc->lli->ctl_hi |=cpu_to_le32 (CH_CTL_H_LLI_VALID ); desc->completed_blocks = i;if (((hw_desc->len * (i +1 )) % desc->period_len) ==0 )
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 75/1536 wifi: rtlwifi: rtl8723be: Remove unnecessary irq save/restore in hw_init()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: William Hansen-Baird <[email protected]>
[ Upstream commit 1b4cd55626b6ffa93d18848412afb912a4add585 ]
rtl8723be hw_init() calls local_save_flags(flags) followed by local_irq_enable(). Later, local_irq_restore(flags) is called.
This causes warnings from Lockdep on boot and modprobe,
as local_irq_restore(flags) should only be called while irqs are disabled. The warning was introduced to detect this class of bug in [1].
With testing I found that all paths which call hw_init() have irqs already enabled for rtl8723be.
Furthermore, the calls were originally added for the rtl8192ce in commit f78bccd79ba3 ("rtlwifi: rtl8192ce: Fix too long disable of IRQs") before later being added to most other rtlwifi drivers.
Commit d3feae41a347 ("rtlwifi: Update power-save routines for 062814 driver") then replaces the call to spin_lock_irqsave() before hw_init(), and thus the codepath which caused irqs to be disabled in hw_init and prompted the original commit has been removed.
The same irq save/restore pattern is also present in the hw_init() of rtl8192ce, rtl8723ae, rtl8188ee, rtl8192se and rtl8192cu, however I don't have the hardware to test them,
so I did not include them in my changes.
Tested on a Razer Blade 14 2017.
Example of output from Lockdep prior to fix:
raw_local_irq_restore() called with IRQs enabled
...
Call Trace: <TASK> rtl8723be_hw_init+0x5992/0x7220 [rtl8723be] ? static_obj+0x61/0xa0 rtl_pci_start+0x222/0x5c0 [rtl_pci] rtl_op_start+0x128/0x1a0 [rtlwifi] ? __kasan_check_read+0x11/0x20 drv_start+0x16c/0x550 [mac80211]
...
irq event stamp: 887679 hardirqs last enabled at (887689): [<ffffffff96511170>] __up_console_sem+0x90/0xa0 hardirqs last disabled at (887698): [<ffffffff96511155>] __up_console_sem+0x75/0xa0 softirqs last enabled at (887670): [<ffffffff962f4675>] __irq_exit_rcu+0x175/0x2f0 softirqs last disabled at (887649): [<ffffffff962f4675>] __irq_exit_rcu+0x175/0x2f0 ---[ end trace 0000000000000000 ]---
[1] https://lore.kernel.org/all/[email protected]/
--- drivers/net/wireless/realtek/rtlwifi/rtl8723be/hw.c | 6 ------ 1 file changed, 6 deletions(-)
drivers/net/wireless/realtek/rtlwifi/rtl8723be/hw.c +0 -6
@@ -1333,11 +1333,6 @@ int rtl8723be_hw_init(struct ieee80211_hw *hw)bool rtstatus = true;int err;u8 tmp_u1b; -unsigned long flags; - -/* reenable interrupts to not interfere with other devices */ -local_save_flags (flags); -local_irq_enable (); rtlhal->fw_ready = false; rtlpriv->rtlhal.being_init_adapter = true;
@@ -1443,7 +1438,6 @@ int rtl8723be_hw_init(struct ieee80211_hw *hw)rtl8723be_dm_init (hw); exit: -local_irq_restore (flags); rtlpriv->rtlhal.being_init_adapter = false;return err; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 40/1536 ARM: OMAP2+: Add CFI type for omap4_finish_suspend
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Mithil Bavishi <[email protected]>
[ Upstream commit 4a7b197ad28d71f9fac873f283b4408df3fdb287 ]
With CONFIG_CFI enabled, OMAP4 can trap in omap4_enter_lowpower() because omap_pm_ops.finish_suspend points directly to the assembly routine omap4_finish_suspend, which lacks the expected KCFI type metadata.
Annotate omap4_finish_suspend with SYM_TYPED_FUNC_START so the assembly routine carries the KCFI type metadata.
--- arch/arm/mach-omap2/sleep44xx.S | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
arch/arm/mach-omap2/sleep44xx.S +3 -2
@@ -6,6 +6,7 @@ * Santosh Shilimkar <[email protected]> */ +#include <linux/cfi_types.h> #include <linux/linkage.h> #include <asm/assembler.h> #include <asm/smp_scu.h>
@@ -58,7 +59,7 @@ * stack frame and it expects the caller to take care of it. Hence the entire * stack frame is saved to avoid possible stack corruption. */ -ENTRY(omap4_finish_suspend) +SYM_TYPED_FUNC_START(omap4_finish_suspend) stmfd sp!, {r4-r12, lr} cmp r0, #0x0 beq do_WFI @ No lowpower state, jump to WFI
@@ -223,7 +224,7 @@ skip_scu_gp_clear: isb dsb ldmfd sp!, {r4-r12, pc} -ENDPROC(omap4_finish_suspend) +SYM_FUNC_END(omap4_finish_suspend) /* * ============================
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 76/1536 wifi: rtw89: wow: only WiFi 6 chips initialize RF registers in WoWLAN mode
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Chih-Kang Chang <[email protected]>
[ Upstream commit dbff9040587e9bd6d3ee337315971957f9f76612 ]
Only the WiFi 6 chips need to initialize RF register when WoWLAN download FW for some power save issue. Applying the same initialization flow to WiFi 7 chips might trigger the error
'RF parameters exceed size. path=1, idx=1500.'.
This happens because normal mode uses rtw89_phy_config_rf_reg_v1(), which skips registers with addresses below 0x100. However, WoWLAN mode uses rtw89_phy_config_rf_reg_noio(), and WiFi 7 chips do not satisfy the rtw89_chip_rf_v1() condition. As a result, more RF registers are configured, causing the size overflow error.
--- drivers/net/wireless/realtek/rtw89/wow.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/net/wireless/realtek/rtw89/wow.c +2 -1
@@ -1249,7 +1249,8 @@ static int rtw89_wow_swap_fw(struct rtw89_dev *rtwdev, bool wow)if (disable_intr_for_dlfw)rtw89_hci_enable_intr (rtwdev); -rtw89_phy_init_rf_reg (rtwdev, true); +if (chip->chip_gen ==RTW89_CHIP_AX ) +rtw89_phy_init_rf_reg (rtwdev, true); ret =rtw89_fw_h2c_role_maintain (rtwdev, rtwvif_link, rtwsta_link,RTW89_ROLE_FW_RESTORE );
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 77/1536 wifi: rtlwifi: fix disabling of ASPM for RTL8723BE with AER flooding
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: William Hansen-Baird <[email protected]>
[ Upstream commit 04a46c2dbf3b516c96a1d19b72917b56055ad6c1 ]
commit 77a6407c6ab2 ("wifi: rtlwifi: disable ASPM for RTL8723BE with subsystem ID 11ad:1723") adds code which sets ppsc->support_aspm to false in _rtl_pci_update_default_setting() in order to disable ASPM.
This does not, however, disable ASPM. Rather, it disables driver
control of ASPM, and blocks calls to rtl_pci_enable_aspm()
and rtl_pci_disable_aspm().
In some cases, the pci device supplied to the probe function has ASPM enabled. The code would therefore not disable ASPM, as it means to, but rather just leave it enabled.
This was discovered through testing on a Razer Blade 14 2017.
Implement a new __rtl_pci_disable_aspm(hw) function which does not check ppsc->support_aspm before disabling and call it from rtl_pci_disable_aspm().
Then move the code added in the previous commit to rtl_pci_init_aspm() to allow adding a call to __rtl_pci_disable_aspm(hw).
This makes sure ASPM is disabled while still disabling
driver control of ASPM to block it from being enabled later.
--- drivers/net/wireless/realtek/rtlwifi/pci.c | 39 ++++++++++++++-------- 1 file changed, 26 insertions(+), 13 deletions(-)
drivers/net/wireless/realtek/rtlwifi/pci.c +26 -13
@@ -156,15 +156,6 @@ static void _rtl_pci_update_default_setting(struct ieee80211_hw *hw) PCI_EXP_LNKCTL_ASPM_L1 | PCI_EXP_LNKCTL_CCC)) ppsc->support_aspm = false; -/* RTL8723BE found on some ASUSTek laptops, such as F441U and -* X555UQ with subsystem ID 11ad:1723 are known to output large -* amounts of PCIe AER errors during and after boot up, causing -* heavy lags, poor network throughput, and occasional lock-ups. -*/ -if (rtlpriv->rtlhal.hw_type ==HARDWARE_TYPE_RTL8723BE && - (rtlpci->pdev->subsystem_vendor ==0x11ad && - rtlpci->pdev->subsystem_device ==0x1723 )) - ppsc->support_aspm = false; } static bool _rtl_pci_platform_switch_device_pci_aspm(
@@ -203,7 +194,7 @@ static void _rtl_pci_switch_clk_req(struct ieee80211_hw *hw, u16 value) }/*Disable RTL8192SE ASPM & Disable Pci Bridge ASPM*/ -static void rtl_pci_disable_aspm (struct ieee80211_hw *hw) +static void __rtl_pci_disable_aspm (struct ieee80211_hw *hw) {struct rtl_priv *rtlpriv =rtl_priv (hw);struct rtl_pci_priv *pcipriv =rtl_pcipriv (hw);
@@ -215,9 +206,6 @@ static void rtl_pci_disable_aspm(struct ieee80211_hw *hw)u16 aspmlevel =0 ;u16 tmp_u1b =0 ; -if (!ppsc->support_aspm) -return ; -if (pcibridge_vendor ==PCI_BRIDGE_VENDOR_UNKNOWN ) {rtl_dbg (rtlpriv,COMP_POWER ,DBG_TRACE ,"PCI(Bridge) UNKNOWN\n" );
@@ -240,6 +228,16 @@ static void rtl_pci_disable_aspm(struct ieee80211_hw *hw)_rtl_pci_platform_switch_device_pci_aspm (hw, linkctrl_reg); } +static void rtl_pci_disable_aspm (struct ieee80211_hw *hw) +{ +struct rtl_ps_ctl *ppsc =rtl_psc (rtl_priv (hw)); + +if (!ppsc->support_aspm) +return ; + +__rtl_pci_disable_aspm (hw); +} +/*Enable RTL8192SE ASPM & Enable Pci Bridge ASPM for *power saving We should follow the sequence to enable *RTL8192SE first then enable Pci Bridge ASPM
@@ -330,10 +328,25 @@ static void rtl_pci_parse_configuration(struct pci_dev *pdev,static void rtl_pci_init_aspm (struct ieee80211_hw *hw) { +struct rtl_pci *rtlpci =rtl_pcidev (rtl_pcipriv (hw));struct rtl_ps_ctl *ppsc =rtl_psc (rtl_priv (hw)); +struct rtl_priv *rtlpriv =rtl_priv (hw);_rtl_pci_update_default_setting (hw); +/* +* RTL8723BE found on some ASUSTek laptops, such as F441U and +* X555UQ with subsystem ID 11ad:1723 are known to output large +* amounts of PCIe AER errors during and after boot up, causing +* heavy lags, poor network throughput, and occasional lock-ups. +*/ +if (rtlpriv->rtlhal.hw_type ==HARDWARE_TYPE_RTL8723BE && + (rtlpci->pdev->subsystem_vendor ==0x11ad && + rtlpci->pdev->subsystem_device ==0x1723 )) { +__rtl_pci_disable_aspm (hw); + ppsc->support_aspm = false; + } +if (ppsc->reg_rfps_level &RT_RF_PS_LEVEL_ALWAYS_ASPM ) {/*Always enable ASPM & Clock Req. */ rtl_pci_enable_aspm (hw);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 41/1536 iio: accel: fxls8962af: clamp the device-reported FIFO sample count
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Bryam Vargas <[email protected]>
[ Upstream commit 2f8225b91eb478ca2e9aec8aaef4d229765bcebe ]
fxls8962af_fifo_flush() transfers the sample count the device reports in BUF_STATUS into an on-stack buffer sized for FXLS8962AF_FIFO_LENGTH (32) samples, but the count is a 6-bit field (0..63) that is only checked for zero. A device, or an attacker on the I2C/SPI bus, reporting 33..63 overflows the buffer by up to 186 bytes: a stack out-of-bounds write.
Clamp the count to FXLS8962AF_FIFO_LENGTH before the transfer, mirroring the clamp already applied in fxls8962af_set_watermark(). Conforming hardware reports at most that many samples and is unaffected.
--- drivers/iio/accel/fxls8962af-core.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/iio/accel/fxls8962af-core.c +2 -0
@@ -959,6 +959,8 @@ static int fxls8962af_fifo_flush(struct iio_dev *indio_dev)if (!count)return 0 ; + count =min (count,FXLS8962AF_FIFO_LENGTH ); + data->old_timestamp = data->timestamp; data->timestamp =iio_get_time_ns (indio_dev);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 42/1536 perf/x86/intel: Fallback to sw branch type decoding if no hw decoding
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Dapeng Mi <[email protected]>
[ Upstream commit 170cc6b02e3d5203ccaa49ffea1ee5a7ab08c885 ]
intel_pmu_lbr_filter() currently assumes arch-LBR provides hardware branch-type decoding and skips software decoding on that path.
However, arch-LBR may not always expose branch-type information. In that case, treating entries as hardware-decoded can misclassify sampled branches (for example, defaulting to JCC), which breaks branch-type filtering results.
Fix this by using software branch-type decoding when hardware branch-type decoding is unavailable (that is, when x86_lbr_type is not enabled). This keeps branch classification and filtering behavior correct across arch-LBR configurations.
Since x86_lbr_type is only set to true when arch-LBR is supported, it's unnecessary to check if the CPU has the arch-LBR feature.
--- arch/x86/events/intel/lbr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/events/intel/lbr.c +1 -1
@@ -1222,7 +1222,7 @@ intel_pmu_lbr_filter(struct cpu_hw_events *cpuc)* Doesn't support OTHER_BRANCH decoding for now. * OTHER_BRANCH branch type still rely on software decoding. */ -if (static_cpu_has (X86_FEATURE_ARCH_LBR ) && +if (static_branch_likely (&x86_lbr_type) && type <=ARCH_LBR_BR_TYPE_KNOWN_MAX ) { to_plm =kernel_ip (to) ?X86_BR_KERNEL :X86_BR_USER ; type = arch_lbr_br_type_map[type] | to_plm;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 43/1536 fat: reject name longer than NAME_MAX in msdos_format_name()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Zizhi Wo <[email protected]>
[ Upstream commit 9d7ed813ee5ff0d469bd99630828ed6fdef4e8da ]
msdos_format_name() performs no upper-bound check on the input name length. It silently truncates an arbitrarily long name into the 8.3 form (11 bytes) and returns success. The subsequent fat_scan() then matches only against these 11 truncated bytes, so it returns an inode as long as any entry with the same 8.3 name exists on disk.
For example, passing a 300-byte name of all 'A's returns 0 with res set to "AAAAAAAA" (8 'A's + 3 padding spaces), reporting success for a name far longer than NAME_MAX.
As a result, when a user calls open() on a path component longer than NAME_MAX (255) bytes, the VFS only enforces PATH_MAX, not the length of an individual component. The dentry keeps the original long name but gets an inode attached and becomes positive. Later in vfs_open() -> fsnotify_open() -> fanotify_info_copy_name() triggers WARN_ON_ONCE(), and the event is reported to userspace with an empty name.
vfat is not affected, as create goes through xlate_to_uni() which refuses names longer than FAT_LFN_LEN.
Fix this by checking 'len > NAME_MAX' at the entry of msdos_format_name(), the single entry point for all msdos name handling, aligning with the NAME_MAX check that xfs/9p/ceph/simple_lookup() perform at lookup.
--- fs/fat/namei_msdos.c | 3 +++ 1 file changed, 3 insertions(+)
fs/fat/namei_msdos.c +3 -0
@@ -29,6 +29,9 @@ static int msdos_format_name(const unsigned char *name, int len,unsigned char c;int space; +if (len >NAME_MAX ) +return -ENAMETOOLONG ; +if (name[0 ] =='.' ) {/* dotfile because . and .. already done */ if (opts->dotsOK) {/* Get rid of dot - test for it elsewhere */
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 44/1536 perf/x86/intel/uncore: Fix PCI PMU cleanup on setup failure
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Zide Chen <[email protected]>
[ Upstream commit 003267cb94e21d762eb72d6977d84f44f1705bb7 ]
When uncore_pci_pmu_register() fails, pmu->boxes[die] is set to NULL before returning. In the uncore_pci_remove() path, this causes uncore_pci_pmu_unregister() to be skipped entirely, leaking pmu->activeboxes. In the uncore_bus_notify() path, uncore_pci_pmu_unregister() may still be called and must exit early when pmu->boxes[die] is NULL to avoid a NULL pointer dereference, and to ensure activeboxes is only decremented for a previously active box.
Additionally, since pci_get_drvdata() returns NULL on registration failure, uncore_pci_remove() can no longer treat NULL drvdata as an indicator of an auxiliary PCI device. Remove the associated WARN_ON_ONCE().
--- arch/x86/events/intel/uncore.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
arch/x86/events/intel/uncore.c +4 -1
@@ -1179,6 +1179,7 @@ static int uncore_pci_pmu_register(struct pci_dev *pdev,/* First active box registers the pmu */ ret =uncore_pmu_register (pmu);if (ret) { +atomic_dec (&pmu->activeboxes); pmu->boxes[die] =NULL ;uncore_box_exit (box);kfree (box);
@@ -1244,6 +1245,9 @@ static void uncore_pci_pmu_unregister(struct intel_uncore_pmu *pmu, int die) {struct intel_uncore_box *box = pmu->boxes[die]; +if (!box) +return ; + pmu->boxes[die] =NULL ;if (atomic_dec_return (&pmu->activeboxes) ==0 )uncore_pmu_unregister (pmu);
@@ -1268,7 +1272,6 @@ static void uncore_pci_remove(struct pci_dev *pdev)break ; } } -WARN_ON_ONCE (i >=UNCORE_EXTRA_PCI_DEV_MAX );return ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 45/1536 spi: bcm-qspi: return error from failed controller suspend
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jiawen Liu <[email protected]>
[ Upstream commit 44d09ef0ba690ac46d17eb05c12a47a5dd75e231 ]
spi_controller_suspend() can fail if the SPI core cannot stop the controller. bcm_qspi_suspend() ignored that error, disabled the controller clock, uninitialized the hardware, and returned success.
Return the suspend error before tearing down the clock and hardware state.
--- drivers/spi/spi-bcm-qspi.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/spi/spi-bcm-qspi.c +5 -1
@@ -1694,13 +1694,17 @@ EXPORT_SYMBOL_GPL(bcm_qspi_remove);static int __maybe_unused bcm_qspi_suspend (struct device *dev) {struct bcm_qspi *qspi =dev_get_drvdata (dev); +int ret;/* store the override strap value */ if (!bcm_qspi_bspi_ver_three (qspi)) qspi->s3_strap_override_ctrl =bcm_qspi_read (qspi,BSPI ,BSPI_STRAP_OVERRIDE_CTRL ); -spi_controller_suspend (qspi->host); + ret =spi_controller_suspend (qspi->host); +if (ret) +return ret; +clk_disable_unprepare (qspi->clk);bcm_qspi_hw_uninit (qspi);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 36/1536 clk: zynq: handle kasprintf() failure in periph_clk registration
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: William Theesfeld <[email protected]>
[ Upstream commit d4d0d335e8d37c6c7e1c5664c7664288eca5a09b ]
zynq_clk_register_periph_clk() ignores the return value of the two kasprintf() calls used to build the mux and divider clock names, and passes the resulting (possibly NULL) pointers straight into clk_register_mux(), clk_register_divider() and clk_register_gate() as the clock '"'name'"' argument. On allocation failure that name later gets dereferenced by the clock framework (e.g. in debugfs name formatting), causing a NULL-pointer dereference.
Check both kasprintf() returns. On failure unwind any allocated name buffer and the spinlock, then fall through to the existing err label which sets clks[] to ERR_PTR(-ENOMEM). Freeing the spinlock on the error path is correct here because no clk_register_*() call has had a chance to take ownership of it; the success path intentionally hands it off to the registered clocks.
The neighbouring zynq_clk_register_fclk() in the same file already uses this per-allocation goto-label cleanup pattern; this change brings periph_clk into line with it.
--- drivers/clk/zynq/clkc.c | 8 ++++++++ 1 file changed, 8 insertions(+)
drivers/clk/zynq/clkc.c +8 -0
@@ -186,7 +186,11 @@ static void __init zynq_clk_register_periph_clk(enum zynq_clk clk0,spin_lock_init (lock); mux_name =kasprintf (GFP_KERNEL ,"%s_mux" , clk_name0); +if (!mux_name) + goto err_mux_name; div_name =kasprintf (GFP_KERNEL ,"%s_div" , clk_name0); +if (!div_name) + goto err_div_name;clk_register_mux (NULL , mux_name, parents,4 ,CLK_SET_RATE_NO_REPARENT , clk_ctrl,4 ,2 ,0 , lock);
@@ -205,6 +209,10 @@ static void __init zynq_clk_register_periph_clk(enum zynq_clk clk0,return ; +err_div_name: +kfree (mux_name); +err_mux_name: +kfree (lock); err: clks[clk0] =ERR_PTR (-ENOMEM );if (two_gates)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 79/1536 block: reject block device inodes with i_rdev == 0 in lookup_bdev()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Yun Zhou <[email protected]>
[ Upstream commit 83887ad02f30c1814bed5da3ca999f7b0f3f337c ]
lookup_bdev() blindly returns inode->i_rdev without validating it. When a FUSE filesystem exposes a root inode with S_IFBLK mode but i_rdev == 0 (via rootmode=060000), any subsequent mount attempt using that path as a block device source propagates dev_t 0 into the superblock machinery. After commit 9ee5f161a4db ("fs: maintain a global device-to-superblock table") this triggers a WARNING in super_dev_register().
Reject i_rdev == 0 early with -ENODEV since no real block device driver registers major 0.
--- block/bdev.c | 12 ++++++++++++ 1 file changed, 12 insertions(+)
block/bdev.c +12 -0
@@ -1185,6 +1185,18 @@ int lookup_bdev(const char *pathname, dev_t *dev)if (!may_open_dev (&path)) goto out_path_put; +/* +* Reject a block device inode with i_rdev == 0. A dev_t of 0 is +* never valid for a block device: no real block device driver +* registers major 0. Fake block device inodes (e.g. fuse with +* rootmode=S_IFBLK) can expose i_rdev == 0, and letting that +* propagate would confuse superblock lookup and trigger warnings +* in the device-to-superblock table (super_dev_register). +*/ + error = -ENODEV ; +if (!inode->i_rdev) + goto out_path_put; + *dev = inode->i_rdev; error =0 ; out_path_put:
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 88/1536 mmc: dw_mmc: stop and complete DMA also in STATE_DATA_BUSY state
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Marek Szyprowski <[email protected]>
[ Upstream commit cb3fcb8d118b874178251d1f02613f60d25e4ddc ]
When transfer was stopped in STATE_DATA_BUSY state, there was no call to dma_ops->cleanup function, so the DMA mapped buffer was never properly unmapped. Fix this by calling dw_mci_stop_dma() function also in that state to ensure proper cleanup call when DMA transfer was used.
--- drivers/mmc/host/dw_mmc.c | 1 + 1 file changed, 1 insertion(+)
drivers/mmc/host/dw_mmc.c +1 -0
@@ -2214,6 +2214,7 @@ static void dw_mci_work_func(struct work_struct *t) }dw_mci_stop_fault_timer (host); +dw_mci_stop_dma (host); host->data =NULL ;set_bit (EVENT_DATA_COMPLETE , &host->completed_events); err =dw_mci_data_complete (host, data);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 89/1536 clk: sunxi-ng: fix ccu probe clock unregister on error
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Jerome Brunet <[email protected]>
[ Upstream commit 81f4ddc9f7e0c11d3e9d24d0f30023845a02f7ee ]
When registering clocks with sunxi_ccu_probe(), the number of ccu_clocks and the number of hw clocks might be different, eventhough they usually are the same.
If they are different, it could lead to out-of-bound access or registered clock left behind on error.
Use a different variable when iterating on hw clocks so every registered clock, and only those, gets unregistered on error.
--- drivers/clk/sunxi-ng/ccu_common.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
drivers/clk/sunxi-ng/ccu_common.c +6 -6
@@ -114,7 +114,7 @@ static int sunxi_ccu_probe(struct sunxi_ccu *ccu, struct device *dev, const struct sunxi_ccu_desc *desc) {struct ccu_reset *reset; -int i, ret; +int i, j, ret; ccu->desc = desc;
@@ -130,8 +130,8 @@ static int sunxi_ccu_probe(struct sunxi_ccu *ccu, struct device *dev, cclk->lock = &ccu->lock; } -for (i =0 ; i < desc->hw_clks->num ; i++) { -struct clk_hw *hw = desc->hw_clks->hws[i]; +for (j =0 ; j < desc->hw_clks->num ; j++) { +struct clk_hw *hw = desc->hw_clks->hws[j];const char *name;if (!hw)
@@ -143,7 +143,7 @@ static int sunxi_ccu_probe(struct sunxi_ccu *ccu, struct device *dev,else ret =of_clk_hw_register (node, hw);if (ret) { -pr_err ("Couldn't register clock %d - %s\n" , i, name); +pr_err ("Couldn't register clock %d - %s\n" , j, name); goto err_clk_unreg; } }
@@ -186,8 +186,8 @@ static int sunxi_ccu_probe(struct sunxi_ccu *ccu, struct device *dev, err_del_provider:of_clk_del_provider (node); err_clk_unreg: -while (--i >=0 ) { -struct clk_hw *hw = desc->hw_clks->hws[i]; +while (--j >=0 ) { +struct clk_hw *hw = desc->hw_clks->hws[j];if (!hw)continue ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 90/1536 remoteproc: core: Full attach detach during recovery
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Tanmay Shah <[email protected]>
[ Upstream commit d93ffd549fb4df18c934ca7a47d4128a18c718cb ]
Current attach on recovery mechanism loads the clean resource table during recovery, but doesn't re-allocate the resources. RPMsg communication will fail after recovery due to this. Fix this incorrect behavior by doing the full detach and attach of remote processor during the recovery. This will load the clean resource table and re-allocate all the resources, which will set up correct vring information in the resource table.
--- drivers/remoteproc/remoteproc_core.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-)
drivers/remoteproc/remoteproc_core.c +14 -1
@@ -1784,7 +1784,20 @@ static int rproc_attach_recovery(struct rproc *rproc)if (ret)return ret; -return __rproc_attach (rproc); +/* clean up all acquired resources */ +rproc_resource_cleanup (rproc); + +/* release HW resources if needed */ +rproc_unprepare_device (rproc); + +rproc_disable_iommu (rproc); + +/* Free the copy of the resource table */ +kfree (rproc->cached_table); + rproc->cached_table =NULL ; + rproc->table_ptr =NULL ; + +return rproc_attach (rproc); }static int rproc_boot_recovery (struct rproc *rproc)
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 91/1536 nvme: handle positive error codes in nuse_show()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: John Garry <[email protected]>
[ Upstream commit dd516cd7624648c71d338d99368587f10ecc9f0b ]
Function __nvme_submit_sync_cmd() returns a positive error code for NVMe errors. Otherwise, we get 0 for success or a negative error code for a kernel error.
In nuse_show() -> ns_{head}_update_nuse() -> nvme_identify_ns() -> nvme_submit_sync_cmd() -> __nvme_submit_sync_cmd(), we then may get a positive error code returned.
Function nuse_show() - being a device attr handler - should return the number of bytes written to the buffer or a negative error code.
Convert any positive NVMe error code to -EIO.
--- drivers/nvme/host/sysfs.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/nvme/host/sysfs.c +3 -1
@@ -239,8 +239,10 @@ static ssize_t nuse_show(struct device *dev, struct device_attribute *attr, ret =ns_head_update_nuse (head); else ret =ns_update_nuse (disk->private_data); -if (ret) +if (ret <0 )return ret; +else if (ret >0 ) +return -EIO ;return sysfs_emit (buf,"%llu\n" , head->nuse); }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 92/1536 nvme-auth: use crypto_memneq for DH-HMAC-CHAP response comparison
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Xixin Liu <[email protected]>
[ Upstream commit 3a6d89836ab09d53f4c32c57588689a378ce4363 ]
DH-HMAC-CHAP authentication compares HMAC response digests with memcmp(). Standard memcmp() may stop at the first differing byte, which can leak timing information to a remote attacker and allow incremental recovery of the expected digest.
Use crypto_memneq() for constant-time comparison on both the host path that validates the controller Success1 response and the target path that validates the host Reply digest. Other memcmp() uses in the NVMe auth code (e.g. fixed string prefix checks) are not security-sensitive and are left unchanged.
--- drivers/nvme/host/auth.c | 3 ++- drivers/nvme/target/fabrics-cmd-auth.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-)
drivers/nvme/host/auth.c +2 -1
@@ -9,6 +9,7 @@#include <linux/unaligned.h> #include <crypto/hash.h> #include <crypto/dh.h> +#include <crypto/utils.h> #include "nvme.h" #include "fabrics.h" #include <linux/nvme-auth.h>
@@ -365,7 +366,7 @@ static int nvme_auth_process_dhchap_success1(struct nvme_ctrl *ctrl,return 0 ;/* Validate controller response */ -if (memcmp (chap->response, data->rval, data->hl)) { +if (crypto_memneq (chap->response, data->rval, data->hl)) {dev_dbg (ctrl->device,"%s: qid %d ctrl response %*ph\n" , __func__, chap->qid, (int )chap->hash_len, data->rval); dev_dbg(ctrl->device, "%s: qid %d host response %*ph\n",
drivers/nvme/target/fabrics-cmd-auth.c +2 -1
@@ -10,6 +10,7 @@#include <linux/nvme-auth.h> #include <crypto/hash.h> #include <crypto/kpp.h> +#include <crypto/utils.h> #include "nvmet.h" static void nvmet_auth_expired_work (struct work_struct *work)
@@ -162,7 +163,7 @@ static u8 nvmet_auth_reply(struct nvmet_req *req, void *d, u32 tl)return NVME_AUTH_DHCHAP_FAILURE_FAILED ; } -if (memcmp (data->rval, response, data->hl)) { +if (crypto_memneq (data->rval, response, data->hl)) {pr_info ("ctrl %d qid %d host response mismatch\n" , ctrl->cntlid, req->sq->qid);kfree (response);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 93/1536 nvme: zns: cap zone report nr_zones by DMA buffer size
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Xixin Liu <[email protected]>
[ Upstream commit 09c9062d4f62199a634a45e2bb9e6e8e572cc78c ]
With Partial Report (PR=1), the Number of Zones (NZ) field in the report header must equal the number of zone descriptors fully transferred in the DMA buffer (ZNS Command Set Specification Rev 1.2, section 3.4.2).
nvme_ns_report_zones() does not cap the parse loop by max_in_buf derived from buflen. Cap nz with min3() over the device-reported count, nr_zones - zone_idx, and max_in_buf.
--- drivers/nvme/host/zns.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-)
drivers/nvme/host/zns.c +6 -2
@@ -179,7 +179,7 @@ int nvme_ns_report_zones(struct nvme_ns *ns, sector_t sector,struct nvme_zone_report *report;struct nvme_command c = { };int ret, zone_idx =0 ; -unsigned int nz, i; +unsigned int max_in_buf, nz, i;size_t buflen;if (ns->head->ids.csi !=NVME_CSI_ZNS )
@@ -189,6 +189,9 @@ int nvme_ns_report_zones(struct nvme_ns *ns, sector_t sector,if (!report)return -ENOMEM ; + max_in_buf = (buflen -sizeof (struct nvme_zone_report )) / +sizeof (struct nvme_zone_descriptor ); + c.zmr.opcode = nvme_cmd_zone_mgmt_recv; c.zmr.nsid =cpu_to_le32 (ns->head->ns_id); c.zmr.numd =cpu_to_le32 (nvme_bytes_to_numd (buflen));
@@ -208,7 +211,8 @@ int nvme_ns_report_zones(struct nvme_ns *ns, sector_t sector, goto out_free; } - nz =min ((unsigned int )le64_to_cpu (report->nr_zones), nr_zones); + nz =min3 ((unsigned int )le64_to_cpu (report->nr_zones), + nr_zones - zone_idx, max_in_buf);if (!nz)break ;
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 94/1536 staging: rtl8723bs: fix missing unregister_netdev on sdio_alloc_irq failure
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Devansh Soni <[email protected]>
[ Upstream commit 51b554f1a758570159a770983c7a0ccd7c761491 ]
In rtw_drv_init(), if rtw_drv_register_netdev() succeeds but sdio_alloc_irq() fails, the error path jumps to free_if1 and calls rtw_sdio_if1_deinit(). However, rtw_sdio_if1_deinit() calls rtw_free_netdev() without a preceding unregister_netdev(), freeing a still-registered netdev but leaving stale sysfs entries behind.
--- drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/staging/rtl8723bs/os_dep/sdio_intf.c +4 -1
@@ -381,11 +381,14 @@ static int rtw_drv_init( status =sdio_alloc_irq (dvobj);if (status != _SUCCESS) - goto free_if1; + goto free_netdev;rtw_ndev_notifier_register (); status = _SUCCESS; +free_netdev: +if (status != _SUCCESS) +rtw_unregister_netdevs (dvobj); free_if1:if (status != _SUCCESS && if1)rtw_sdio_if1_deinit (if1);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 95/1536 udf: validate extent partition references in udf_current_aext()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Kyle Zeng <[email protected]>
[ Upstream commit 120ec50984b8645232c2c004310dd94ceff5520e ]
Long allocation descriptors carry an on-disk extLocation.partitionReferenceNum. udf_current_aext() copies that value into a kernel_lb_addr and returns it to several consumers.
If the partition reference is outside s_partitions, callers can later index s_partmaps out of bounds. The truncate/free path can pass such an extent to udf_free_blocks(), where the invalid partition reference causes a slab out-of-bounds read.
Validate eloc->partitionReferenceNum in udf_current_aext() before returning a decoded extent. This rejects invalid file extents and indirect allocation descriptor extents in the common parser, so callers do not need to duplicate the partition-map bounds check.
--- fs/udf/inode.c | 7 +++++++ 1 file changed, 7 insertions(+)
fs/udf/inode.c +7 -0
@@ -2305,6 +2305,13 @@ int udf_current_aext(struct inode *inode, struct extent_position *epos,return -EINVAL ; } +if (eloc->partitionReferenceNum >=UDF_SB (inode->i_sb)->s_partitions) { +udf_debug ("invalid partition reference %u (partitions %u)\n" , + eloc->partitionReferenceNum, +UDF_SB (inode->i_sb)->s_partitions); +return -EFSCORRUPTED ; + } +return 1 ; }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 96/1536 udf: avoid recursive s_alloc_mutex deadlock when freeing AED blocks
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Deepanshu Kartikey <[email protected]>
[ Upstream commit 31e5e0c8c8e2617eb9f7a20c1cf5df23f592ade2 ]
udf_table_prealloc_blocks() and udf_table_new_block() call udf_delete_aext() on the unallocated-space-table inode while holding sbi->s_alloc_mutex. When the deleted allocation descriptor empties an allocation-extent (AED) block, udf_delete_aext() returns that block to free space via udf_free_blocks(). For a table-managed partition that path is udf_free_blocks() -> udf_table_free_blocks() -> mutex_lock(&sbi->s_alloc_mutex), i.e. the task tries to acquire a mutex it already holds.
On a PREEMPT_RT kernel the rtmutex deadlock detector reports this as -EDEADLK:
rtmutex deadlock detected
WARNING: kernel/locking/rtmutex.c:1698 at rt_mutex_handle_deadlock udf_table_free_blocks fs/udf/balloc.c:376 [inline] udf_free_blocks+0xa8c/0x1900 fs/udf/balloc.c:678 udf_delete_aext+0x4f5/0xc00 fs/udf/inode.c:2381 udf_table_prealloc_blocks fs/udf/balloc.c:544 [inline] udf_prealloc_blocks+0xbd4/0x10e0 fs/udf/balloc.c:702
On a non-RT kernel the same path is a hard self-deadlock (or a lockdep recursive-locking splat). It is reachable from a crafted UDF image via the write/sendfile path.
The allocator already refuses to recurse on the add side: see the comment in udf_table_free_blocks() explaining why it must not call udf_add_aext() while holding s_alloc_mutex. Apply the same rule to the delete side. Let udf_delete_aext() report the AED block it would otherwise free through a new out-parameter, and have the two callers that hold s_alloc_mutex free it after dropping the lock. The block is already unlinked from the inode's descriptor chain by then, so nothing can reference it in the meantime. All other callers pass NULL and keep freeing the block inline, exactly as before.
The out-parameter is pre-initialised with the reserved partition number 0xFFFF, which can never name a real block, so the caller can tell whether a block was handed back.
--- fs/udf/balloc.c | 12 ++++++++++-- fs/udf/inode.c | 19 ++++++++++++++++--- fs/udf/truncate.c | 2 +- fs/udf/udfdecl.h | 3 ++- 4 files changed, 29 insertions(+), 7 deletions(-)
fs/udf/balloc.c +10 -2
@@ -502,6 +502,8 @@ static int udf_table_prealloc_blocks(struct super_block *sb,int8_t etype =-1 ;struct udf_inode_info *iinfo;int ret =0 ; +/* AED block freed by udf_delete_aext(), released after unlock */ +struct kernel_lb_addr freed = { .partitionReferenceNum =0xFFFF };if (first_block >= sbi->s_partmaps[partition].s_partition_len)return 0 ;
@@ -541,7 +543,7 @@ static int udf_table_prealloc_blocks(struct super_block *sb,udf_write_aext (table, &epos, &eloc, (etype <<30 ) | elen,1 ); }else -udf_delete_aext (table, epos); +udf_delete_aext (table, epos, &freed); }else { alloc_count =0 ; }
@@ -552,6 +554,8 @@ static int udf_table_prealloc_blocks(struct super_block *sb,if (alloc_count)udf_add_free_space (sb, partition, -alloc_count);mutex_unlock (&sbi->s_alloc_mutex); +if (freed.partitionReferenceNum !=0xFFFF ) +udf_free_blocks (sb, table, &freed,0 ,1 );return alloc_count; }
@@ -560,6 +564,8 @@ static udf_pblk_t udf_table_new_block(struct super_block *sb, uint32_t goal, int *err) { struct udf_sb_info *sbi = UDF_SB(sb); +/* AED block freed by udf_delete_aext(), released after unlock */ +struct kernel_lb_addr freed = { .partitionReferenceNum =0xFFFF };uint32_t spread =0xFFFFFFFF , nspread =0xFFFFFFFF ;udf_pblk_t newblock =0 ;uint32_t adsize;
@@ -643,12 +649,14 @@ static udf_pblk_t udf_table_new_block(struct super_block *sb,if (goal_elen)udf_write_aext (table, &goal_epos, &goal_eloc, goal_elen,1 );else -udf_delete_aext (table, goal_epos); +udf_delete_aext (table, goal_epos, &freed);brelse (goal_epos.bh);udf_add_free_space (sb, partition,-1 );mutex_unlock (&sbi->s_alloc_mutex); +if (freed.partitionReferenceNum !=0xFFFF ) +udf_free_blocks (sb, table, &freed,0 ,1 ); *err =0 ;return newblock; }
fs/udf/inode.c +16 -3
@@ -1210,7 +1210,7 @@ static int udf_update_extents(struct inode *inode, struct kernel_long_ad *laarr,if (startnum > endnum) {for (i =0 ; i < (startnum - endnum); i++) -udf_delete_aext (inode, *epos); +udf_delete_aext (inode, *epos,NULL ); }else if (startnum < endnum) {for (i =0 ; i < (endnum - startnum); i++) { err = udf_insert_aext(inode, *epos,
@@ -2341,7 +2341,8 @@ static int udf_insert_aext(struct inode *inode, struct extent_position epos,return ret; } -int8_t udf_delete_aext (struct inode *inode,struct extent_position epos) +int8_t udf_delete_aext (struct inode *inode,struct extent_position epos, +struct kernel_lb_addr *freed) {struct extent_position oepos;int adsize;
@@ -2391,7 +2392,19 @@ int8_t udf_delete_aext(struct inode *inode, struct extent_position epos) elen =0 ;if (epos.bh != oepos.bh) { -udf_free_blocks (inode->i_sb, inode, &epos.block,0 ,1 ); +/* +* The block that held the now-empty allocation extent must be +* returned to free space. When the caller already holds +* s_alloc_mutex (the space-table allocator in balloc.c), +* freeing it inline would recurse through udf_free_blocks() +* into udf_table_free_blocks() and deadlock re-acquiring +* s_alloc_mutex. In that case report the block to the caller, +* which frees it after dropping the lock. +*/ +if (freed) + *freed = epos.block; +else +udf_free_blocks (inode->i_sb, inode, &epos.block,0 ,1 );udf_write_aext (inode, &oepos, &eloc, elen,1 );udf_write_aext (inode, &oepos, &eloc, elen,1 );if (!oepos.bh) {
fs/udf/truncate.c +1 -1
@@ -159,7 +159,7 @@ void udf_discard_prealloc(struct inode *inode)if (etype == (EXT_NOT_RECORDED_ALLOCATED >>30 )) { lbcount -= elen; -udf_delete_aext (inode, prev_epos); +udf_delete_aext (inode, prev_epos,NULL );udf_free_blocks (inode->i_sb, inode, &eloc,0 ,DIV_ROUND_UP (elen, bsize)); }
fs/udf/udfdecl.h +2 -1
@@ -169,7 +169,8 @@ extern int udf_add_aext(struct inode *, struct extent_position *, struct kernel_lb_addr *, uint32_t, int);extern void udf_write_aext (struct inode *,struct extent_position *,struct kernel_lb_addr *,uint32_t ,int ); -extern int8_t udf_delete_aext (struct inode *,struct extent_position ); +extern int8_t udf_delete_aext (struct inode *,struct extent_position , +struct kernel_lb_addr *);extern int udf_next_aext (struct inode *inode,struct extent_position *epos,struct kernel_lb_addr *eloc,uint32_t *elen,int8_t *etype,int inc);
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 97/1536 drm/amdgpu/atomfirmware: WARN() rather than BUG()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Alex Deucher <[email protected]>
[ Upstream commit d7c595044965c826e6f3ce30590d3ec4399cd633 ]
There's no need to crash the kernel for this case. Just return an error.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_atomfirmware.c | 2 -- 1 file changed, 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_atomfirmware.c +0 -2
@@ -797,8 +797,6 @@ int amdgpu_atomfirmware_get_clock_info(struct amdgpu_device *adev) (crev != 6)) { spll->reference_freq =le32_to_cpu (gfx_info->v22.rlc_gpu_timer_refclk); ret =0 ; - } else { -BUG (); } } }
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 80/1536 iio: adc: max1241: add missing MODULE_DEVICE_TABLE()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Pengpeng Hou <[email protected]>
[ Upstream commit 790a2080e0c9eabefea3561dec301172043de236 ]
The driver has a match table for the spi bus wired into its driver structure, but the table is not exported with MODULE_DEVICE_TABLE().
Add the missing MODULE_DEVICE_TABLE() entry so module alias information is generated for automatic module loading.
This is a source-level fix. It does not claim dynamic hardware reproduction; the evidence is the driver-owned match table, its use by the driver registration structure, and the missing module alias publication.
--- drivers/iio/adc/max1241.c | 1 + 1 file changed, 1 insertion(+)
drivers/iio/adc/max1241.c +1 -0
@@ -179,6 +179,7 @@ static const struct spi_device_id max1241_id[] = { { "max1241", max1241 }, { } }; +MODULE_DEVICE_TABLE (spi, max1241_id);static const struct of_device_id max1241_dt_ids[] = { { .compatible = "maxim,max1241" },
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 98/1536 drm/amdgpu/gfx11: WARN() rather than BUG() for invalid SDMA engine
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: Alex Deucher <[email protected]>
[ Upstream commit c24edbd5ae0e4f24e0179e8c9f22a867016177bb ]
There's no need to crash the kernel for these cases.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v11.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v11.c +2 -1
@@ -139,7 +139,8 @@ static uint32_t get_sdma_rlc_reg_offset(struct amdgpu_device *adev, regSDMA1_QUEUE0_RB_CNTL) - regSDMA0_QUEUE0_RB_CNTL;break ;default : -BUG (); +WARN (1 ,"Invalid SDMA engine id %d\n" , engine_id); +break ; } sdma_rlc_reg_offset = sdma_engine_reg_base
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 99/1536 nvme: dont reference NS after unlocking in nvme_ns_head_ctrl_ioctl()
In reply to Greg Kroah-Hartman6.12-stable review patch. If anyone has any objections, please let me know.
------------------
From: John Garry <[email protected]>
[ Upstream commit 77c57daf98a2ad95ec9ac1371caeff8939cc1f58 ]
In nvme_ns_head_ctrl_ioctl(), once we drop the SRCU read lock we should not reference the NS to lookup the controller, so use the available controller pointer directly.
--- drivers/nvme/host/ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/nvme/host/ioctl.c +1 -1
@@ -725,7 +725,7 @@ static int nvme_ns_head_ctrl_ioctl(struct nvme_ns *ns, unsigned int cmd,nvme_get_ctrl (ns->ctrl);srcu_read_unlock (&head->srcu, srcu_idx); - ret =nvme_ctrl_ioctl (ns->ctrl, cmd, argp, open_for_write); + ret =nvme_ctrl_ioctl (ctrl, cmd, argp, open_for_write);nvme_put_ctrl (ctrl);return ret;
Signature · 1 line
2.53.0