Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
115 commits
Select commit Hold shift + click to select a range
482dd75
nvmet-tcp: add bounds checks in nvmet_tcp_build_pdu_iovec
Jan 28, 2026
68804f3
x86/vmware: Fix hypercall clobbers
jpoimboe Feb 6, 2026
6d9fdd2
x86/kfence: fix booting on 32bit non-PAE systems
andyhhp Jan 26, 2026
1262af8
platform/x86: intel_telemetry: Fix swapped arrays in PSS output
kaushlen Dec 24, 2025
2a8631d
ALSA: aloop: Fix racy access at PCM trigger
tiwai Feb 3, 2026
a372d3a
pmdomain: qcom: rpmpd: fix off-by-one error in clamping to the highes…
juhosg Jan 22, 2026
e3b4bbe
pmdomain: imx8mp-blk-ctrl: Keep gpc power domain on for system wakeup
Feb 4, 2026
b460035
pmdomain: imx: gpcv2: Fix the imx8mm gpu hang due to wrong adb400 reset
JackyBai Jan 23, 2026
fc9f44e
pmdomain: imx8mp-blk-ctrl: Keep usb phy power domain on for system wa…
Feb 4, 2026
ff375f3
pmdomain: imx8m-blk-ctrl: fix out-of-range access of bc->domains
Jan 30, 2026
d4cb586
mm/slab: Add alloc_tagging_slab_free_hook for memcg_alloc_abort_single
Feb 4, 2026
1ccaf44
ceph: fix NULL pointer dereference in ceph_mds_auth_match()
dubeyko Feb 3, 2026
779a9c9
rbd: check for EOD after exclusive lock is ensured to be held
idryomov Jan 7, 2026
af6c195
ARM: 9468/1: fix memset64() on big-endian
t-8ch Jan 7, 2026
aaad463
ceph: fix oops due to invalid pointer for kfree() in parse_longname()
cytrinox Feb 1, 2026
3bbcfa5
gve: Fix stats report corruption on queue count change
Feb 2, 2026
b7b1089
gve: Correct ethtool rx_dropped calculation
ffyuanda Feb 2, 2026
b5c6003
mm, shmem: prevent infinite loop on truncate race
ryncsn Jan 28, 2026
4814818
Revert "drm/amd: Check if ASPM is enabled from PCIe subsystem"
spasswolf Feb 1, 2026
aac5a5a
KVM: Don't clobber irqfd routing type when deassigning irqfd
sean-jc Jan 13, 2026
6b954d2
PCI/ERR: Ensure error recoverability at all times
l1k Nov 19, 2025
adbf06d
tools/power turbostat: fix GCC9 build regression
tebrandt Jul 31, 2024
9f9451d
ublk: fix deadlock when reading partition table
Dec 12, 2025
8237e48
hfsplus: fix slab-out-of-bounds read in hfsplus_uni2asc()
void0red Sep 9, 2025
22123d6
binder: fix BR_FROZEN_REPLY error log
Jan 23, 2026
c78bd67
binderfs: fix ida_alloc_max() upper bound
Jan 27, 2026
c52f535
KVM: selftests: Add -U_FORTIFY_SOURCE to avoid some unpredictable tes…
freelancer-leon Feb 7, 2026
ddf8fdd
procfs: avoid fetching build ID while holding VMA lock
anakryiko Feb 7, 2026
bac3c5d
tracing: Fix ftrace event field alignments
rostedt Feb 7, 2026
54c83aa
wifi: mac80211: ocb: skip rx_no_sta when interface is not joined
moonheelee Dec 16, 2025
e79ecdf
wifi: wlcore: ensure skb headroom before skb_push
astrand Dec 3, 2025
6af2018
net: usb: sr9700: support devices with virtual driver CD
EthanNelson-Moore Dec 11, 2025
63e9cfe
block,bfq: fix aux stat accumulation destination
shechenglong-fusion Dec 28, 2025
7dd4f35
smb/server: call ksmbd_session_rpc_close() on error path in create_sm…
Dec 28, 2025
510fd19
LoongArch: Set correct protection_map[] for VM_NONE/VM_SHARED
chenhuacai Dec 31, 2025
b905aa7
md: suspend array while updating raid_disks via sysfs
Dec 26, 2025
6cc60ee
smb/server: fix refcount leak in smb2_open()
Dec 29, 2025
091b50a
LoongArch: Enable exception fixup for specific ADE subcode
Dec 31, 2025
bb0b3dc
smb/server: fix refcount leak in parse_durable_handle_context()
Dec 29, 2025
e3b9696
HID: intel-ish-hid: Update ishtp bus match to support device ID table
lixuzha Dec 10, 2025
d8ead1f
HID: multitouch: add MT_QUIRK_STICKY_FINGERS to MT_CLS_VTL
DaytonCL Dec 14, 2025
e24d744
btrfs: fix reservation leak in some error paths when inserting inline…
fdmanana Dec 12, 2025
7b34240
riscv: Sanitize syscall table indexing under speculation
Dec 18, 2025
a07a672
HID: intel-ish-hid: Reset enum_devices_done before enumeration
lixuzha Dec 12, 2025
10f01ab
HID: playstation: Center initial joystick axes to prevent spurious ev…
vishniakou Nov 11, 2025
1cc41ce
ALSA: hda/realtek: Add quirk for Acer Nitro AN517-55
B-kiplingi Dec 31, 2025
4b9c3df
ALSA: hda/realtek: add HP Laptop 15s-eq1xxx mute LED quirk
3xxx0rc1st Jan 1, 2026
9884f51
PCI: qcom: Remove ASPM L0s support for MSM8996 SoC
Mani-Sadhasivam Nov 26, 2025
26cbe30
netfilter: replace -EEXIST with -EBUSY
dagomez137 Dec 19, 2025
16f261f
HID: quirks: Add another Chicony HP 5MP Cameras to hid_ignore_list
mschiu77 Jan 2, 2026
8d73022
HID: i2c-hid: fix potential buffer overflow in i2c_hid_get_report()
kenkinming2002 Dec 31, 2025
931fd00
HID: Apply quirk HID_QUIRK_ALWAYS_POLL to Edifier QR30 (2d99:a101)
Nov 27, 2025
5226a6f
drm/amd/pm: Disable MMIO access during SMU Mode 1 reset
Dec 25, 2025
4afcc28
ring-buffer: Avoid softlockup in ring_buffer_resize() during memory free
Dec 28, 2025
15e238d
HID: logitech: add HID++ support for Logitech MX Anywhere 3S
twelho Jan 4, 2026
d4a7439
wifi: mac80211: collect station statistics earlier when disconnect
Dec 22, 2025
c7a7802
ASoC: davinci-evm: Fix reference leak in davinci_evm_probe
Keryer Jan 7, 2026
4be6e85
ASoC: simple-card-utils: Check device node before overwrite direction
TE-N-ShengjiuWang Dec 29, 2025
13cb29d
nvme-fc: release admin tagset if init fails
ChaitanayaKulkarni Dec 20, 2025
a25bdb1
nvmet-tcp: fixup hang in nvmet_tcp_listen_data_ready()
Aug 18, 2025
5eb2adb
ASoC: amd: yc: Fix microphone on ASUS M6500RE
Jan 12, 2026
bef3be2
ASoC: tlv320adcx140: Propagate error codes during probe
DmtKats Jan 13, 2026
91b0495
spi: hisi-kunpeng: Fixed the wrong debugfs node name in hisi_spi debu…
Jan 8, 2026
b41e67d
regmap: maple: free entry on mas_store_gfp() failure
kaushlen Jan 5, 2026
a9023c7
wifi: cfg80211: Fix bitrate calculation overflow for HE rates
Jan 9, 2026
a3ec9cb
scsi: target: iscsi: Fix use-after-free in iscsit_dec_session_usage_c…
maurizio-lombardi Jan 12, 2026
649dc45
ALSA: hda/realtek: Fix headset mic for TongFang X6AR55xU
Jan 19, 2026
e5bd616
scsi: target: iscsi: Fix use-after-free in iscsit_dec_conn_usage_count()
maurizio-lombardi Jan 12, 2026
8eb07fe
wifi: mac80211: correctly check if CSA is active
Miriam-Rachel Jan 11, 2026
9ca80e8
wifi: mac80211: don't increment crypto_tx_tailroom_needed_cnt twice
Miriam-Rachel Jan 18, 2026
128dd01
btrfs: reject new transactions if the fs is fully read-only
adam900710 Jan 13, 2026
10be9ce
ALSA: hda/realtek: ALC269 fixup for Lenovo Yoga Book 9i 13IRU8 audio
martin-hamilton Jan 22, 2026
b615bb5
platform/x86: toshiba_haps: Fix memory leaks in add/remove routines
rafaeljw Jan 26, 2026
faa789c
platform/x86: intel_telemetry: Fix PSS event register mask
kaushlen Dec 24, 2025
cd59230
platform/x86: hp-bioscfg: Skip empty attribute names
superm1 Jan 28, 2026
2407730
platform/x86/intel/tpmi/plr: Make the file domain<n>/status writeable
ricardon Jan 27, 2026
a550905
smb/client: fix memory leak in smb2_open_file()
Feb 2, 2026
ab46211
net: add skb_header_pointer_careful() helper
edumazet Jan 28, 2026
651e2c8
net/sched: cls_u32: use skb_header_pointer_careful()
edumazet Jan 28, 2026
50fd57f
dpaa2-switch: prevent ZERO_SIZE_PTR dereference when num_ifs is zero
avasummer Jan 28, 2026
fb0b315
net: liquidio: Initialize netdev pointer before queue setup
GoodLuck612 Jan 28, 2026
4c05a3d
net: liquidio: Fix off-by-one error in PF setup_nic_devices() cleanup
GoodLuck612 Jan 28, 2026
2e81a8f
net: liquidio: Fix off-by-one error in VF setup_nic_devices() cleanup
GoodLuck612 Jan 28, 2026
5745f0e
dpaa2-switch: add bounds check for if_id in IRQ handler
avasummer Jan 28, 2026
773bfdb
net: phy: add phy_interface_weight()
Aug 31, 2025
49ccd0b
net: phy: add phy_interface_copy()
Sep 16, 2025
742b02a
net: sfp: pre-parse the module support
Sep 16, 2025
1a1a151
net: sfp: convert sfp quirks to modify struct sfp_module_support
Sep 16, 2025
b4c8be2
net: sfp: Fix quirk for Ubiquiti U-Fiber Instant SFP module
elkablo Jan 29, 2026
e7d1ad0
macvlan: fix error recovery in macvlan_common_newlink()
edumazet Jan 29, 2026
b7134fb
net: usb: r8152: fix resume reset deadlock
sergey-senozhatsky Jan 29, 2026
f56d26b
net: don't touch dev->stats in BPF redirect paths
kuba-moo Jan 30, 2026
8c486b5
tipc: use kfree_sensitive() for session key material
hodgesds Jan 31, 2026
93081c0
drm/amd/display: fix wrong color value mapping on MCM shaper LUT
melissawen Jan 22, 2026
c829427
net: ethernet: adi: adin1110: Check return value of devm_gpiod_get_op…
Feb 2, 2026
cbc20cd
net: gro: fix outer network offset
Feb 2, 2026
54025b2
drm/mgag200: fix mgag200_bmc_stop_scanout()
jacob-keller Feb 3, 2026
2142e33
drm/xe/query: Fix topology query pointer advance
ShuichengLin Jan 30, 2026
32467ce
drm/xe/pm: Also avoid missing outer rpm warning on system suspend
rodrigovivi Dec 17, 2024
adf2abf
drm/xe/pm: Disable D3Cold for BMG only on specific platforms
kpoosa Jan 23, 2026
d6ae8cf
hwmon: (occ) Mark occ_init_attribute() as __printf
arndb Feb 3, 2026
f4e1dfa
netfilter: nf_tables: fix inverted genmask check in nft_map_catchall_…
andrew-aisi Feb 4, 2026
586b915
ipv6: Fix ECMP sibling count mismatch when clearing RTF_ADDRCONF
Feb 4, 2026
f261ee3
ALSA: usb-audio: fix broken logic in snd_audigy2nx_led_update()
Feb 3, 2026
9570c46
ASoC: amd: fix memory leak in acp3x pdm dma ops
chrisbainbridge Feb 2, 2026
60451d6
spi: tegra210-quad: Return IRQ_HANDLED when timeout already processed…
leitao Jan 26, 2026
83ec7bd
spi: tegra210-quad: Move curr_xfer read inside spinlock
leitao Jan 26, 2026
b9a6e72
spi: tegra210-quad: Protect curr_xfer assignment in tegra_qspi_setup_…
leitao Jan 26, 2026
ee514bf
spi: tegra210-quad: Protect curr_xfer in tegra_qspi_combined_seq_xfer
leitao Jan 26, 2026
50190c0
spi: tegra210-quad: Protect curr_xfer clearing in tegra_qspi_non_comb…
leitao Jan 26, 2026
cc071c4
spi: tegra: Fix a memory leak in tegra_slink_probe()
outman119 Feb 2, 2026
0594e24
spi: tegra114: Preserve SPI mode bits in def_command1_reg
Feb 4, 2026
c4f9fa6
ALSA: hda/realtek: Really fix headset mic for TongFang X6AR55xU.
tuxedo-wse Jan 23, 2026
577d17b
gpiolib-acpi: Update file references in the Documentation and MAINTAI…
andy-shev May 16, 2025
cb618cf
Linux 6.12.70
gregkh Feb 11, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Documentation/driver-api/gpio/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Core
ACPI support
============

