Skip to content

Commit 5b4238c

Browse files
committed
Merge tag 'v6.12.78' into 6.12-main
This is the 6.12.78 stable release # -----BEGIN PGP SIGNATURE----- # # iQIzBAABCgAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmnDtEsACgkQONu9yGCS # aT4GgA/8DLNTuvsoNVhgrc8HDDjZT0ln/Y1xu3UINnv9lkfX8e95EZhRoM9J0lgR # thCXsYphSpS6EIeFqifS2gZSnKuWqRY5qNuxknzZiLjm/6V6FVY3oU54Lr9H1pTx # VhOM8xYAeEZWyhgFAWpCAFphXJUrr2oK0fYOiQbxau7FlbjAQAfgTJ3W4HIjJUV3 # sx0SRUHGaCF2kmG7PCEcQhHCovP89Y7DSq/Oy5bFIX2v2RbO76uBNhkmSCfWoovv # Ufx7bjKM/LgCpbBRvZ0OPvf+gqg6m8AQHKASc6vjk/zIlAMNvf1UBPvZFCN4f+Km # DF92n6Mdk2L22YkYJEJV1dnh0JIumLNVyVH2HlOuNrzBXD4G4hO2CdA66vcJM9uH # gjozgxe3jhQ/5+umuFVW/0IFFiKp7m0gCxGkzULzhZtKQaYaemWY5KUQZuFAfnxa # 6N8MgTpTanh2w5hPqF2p/mB2k1XwKKE9MXWeEHHuYZ/TpIfmQsyr1z6EzX/49wR5 # 1J4Qm3WMEnmkCtjqYOyXIPnDnJJlJE49mLxxBFAIzdidKDArcuj5je4GBYxFKqw8 # O7sUthOHGcKKVm28sQ3FaHa3VY245qLmHRbCAU2ozZCOzPSqyQB5WDeVKQUepYwD # 9AZ6ZxIOAP/NsudU1Sxk361u+fQ4XUseILrniSX4XYqEruNjIW0= # =5QwP # -----END PGP SIGNATURE----- # gpg: Signature made Wed Mar 25 11:09:15 2026 CET # gpg: using RSA key 647F28654894E3BD457199BE38DBBDC86092693E # gpg: Can't check signature: No public key
2 parents 054138d + 4859112 commit 5b4238c

503 files changed

Lines changed: 5250 additions & 2255 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Documentation/virt/kvm/api.rst

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8107,6 +8107,58 @@ KVM_X86_QUIRK_SLOT_ZAP_ALL By default, for KVM_X86_DEFAULT_VM VMs, KVM
81078107
or moved memslot isn't reachable, i.e KVM
81088108
_may_ invalidate only SPTEs related to the
81098109
memslot.
8110+
8111+
KVM_X86_QUIRK_STUFF_FEATURE_MSRS By default, at vCPU creation, KVM sets the
8112+
vCPU's MSR_IA32_PERF_CAPABILITIES (0x345),
8113+
MSR_IA32_ARCH_CAPABILITIES (0x10a),
8114+
MSR_PLATFORM_INFO (0xce), and all VMX MSRs
8115+
(0x480..0x492) to the maximal capabilities
8116+
supported by KVM. KVM also sets
8117+
MSR_IA32_UCODE_REV (0x8b) to an arbitrary
8118+
value (which is different for Intel vs.
8119+
AMD). Lastly, when guest CPUID is set (by
8120+
userspace), KVM modifies select VMX MSR
8121+
fields to force consistency between guest
8122+
CPUID and L2's effective ISA. When this
8123+
quirk is disabled, KVM zeroes the vCPU's MSR
8124+
values (with two exceptions, see below),
8125+
i.e. treats the feature MSRs like CPUID
8126+
leaves and gives userspace full control of
8127+
the vCPU model definition. This quirk does
8128+
not affect VMX MSRs CR0/CR4_FIXED1 (0x487
8129+
and 0x489), as KVM does now allow them to
8130+
be set by userspace (KVM sets them based on
8131+
guest CPUID, for safety purposes).
8132+
8133+
KVM_X86_QUIRK_IGNORE_GUEST_PAT By default, on Intel platforms, KVM ignores
8134+
guest PAT and forces the effective memory
8135+
type to WB in EPT. The quirk is not available
8136+
on Intel platforms which are incapable of
8137+
safely honoring guest PAT (i.e., without CPU
8138+
self-snoop, KVM always ignores guest PAT and
8139+
forces effective memory type to WB). It is
8140+
also ignored on AMD platforms or, on Intel,
8141+
when a VM has non-coherent DMA devices
8142+
assigned; KVM always honors guest PAT in
8143+
such case. The quirk is needed to avoid
8144+
slowdowns on certain Intel Xeon platforms
8145+
(e.g. ICX, SPR) where self-snoop feature is
8146+
supported but UC is slow enough to cause
8147+
issues with some older guests that use
8148+
UC instead of WC to map the video RAM.
8149+
Userspace can disable the quirk to honor
8150+
guest PAT if it knows that there is no such
8151+
guest software, for example if it does not
8152+
expose a bochs graphics device (which is
8153+
known to have had a buggy driver).
8154+
8155+
KVM_X86_QUIRK_VMCS12_ALLOW_FREEZE_IN_SMM By default, KVM relaxes the consistency
8156+
check for GUEST_IA32_DEBUGCTL in vmcs12
8157+
to allow FREEZE_IN_SMM to be set. When
8158+
this quirk is disabled, KVM requires this
8159+
bit to be cleared. Note that the vmcs02
8160+
bit is still completely controlled by the
8161+
host, regardless of the quirk setting.
81108162
=================================== ============================================
81118163

81128164
7.32 KVM_CAP_MAX_VCPU_ID

Makefile

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: GPL-2.0
22
VERSION = 6
33
PATCHLEVEL = 12
4-
SUBLEVEL = 77
4+
SUBLEVEL = 78
55
EXTRAVERSION =
66
NAME = Baby Opossum Posse
77

@@ -446,6 +446,7 @@ KBUILD_USERLDFLAGS := $(USERLDFLAGS)
446446
export rust_common_flags := --edition=2021 \
447447
-Zbinary_dep_depinfo=y \
448448
-Astable_features \
449+
-Aunused_features \
449450
-Dnon_ascii_idents \
450451
-Dunsafe_op_in_unsafe_fn \
451452
-Wmissing_docs \
@@ -1370,13 +1371,13 @@ ifneq ($(wildcard $(resolve_btfids_O)),)
13701371
$(Q)$(MAKE) -sC $(srctree)/tools/bpf/resolve_btfids O=$(resolve_btfids_O) clean
13711372
endif
13721373

1373-
PHONY += objtool_clean
1374+
PHONY += objtool_clean objtool_mrproper
13741375

13751376
objtool_O = $(abspath $(objtree))/tools/objtool
13761377

1377-
objtool_clean:
1378+
objtool_clean objtool_mrproper:
13781379
ifneq ($(wildcard $(objtool_O)),)
1379-
$(Q)$(MAKE) -sC $(abs_srctree)/tools/objtool O=$(objtool_O) srctree=$(abs_srctree) clean
1380+
$(Q)$(MAKE) -sC $(abs_srctree)/tools/objtool O=$(objtool_O) srctree=$(abs_srctree) $(patsubst objtool_%,%,$@)
13801381
endif
13811382

13821383
tools/: FORCE
@@ -1547,7 +1548,7 @@ PHONY += $(mrproper-dirs) mrproper
15471548
$(mrproper-dirs):
15481549
$(Q)$(MAKE) $(clean)=$(patsubst _mrproper_%,%,$@)
15491550

1550-
mrproper: clean $(mrproper-dirs)
1551+
mrproper: clean objtool_mrproper $(mrproper-dirs)
15511552
$(call cmd,rmfiles)
15521553
@find . $(RCS_FIND_IGNORE) \
15531554
\( -name '*.rmeta' \) \

arch/arm/kernel/machine_kexec.c

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -127,29 +127,6 @@ void crash_smp_send_stop(void)
127127
cpus_stopped = 1;
128128
}
129129