.. kernel-doc:: drivers/gpio/gpiolib-acpi.c
.. kernel-doc:: drivers/gpio/gpiolib-acpi-core.c
:export:

Device tree support
Expand Down
2 changes: 1 addition & 1 deletion Documentation/translations/zh_CN/driver-api/gpio/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ ACPI支持

该API在以下内核代码中:

drivers/gpio/gpiolib-acpi.c
drivers/gpio/gpiolib-acpi-core.c

设备树支持
==========
Expand Down
2 changes: 1 addition & 1 deletion MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -9703,7 +9703,7 @@ L: linux-acpi@vger.kernel.org
S: Supported
T: git git://git.kernel.org/pub/scm/linux/kernel/git/andy/linux-gpio-intel.git
F: Documentation/firmware-guide/acpi/gpio-properties.rst
F: drivers/gpio/gpiolib-acpi.c
F: drivers/gpio/gpiolib-acpi-*.c
F: drivers/gpio/gpiolib-acpi.h

GPIO AGGREGATOR
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# SPDX-License-Identifier: GPL-2.0
VERSION = 6
PATCHLEVEL = 12
SUBLEVEL = 69
SUBLEVEL = 70
EXTRAVERSION =
NAME = Baby Opossum Posse

Expand Down
5 changes: 4 additions & 1 deletion arch/arm/include/asm/string.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,10 @@ static inline void *memset32(uint32_t *p, uint32_t v, __kernel_size_t n)
extern void *__memset64(uint64_t *, uint32_t low, __kernel_size_t, uint32_t hi);
static inline void *memset64(uint64_t *p, uint64_t v, __kernel_size_t n)
{
return __memset64(p, v, n * 8, v >> 32);
if (IS_ENABLED(CONFIG_CPU_LITTLE_ENDIAN))
return __memset64(p, v, n * 8, v >> 32);
else
return __memset64(p, v >> 32, n * 8, v);
}