130-
static void machine_kexec_mask_interrupts(void)
131-
{
132-
unsigned int i;
133-
struct irq_desc *desc;
134-
135-
for_each_irq_desc(i, desc) {
136-
struct irq_chip *chip;
137-
138-
chip = irq_desc_get_chip(desc);
139-
if (!chip)
140-
continue;
141-
142-
if (chip->irq_eoi && irqd_irq_inprogress(&desc->irq_data))
143-
chip->irq_eoi(&desc->irq_data);
144-
145-
if (chip->irq_mask)
146-
chip->irq_mask(&desc->irq_data);
147-
148-
if (chip->irq_disable && !irqd_irq_disabled(&desc->irq_data))
149-
chip->irq_disable(&desc->irq_data);
150-
}
151-
}
152-
153130
void machine_crash_shutdown(struct pt_regs *regs)
154131
{
155132
local_irq_disable();

arch/arm64/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,7 @@ config ARM64
146146
select GENERIC_IDLE_POLL_SETUP
147147
select GENERIC_IOREMAP
148148
select GENERIC_IRQ_IPI
149+
select GENERIC_IRQ_KEXEC_CLEAR_VM_FORWARD
149150
select GENERIC_IRQ_PROBE
150151
select GENERIC_IRQ_SHOW
151152
select GENERIC_IRQ_SHOW_LEVEL

arch/arm64/boot/dts/qcom/sdm845-oneplus-common.dtsi

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,6 @@
246246
regulator-min-microvolt = <1800000>;
247247
regulator-max-microvolt = <1800000>;
248248
regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
249-
regulator-boot-on;
250249
};
251250

252251
vreg_l14a_1p88: ldo14 {

arch/arm64/boot/dts/renesas/r9a09g057.dtsi

Lines changed: 11 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -201,16 +201,6 @@
201201
status = "disabled";
202202
};
203203

204-
wdt0: watchdog@11c00400 {
205-
compatible = "renesas,r9a09g057-wdt";
206-
reg = <0 0x11c00400 0 0x400>;
207-
clocks = <&cpg CPG_MOD 0x4b>, <&cpg CPG_MOD 0x4c>;
208-
clock-names = "pclk", "oscclk";
209-
resets = <&cpg 0x75>;
210-
power-domains = <&cpg>;
211-
status = "disabled";
212-
};
213-
214204
wdt1: watchdog@14400000 {
215205
compatible = "renesas,r9a09g057-wdt";
216206
reg = <0 0x14400000 0 0x400>;
@@ -221,23 +211,18 @@
221211
status = "disabled";
222212
};
223213