/*
Expand Down
5 changes: 5 additions & 0 deletions arch/loongarch/kernel/traps.c
Original file line number Diff line number Diff line change
Expand Up @@ -534,10 +534,15 @@ asmlinkage void noinstr do_fpe(struct pt_regs *regs, unsigned long fcsr)
asmlinkage void noinstr do_ade(struct pt_regs *regs)
{
irqentry_state_t state = irqentry_enter(regs);
unsigned int esubcode = FIELD_GET(CSR_ESTAT_ESUBCODE, regs->csr_estat);

if ((esubcode == EXSUBCODE_ADEM) && fixup_exception(regs))
goto out;

die_if_kernel("Kernel ade access", regs);
force_sig_fault(SIGBUS, BUS_ADRERR, (void __user *)regs->csr_badvaddr);

out:
irqentry_exit(regs, state);
}

Expand Down
8 changes: 4 additions & 4 deletions arch/loongarch/mm/cache.c
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,8 @@ void cpu_cache_init(void)

static const pgprot_t protection_map[16] = {
[VM_NONE] = __pgprot(_CACHE_CC | _PAGE_USER |
_PAGE_PROTNONE | _PAGE_NO_EXEC |
_PAGE_NO_READ),
_PAGE_NO_EXEC | _PAGE_NO_READ |
(_PAGE_PROTNONE ? : _PAGE_PRESENT)),
[VM_READ] = __pgprot(_CACHE_CC | _PAGE_VALID |
_PAGE_USER | _PAGE_PRESENT |
_PAGE_NO_EXEC),
Expand All @@ -201,8 +201,8 @@ static const pgprot_t protection_map[16] = {
[VM_EXEC | VM_WRITE | VM_READ] = __pgprot(_CACHE_CC | _PAGE_VALID |
_PAGE_USER | _PAGE_PRESENT),
[VM_SHARED] = __pgprot(_CACHE_CC | _PAGE_USER |
_PAGE_PROTNONE | _PAGE_NO_EXEC |
_PAGE_NO_READ),
_PAGE_NO_EXEC | _PAGE_NO_READ |
(_PAGE_PROTNONE ? : _PAGE_PRESENT)),
[VM_SHARED | VM_READ] = __pgprot(_CACHE_CC | _PAGE_VALID |
_PAGE_USER | _PAGE_PRESENT |
_PAGE_NO_EXEC),
Expand Down
4 changes: 3 additions & 1 deletion arch/riscv/kernel/traps.c
Original file line number Diff line number Diff line change
Expand Up @@ -339,8 +339,10 @@ void do_trap_ecall_u(struct pt_regs *regs)

add_random_kstack_offset();

if (syscall >= 0 && syscall < NR_syscalls)
if (syscall >= 0 && syscall < NR_syscalls) {
syscall = array_index_nospec(syscall, NR_syscalls);
syscall_handler(regs, syscall);
}

/*
* Ultimately, this value will get limited by KSTACK_OFFSET_MAX(),
Expand Down
7 changes: 4 additions & 3 deletions arch/x86/include/asm/kfence.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ static inline bool kfence_protect_page(unsigned long addr, bool protect)
{
unsigned int level;
pte_t *pte = lookup_address(addr, &level);
pteval_t val;
pteval_t val, new;

if (WARN_ON(!pte || level != PG_LEVEL_4K))
return false;
Expand All @@ -57,11 +57,12 @@ static inline bool kfence_protect_page(unsigned long addr, bool protect)
return true;

/*
* Otherwise, invert the entire PTE. This avoids writing out an
* Otherwise, flip the Present bit, taking care to avoid writing an
* L1TF-vulnerable PTE (not present, without the high address bits
* set).
*/
set_pte(pte, __pte(~val));
new = val ^ _PAGE_PRESENT;
set_pte(pte, __pte(flip_protnone_guard(val, new, PTE_PFN_MASK)));