224-
wdt2: watchdog@13000000 {
225-
compatible = "renesas,r9a09g057-wdt";
226-
reg = <0 0x13000000 0 0x400>;
227-
clocks = <&cpg CPG_MOD 0x4f>, <&cpg CPG_MOD 0x50>;
228-
clock-names = "pclk", "oscclk";
229-
resets = <&cpg 0x77>;
230-
power-domains = <&cpg>;
231-
status = "disabled";
232-
};
233-
234-
wdt3: watchdog@13000400 {
235-
compatible = "renesas,r9a09g057-wdt";
236-
reg = <0 0x13000400 0 0x400>;
237-
clocks = <&cpg CPG_MOD 0x51>, <&cpg CPG_MOD 0x52>;
238-
clock-names = "pclk", "oscclk";
239-
resets = <&cpg 0x78>;
214+
rtc: rtc@11c00800 {
215+
compatible = "renesas,r9a09g057-rtca3", "renesas,rz-rtca3";
216+
reg = <0 0x11c00800 0 0x400>;
217+
interrupts = <GIC_SPI 524 IRQ_TYPE_EDGE_RISING>,
218+
<GIC_SPI 525 IRQ_TYPE_EDGE_RISING>,
219+
<GIC_SPI 526 IRQ_TYPE_EDGE_RISING>;
220+
interrupt-names = "alarm", "period", "carry";
221+
clocks = <&cpg CPG_MOD 0x53>, <&rtxin_clk>;
222+
clock-names = "bus", "counter";
240223
power-domains = <&cpg>;
224+
resets = <&cpg 0x79>, <&cpg 0x7a>;
225+
reset-names = "rtc", "rtest";
241226
status = "disabled";
242227
};
243228

arch/arm64/include/asm/pgtable-prot.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,11 @@
5252

5353
#define _PAGE_DEFAULT (_PROT_DEFAULT | PTE_ATTRINDX(MT_NORMAL))
5454

55-
#define _PAGE_KERNEL (PROT_NORMAL)
56-
#define _PAGE_KERNEL_RO ((PROT_NORMAL & ~PTE_WRITE) | PTE_RDONLY)
57-
#define _PAGE_KERNEL_ROX ((PROT_NORMAL & ~(PTE_WRITE | PTE_PXN)) | PTE_RDONLY)
58-
#define _PAGE_KERNEL_EXEC (PROT_NORMAL & ~PTE_PXN)
59-
#define _PAGE_KERNEL_EXEC_CONT ((PROT_NORMAL & ~PTE_PXN) | PTE_CONT)
55+
#define _PAGE_KERNEL (PROT_NORMAL | PTE_DIRTY)
56+
#define _PAGE_KERNEL_RO ((PROT_NORMAL & ~PTE_WRITE) | PTE_RDONLY | PTE_DIRTY)
57+
#define _PAGE_KERNEL_ROX ((PROT_NORMAL & ~(PTE_WRITE | PTE_PXN)) | PTE_RDONLY | PTE_DIRTY)
58+
#define _PAGE_KERNEL_EXEC ((PROT_NORMAL & ~PTE_PXN) | PTE_DIRTY)
59+
#define _PAGE_KERNEL_EXEC_CONT ((PROT_NORMAL & ~PTE_PXN) | PTE_CONT | PTE_DIRTY)
6060

6161
#define _PAGE_SHARED (_PAGE_DEFAULT | PTE_USER | PTE_RDONLY | PTE_NG | PTE_PXN | PTE_UXN | PTE_WRITE)
6262
#define _PAGE_SHARED_EXEC (_PAGE_DEFAULT | PTE_USER | PTE_RDONLY | PTE_NG | PTE_PXN | PTE_WRITE)

arch/arm64/kernel/machine_kexec.c

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -207,37 +207,6 @@ void machine_kexec(struct kimage *kimage)
207207
BUG(); /* Should never get here. */
208208
}
209209

210-
static void machine_kexec_mask_interrupts(void)
211-
{
212-
unsigned int i;
213-
struct irq_desc *desc;
214-
215-
for_each_irq_desc(i, desc) {
216-
struct irq_chip *chip;
217-
int ret;
218-
219-
chip = irq_desc_get_chip(desc);
220-
if (!chip)
221-
continue;
222-
223-
/*
224-
* First try to remove the active state. If this
225-
* fails, try to EOI the interrupt.
226-
*/
227-
ret = irq_set_irqchip_state(i, IRQCHIP_STATE_ACTIVE, false);
228-
229-
if (ret && irqd_irq_inprogress(&desc->irq_data) &&
230-
chip->irq_eoi)
231-
chip->irq_eoi(&desc->irq_data);
232-
233-
if (chip->irq_mask)
234-
chip->irq_mask(&desc->irq_data);
235-
236-
if (chip->irq_disable && !irqd_irq_disabled(&desc->irq_data))
237-
chip->irq_disable(&desc->irq_data);
238-
}
239-
}
240-
241210
/**
242211
* machine_crash_shutdown - shutdown non-crashing cpus and save registers
243212
*/

arch/arm64/mm/contpte.c

Lines changed: 49 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -390,6 +390,27 @@ void contpte_clear_young_dirty_ptes(struct vm_area_struct *vma,
390390
}
391391
EXPORT_SYMBOL_GPL(contpte_clear_young_dirty_ptes);
392392