/*
* If the page was protected (non-present) and we're making it
Expand Down
4 changes: 2 additions & 2 deletions arch/x86/include/asm/vmware.h
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ unsigned long vmware_hypercall3(unsigned long cmd, unsigned long in1,
"b" (in1),
"c" (cmd),
"d" (0)
: "cc", "memory");
: "di", "si", "cc", "memory");
return out0;
}

Expand All @@ -165,7 +165,7 @@ unsigned long vmware_hypercall4(unsigned long cmd, unsigned long in1,
"b" (in1),
"c" (cmd),
"d" (0)
: "cc", "memory");
: "di", "si", "cc", "memory");
return out0;
}

Expand Down
2 changes: 1 addition & 1 deletion block/bfq-cgroup.c
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ static void bfqg_stats_add_aux(struct bfqg_stats *to, struct bfqg_stats *from)
blkg_rwstat_add_aux(&to->merged, &from->merged);
blkg_rwstat_add_aux(&to->service_time, &from->service_time);
blkg_rwstat_add_aux(&to->wait_time, &from->wait_time);
bfq_stat_add_aux(&from->time, &from->time);
bfq_stat_add_aux(&to->time, &from->time);
bfq_stat_add_aux(&to->avg_queue_size_sum, &from->avg_queue_size_sum);
bfq_stat_add_aux(&to->avg_queue_size_samples,
&from->avg_queue_size_samples);
Expand Down
5 changes: 3 additions & 2 deletions drivers/android/binder.c
Original file line number Diff line number Diff line change
Expand Up @@ -3749,8 +3749,9 @@ static void binder_transaction(struct binder_proc *proc,
return;

err_dead_proc_or_thread:
binder_txn_error("%d:%d dead process or thread\n",
thread->pid, proc->pid);
binder_txn_error("%d:%d %s process or thread\n",
proc->pid, thread->pid,
return_error == BR_FROZEN_REPLY ? "frozen" : "dead");
return_error_line = __LINE__;
binder_dequeue_work(proc, tcomplete);
err_translate_failed:
Expand Down
8 changes: 4 additions & 4 deletions drivers/android/binderfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,8 @@ static int binderfs_binder_device_create(struct inode *ref_inode,
mutex_lock(&binderfs_minors_mutex);
if (++info->device_count <= info->mount_opts.max)
minor = ida_alloc_max(&binderfs_minors,
use_reserve ? BINDERFS_MAX_MINOR :
BINDERFS_MAX_MINOR_CAPPED,
use_reserve ? BINDERFS_MAX_MINOR - 1 :
BINDERFS_MAX_MINOR_CAPPED - 1,
GFP_KERNEL);
else
minor = -ENOSPC;
Expand Down Expand Up @@ -422,8 +422,8 @@ static int binderfs_binder_ctl_create(struct super_block *sb)
/* Reserve a new minor number for the new device. */
mutex_lock(&binderfs_minors_mutex);
minor = ida_alloc_max(&binderfs_minors,
use_reserve ? BINDERFS_MAX_MINOR :
BINDERFS_MAX_MINOR_CAPPED,
use_reserve ? BINDERFS_MAX_MINOR - 1 :
BINDERFS_MAX_MINOR_CAPPED - 1,
GFP_KERNEL);
mutex_unlock(&binderfs_minors_mutex);
if (minor < 0) {
Expand Down
11 changes: 6 additions & 5 deletions drivers/base/regmap/regcache-maple.c
Original file line number Diff line number Diff line change
Expand Up @@ -96,12 +96,13 @@ static int regcache_maple_write(struct regmap *map, unsigned int reg,

mas_unlock(&mas);

if (ret == 0) {
kfree(lower);
kfree(upper);
if (ret) {
kfree(entry);
return ret;
}

return ret;
kfree(lower);
kfree(upper);
return 0;
}

static int regcache_maple_drop(struct regmap *map, unsigned int min,
Expand Down
33 changes: 21 additions & 12 deletions drivers/block/rbd.c
Original file line number Diff line number Diff line change
Expand Up @@ -3495,11 +3495,29 @@ static void rbd_img_object_requests(struct rbd_img_request *img_req)
rbd_assert(!need_exclusive_lock(img_req) ||
__rbd_is_lock_owner(rbd_dev));

if (rbd_img_is_write(img_req)) {
rbd_assert(!img_req->snapc);
if (test_bit(IMG_REQ_CHILD, &img_req->flags)) {
rbd_assert(!rbd_img_is_write(img_req));
} else {
struct request *rq = blk_mq_rq_from_pdu(img_req);
u64 off = (u64)blk_rq_pos(rq) << SECTOR_SHIFT;
u64 len = blk_rq_bytes(rq);
u64 mapping_size;

down_read(&rbd_dev->header_rwsem);
img_req->snapc = ceph_get_snap_context(rbd_dev->header.snapc);
mapping_size = rbd_dev->mapping.size;
if (rbd_img_is_write(img_req)) {
rbd_assert(!img_req->snapc);
img_req->snapc =
ceph_get_snap_context(rbd_dev->header.snapc);
}
up_read(&rbd_dev->header_rwsem);

if (unlikely(off + len > mapping_size)) {
rbd_warn(rbd_dev, "beyond EOD (%llu~%llu > %llu)",
off, len, mapping_size);
img_req->pending.result = -EIO;
return;
}
}

for_each_obj_request(img_req, obj_req) {
Expand Down Expand Up @@ -4725,7 +4743,6 @@ static void rbd_queue_workfn(struct work_struct *work)
struct request *rq = blk_mq_rq_from_pdu(img_request);
u64 offset = (u64)blk_rq_pos(rq) << SECTOR_SHIFT;
u64 length = blk_rq_bytes(rq);
u64 mapping_size;
int result;

/* Ignore/skip any zero-length requests */
Expand All @@ -4738,17 +4755,9 @@ static void rbd_queue_workfn(struct work_struct *work)
blk_mq_start_request(rq);

down_read(&rbd_dev->header_rwsem);
mapping_size = rbd_dev->mapping.size;
rbd_img_capture_header(img_request);
up_read(&rbd_dev->header_rwsem);

if (offset + length > mapping_size) {
rbd_warn(rbd_dev, "beyond EOD (%llu~%llu > %llu)", offset,
length, mapping_size);
result = -EIO;
goto err_img_request;
}

dout("%s rbd_dev %p img_req %p %s %llu~%llu\n", __func__, rbd_dev,
img_request, obj_op_name(op_type), offset, length);

Expand Down
30 changes: 27 additions & 3 deletions drivers/block/ublk_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -1020,13 +1020,21 @@ static inline bool ubq_daemon_is_dying(struct ublk_queue *ubq)
return ubq->ubq_daemon->flags & PF_EXITING;
}

static void ublk_end_request(struct request *req, blk_status_t error)
{
local_bh_disable();
blk_mq_end_request(req, error);
local_bh_enable();
}

/* todo: handle partial completion */
static inline void __ublk_complete_rq(struct request *req)
{
struct ublk_queue *ubq = req->mq_hctx->driver_data;
struct ublk_io *io = &ubq->ios[req->tag];
unsigned int unmapped_bytes;
blk_status_t res = BLK_STS_OK;
bool requeue;

/* called from ublk_abort_queue() code path */
if (io->flags & UBLK_IO_FLAG_ABORTED) {
Expand Down Expand Up @@ -1064,14 +1072,30 @@ static inline void __ublk_complete_rq(struct request *req)
if (unlikely(unmapped_bytes < io->res))
io->res = unmapped_bytes;

if (blk_update_request(req, BLK_STS_OK, io->res))
/*
* Run bio->bi_end_io() with softirqs disabled. If the final fput
* happens off this path, then that will prevent ublk's blkdev_release()
* from being called on current's task work, see fput() implementation.
*
* Otherwise, ublk server may not provide forward progress in case of
* reading the partition table from bdev_open() with disk->open_mutex
* held, and causes dead lock as we could already be holding
* disk->open_mutex here.
*
* Preferably we would not be doing IO with a mutex held that is also
* used for release, but this work-around will suffice for now.
*/
local_bh_disable();
requeue = blk_update_request(req, BLK_STS_OK, io->res);
local_bh_enable();
if (requeue)
blk_mq_requeue_request(req, true);
else
__blk_mq_end_request(req, BLK_STS_OK);

return;
exit:
blk_mq_end_request(req, res);
ublk_end_request(req, res);
}

static void ublk_complete_rq(struct kref *ref)
Expand Down Expand Up @@ -1149,7 +1173,7 @@ static inline void __ublk_abort_rq(struct ublk_queue *ubq,
if (ublk_nosrv_dev_should_queue_io(ubq->dev))
blk_mq_requeue_request(rq, false);
else
blk_mq_end_request(rq, BLK_STS_IOERR);
ublk_end_request(rq, BLK_STS_IOERR);
}

static inline void __ublk_rq_task_work(struct request *req,
Expand Down
3 changes: 3 additions & 0 deletions drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -5325,6 +5325,9 @@ int amdgpu_device_mode1_reset(struct amdgpu_device *adev)
if (ret)
goto mode1_reset_failed;

/* enable mmio access after mode 1 reset completed */
adev->no_hw_access = false;

amdgpu_device_load_pci_state(adev->pdev);
ret = amdgpu_psp_wait_for_bootloader(adev);
if (ret)
Expand Down
3 changes: 0 additions & 3 deletions drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -2273,9 +2273,6 @@ static int amdgpu_pci_probe(struct pci_dev *pdev,
return -ENODEV;
}

if (amdgpu_aspm == -1 && !pcie_aspm_enabled(pdev))
amdgpu_aspm = 0;

if (amdgpu_virtual_display ||
amdgpu_device_asic_has_dc_support(flags & AMD_ASIC_MASK))
supports_atomic = true;
Expand Down
7 changes: 5 additions & 2 deletions drivers/gpu/drm/amd/display/dc/dcn30/dcn30_cm_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,11 @@ bool cm3_helper_translate_curve_to_hw_format(
hw_points += (1 << seg_distr[k]);
}

// DCN3+ have 257 pts in lieu of no separate slope registers
// Prior HW had 256 base+slope pairs
// Shaper LUT (i.e. fixpoint == true) is still 256 bases and 256 deltas
hw_points = fixpoint ? (hw_points - 1) : hw_points;

j = 0;
for (k = 0; k < (region_end - region_start); k++) {
increment = NUMBER_SW_SEGMENTS / (1 << seg_distr[k]);
Expand Down Expand Up @@ -228,8 +233,6 @@ bool cm3_helper_translate_curve_to_hw_format(
corner_points[1].green.slope = dc_fixpt_zero;
corner_points[1].blue.slope = dc_fixpt_zero;

// DCN3+ have 257 pts in lieu of no separate slope registers
// Prior HW had 256 base+slope pairs
lut_params->hw_points_num = hw_points + 1;

k = 0;
Expand Down
7 changes: 6 additions & 1 deletion drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_0_ppt.c
Original file line number Diff line number Diff line change
Expand Up @@ -2853,8 +2853,13 @@ static int smu_v13_0_0_mode1_reset(struct smu_context *smu)
break;
}

if (!ret)
if (!ret) {
/* disable mmio access while doing mode 1 reset*/
smu->adev->no_hw_access = true;
/* ensure no_hw_access is globally visible before any MMIO */
smp_mb();
msleep(SMU13_MODE1_RESET_WAIT_TIME_IN_MS);
}

return ret;
}
Expand Down
9 changes: 7 additions & 2 deletions drivers/gpu/drm/amd/pm/swsmu/smu14/smu_v14_0_2_ppt.c
Original file line number Diff line number Diff line change
Expand Up @@ -2129,10 +2129,15 @@ static int smu_v14_0_2_mode1_reset(struct smu_context *smu)

ret = smu_cmn_send_debug_smc_msg(smu, DEBUGSMC_MSG_Mode1Reset);
if (!ret) {
if (amdgpu_emu_mode == 1)
if (amdgpu_emu_mode == 1) {
msleep(50000);
else
} else {
/* disable mmio access while doing mode 1 reset*/
smu->adev->no_hw_access = true;
/* ensure no_hw_access is globally visible before any MMIO */
smp_mb();
msleep(1000);
}
}

return ret;
Expand Down
Loading