393+
static bool contpte_all_subptes_match_access_flags(pte_t *ptep, pte_t entry)
394+
{
395+
pte_t *cont_ptep = contpte_align_down(ptep);
396+
/*
397+
* PFNs differ per sub-PTE. Match only bits consumed by
398+
* __ptep_set_access_flags(): AF, DIRTY and write permission.
399+
*/
400+
const pteval_t cmp_mask = PTE_RDONLY | PTE_AF | PTE_WRITE | PTE_DIRTY;
401+
pteval_t entry_cmp = pte_val(entry) & cmp_mask;
402+
int i;
403+
404+
for (i = 0; i < CONT_PTES; i++) {
405+
pteval_t pte_cmp = pte_val(__ptep_get(cont_ptep + i)) & cmp_mask;
406+
407+
if (pte_cmp != entry_cmp)
408+
return false;
409+
}
410+
411+
return true;
412+
}
413+
393414
int contpte_ptep_set_access_flags(struct vm_area_struct *vma,
394415
unsigned long addr, pte_t *ptep,
395416
pte_t entry, int dirty)
@@ -399,13 +420,37 @@ int contpte_ptep_set_access_flags(struct vm_area_struct *vma,
399420
int i;
400421

401422
/*
402-
* Gather the access/dirty bits for the contiguous range. If nothing has
403-
* changed, its a noop.
423+
* Check whether all sub-PTEs in the CONT block already match the
424+
* requested access flags/write permission, using raw per-PTE values
425+
* rather than the gathered ptep_get() view.
426+
*
427+
* __ptep_set_access_flags() can update AF, dirty and write
428+
* permission, but only to make the mapping more permissive.
429+
*
430+
* ptep_get() gathers AF/dirty state across the whole CONT block,
431+
* which is correct for a CPU with FEAT_HAFDBS. But page-table
432+
* walkers that evaluate each descriptor individually (e.g. a CPU
433+
* without DBM support, or an SMMU without HTTU, or with HA/HD
434+
* disabled in CD.TCR) can keep faulting on the target sub-PTE if
435+
* only a sibling has been updated. Gathering can therefore cause
436+
* false no-ops when only a sibling has been updated:
437+
* - write faults: target still has PTE_RDONLY (needs PTE_RDONLY cleared)
438+
* - read faults: target still lacks PTE_AF
439+
*
440+
* Per Arm ARM (DDI 0487) D8.7.1, any sub-PTE in a CONT range may
441+
* become the effective cached translation, so all entries must have
442+
* consistent attributes. Check the full CONT block before returning
443+
* no-op, and when any sub-PTE mismatches, proceed to update the whole
444+
* range.
404445
*/
405-
orig_pte = pte_mknoncont(ptep_get(ptep));
406-
if (pte_val(orig_pte) == pte_val(entry))
446+
if (contpte_all_subptes_match_access_flags(ptep, entry))
407447
return 0;
408448

449+
/*
450+
* Use raw target pte (not gathered) for write-bit unfold decision.
451+
*/
452+
orig_pte = pte_mknoncont(__ptep_get(ptep));
453+
409454
/*
410455
* We can fix up access/dirty bits without having to unfold the contig
411456
* range. But if the write bit is changing, we must unfold.

arch/loongarch/include/asm/uaccess.h

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,8 +196,13 @@ do { \
196196
\
197197
__get_kernel_common(*((type *)(dst)), sizeof(type), \
198198
(__force type *)(src)); \
199-
if (unlikely(__gu_err)) \
199+
if (unlikely(__gu_err)) { \
200+
pr_info("%s: memory access failed, ecode 0x%x\n", \
201+
__func__, read_csr_excode()); \
202+
pr_info("%s: the caller is %pS\n", \
203+
__func__, __builtin_return_address(0)); \
200204
goto err_label; \
205+
} \
201206
} while (0)
202207

203208
#define __put_kernel_nofault(dst, src, type, err_label) \
@@ -207,8 +212,13 @@ do { \
207212
\
208213
__pu_val = *(__force type *)(src); \
209214
__put_kernel_common(((type *)(dst)), sizeof(type)); \
210-
if (unlikely(__pu_err)) \
215+
if (unlikely(__pu_err)) { \
216+
pr_info("%s: memory access failed, ecode 0x%x\n", \
217+
__func__, read_csr_excode()); \
218+
pr_info("%s: the caller is %pS\n", \
219+
__func__, __builtin_return_address(0)); \
211220
goto err_label; \
221+
} \
212222
} while (0)
213223

214224
extern unsigned long __copy_user(void *to, const void *from, __kernel_size_t n);

0 commit comments

Comments
 (0)