Skip to content

Commit fb21dd5

Browse files
committed
Merge tag 'v6.12.6' into 6.12-main
This is the 6.12.6 stable release # -----BEGIN PGP SIGNATURE----- # # iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmdkVEUACgkQONu9yGCS # aT7FYA/+OEDrmsHBVy0VShtpcrbC0O5VE/HInQ9A30sMLTbg3U3DvVi715jdSiYJ # kAfusNMS+bcFJ8b3IeYgVfJWOPD7PplMVTgOo74dht89vI2/yYAHP2+Bpf57oqB9 # c1RzPSEmQSVsk8DTzAW7eg0lgmloA0W6F6et2Cz+qLm9eisagC+cl4LCLGMC0Zcw # ILMj6tL+kIfvw1c87UF8PjXtF/UdgDeIaaX9zVl9SRi4c9Ha6Yy4zUrh2BteGeiy # LXHIrommGyDanajvWbv2BluwCVvJ/cUzwrnLfrR0Cjwxrjlbbn0WNzt1wKQO61VX # 3YVRDF+rnGKmt0s7mLBWvwlqsRQgFdjngtviH33qdHy/+J9UbhHmOuvLyuX3wCw0 # vlX9cjVQPYDv3kSpTErCtQ1WOSCO/Eb+OlpYyNEnUdaOuySZlXdl4cPJPRspjNoY # ZcqC9gREseYda3q+LfdvwN4vnPzY90LIfO5xerPf6PgRjyGRl6QUhGTc3c69neaf # vwqVhWEhp5btuj9p+sBS6ozviH49oUV7E4E/ZtMuKMGUEwLaA07HS/BiUDmE306U # 5Sv0OMllJPiZTtCb7nR2HsyQEK0jK43eD0NMLD8K3l112L4i7BF41ER1GwcaTTUz # maoJcswK422Dp1hTzODqAGvjZdFx5VGgO5m0rAINh1l2xEPtSN8= # =pkpv # -----END PGP SIGNATURE----- # gpg: Signature made Thu Dec 19 18:13:41 2024 CET # gpg: using RSA key 647F28654894E3BD457199BE38DBBDC86092693E # gpg: Can't check signature: No public key
2 parents f10abbc + e9d65b4 commit fb21dd5

File tree

182 files changed

+2197
-1291
lines changed

Some content is hidden

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

182 files changed

+2197
-1291
lines changed

Documentation/networking/ip-sysctl.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2170,6 +2170,12 @@ nexthop_compat_mode - BOOLEAN
21702170
understands the new API, this sysctl can be disabled to achieve full
21712171
performance benefits of the new API by disabling the nexthop expansion
21722172
and extraneous notifications.
2173+
2174+
Note that as a backward-compatible mode, dumping of modern features
2175+
might be incomplete or wrong. For example, resilient groups will not be
2176+
shown as such, but rather as just a list of next hops. Also weights that
2177+
do not fit into 8 bits will show incorrectly.
2178+
21732179
Default: true (backward compat mode)
21742180

21752181
fib_notify_on_flag_change - INTEGER

Documentation/power/runtime_pm.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,9 @@ drivers/base/power/runtime.c and include/linux/pm_runtime.h:
347347

348348
`int pm_runtime_resume_and_get(struct device *dev);`
349349
- run pm_runtime_resume(dev) and if successful, increment the device's
350-
usage counter; return the result of pm_runtime_resume
350+
usage counter; returns 0 on success (whether or not the device's
351+
runtime PM status was already 'active') or the error code from
352+
pm_runtime_resume() on failure.
351353

352354
`int pm_request_idle(struct device *dev);`
353355
- submit a request to execute the subsystem-level idle callback for the

Makefile

Lines changed: 1 addition & 1 deletion
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 = 5
4+
SUBLEVEL = 6
55
EXTRAVERSION =
66
NAME = Baby Opossum Posse
77

arch/arm64/kvm/sys_regs.c

Lines changed: 52 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1535,6 +1535,7 @@ static u64 __kvm_read_sanitised_id_reg(const struct kvm_vcpu *vcpu,
15351535
val &= ~ARM64_FEATURE_MASK(ID_AA64PFR1_EL1_MTEX);
15361536
val &= ~ARM64_FEATURE_MASK(ID_AA64PFR1_EL1_DF2);
15371537
val &= ~ARM64_FEATURE_MASK(ID_AA64PFR1_EL1_PFAR);
1538+
val &= ~ARM64_FEATURE_MASK(ID_AA64PFR1_EL1_MPAM_frac);
15381539
break;
15391540
case SYS_ID_AA64PFR2_EL1:
15401541
/* We only expose FPMR */
@@ -1724,6 +1725,13 @@ static u64 read_sanitised_id_aa64pfr0_el1(struct kvm_vcpu *vcpu,
17241725

17251726
val &= ~ID_AA64PFR0_EL1_AMU_MASK;
17261727

1728+
/*
1729+
* MPAM is disabled by default as KVM also needs a set of PARTID to
1730+
* program the MPAMVPMx_EL2 PARTID remapping registers with. But some
1731+
* older kernels let the guest see the ID bit.
1732+
*/
1733+
val &= ~ID_AA64PFR0_EL1_MPAM_MASK;
1734+
17271735
return val;
17281736
}
17291737

@@ -1834,6 +1842,42 @@ static int set_id_dfr0_el1(struct kvm_vcpu *vcpu,
18341842
return set_id_reg(vcpu, rd, val);
18351843
}
18361844

1845+
static int set_id_aa64pfr0_el1(struct kvm_vcpu *vcpu,
1846+
const struct sys_reg_desc *rd, u64 user_val)
1847+
{
1848+
u64 hw_val = read_sanitised_ftr_reg(SYS_ID_AA64PFR0_EL1);
1849+
u64 mpam_mask = ID_AA64PFR0_EL1_MPAM_MASK;
1850+
1851+
/*
1852+
* Commit 011e5f5bf529f ("arm64/cpufeature: Add remaining feature bits
1853+
* in ID_AA64PFR0 register") exposed the MPAM field of AA64PFR0_EL1 to
1854+
* guests, but didn't add trap handling. KVM doesn't support MPAM and
1855+
* always returns an UNDEF for these registers. The guest must see 0
1856+
* for this field.
1857+
*
1858+
* But KVM must also accept values from user-space that were provided
1859+
* by KVM. On CPUs that support MPAM, permit user-space to write
1860+
* the sanitizied value to ID_AA64PFR0_EL1.MPAM, but ignore this field.
1861+
*/
1862+
if ((hw_val & mpam_mask) == (user_val & mpam_mask))
1863+
user_val &= ~ID_AA64PFR0_EL1_MPAM_MASK;
1864+
1865+
return set_id_reg(vcpu, rd, user_val);
1866+
}
1867+
1868+
static int set_id_aa64pfr1_el1(struct kvm_vcpu *vcpu,
1869+
const struct sys_reg_desc *rd, u64 user_val)
1870+
{
1871+
u64 hw_val = read_sanitised_ftr_reg(SYS_ID_AA64PFR1_EL1);
1872+
u64 mpam_mask = ID_AA64PFR1_EL1_MPAM_frac_MASK;
1873+
1874+
/* See set_id_aa64pfr0_el1 for comment about MPAM */
1875+
if ((hw_val & mpam_mask) == (user_val & mpam_mask))
1876+
user_val &= ~ID_AA64PFR1_EL1_MPAM_frac_MASK;
1877+
1878+
return set_id_reg(vcpu, rd, user_val);
1879+
}
1880+
18371881
/*
18381882
* cpufeature ID register user accessors
18391883
*
@@ -2377,15 +2421,20 @@ static const struct sys_reg_desc sys_reg_descs[] = {
23772421
{ SYS_DESC(SYS_ID_AA64PFR0_EL1),
23782422
.access = access_id_reg,
23792423
.get_user = get_id_reg,
2380-
.set_user = set_id_reg,
2424+
.set_user = set_id_aa64pfr0_el1,
23812425
.reset = read_sanitised_id_aa64pfr0_el1,
23822426
.val = ~(ID_AA64PFR0_EL1_AMU |
23832427
ID_AA64PFR0_EL1_MPAM |
23842428
ID_AA64PFR0_EL1_SVE |
23852429
ID_AA64PFR0_EL1_RAS |
23862430
ID_AA64PFR0_EL1_AdvSIMD |
23872431
ID_AA64PFR0_EL1_FP), },
2388-
ID_WRITABLE(ID_AA64PFR1_EL1, ~(ID_AA64PFR1_EL1_PFAR |
2432+
{ SYS_DESC(SYS_ID_AA64PFR1_EL1),
2433+
.access = access_id_reg,
2434+
.get_user = get_id_reg,
2435+
.set_user = set_id_aa64pfr1_el1,
2436+
.reset = kvm_read_sanitised_id_reg,
2437+
.val = ~(ID_AA64PFR1_EL1_PFAR |
23892438
ID_AA64PFR1_EL1_DF2 |
23902439
ID_AA64PFR1_EL1_MTEX |
23912440
ID_AA64PFR1_EL1_THE |
@@ -2397,7 +2446,7 @@ static const struct sys_reg_desc sys_reg_descs[] = {
23972446
ID_AA64PFR1_EL1_RES0 |
23982447
ID_AA64PFR1_EL1_MPAM_frac |
23992448
ID_AA64PFR1_EL1_RAS_frac |
2400-
ID_AA64PFR1_EL1_MTE)),
2449+
ID_AA64PFR1_EL1_MTE), },
24012450
ID_WRITABLE(ID_AA64PFR2_EL1, ID_AA64PFR2_EL1_FPMR),
24022451
ID_UNALLOCATED(4,3),
24032452
ID_WRITABLE(ID_AA64ZFR0_EL1, ~ID_AA64ZFR0_EL1_RES0),

arch/riscv/include/asm/kfence.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ static inline bool kfence_protect_page(unsigned long addr, bool protect)
2222
else
2323
set_pte(pte, __pte(pte_val(ptep_get(pte)) | _PAGE_PRESENT));
2424

25-
flush_tlb_kernel_range(addr, addr + PAGE_SIZE);
25+
preempt_disable();
26+
local_flush_tlb_kernel_range(addr, addr + PAGE_SIZE);
27+
preempt_enable();
2628

2729
return true;
2830
}

arch/riscv/kernel/setup.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ static void __init init_resources(void)
227227
static void __init parse_dtb(void)
228228
{
229229
/* Early scan of device tree from init memory */
230-
if (early_init_dt_scan(dtb_early_va, __pa(dtb_early_va))) {
230+
if (early_init_dt_scan(dtb_early_va, dtb_early_pa)) {
231231
const char *name = of_flat_dt_get_machine_name();
232232

233233
if (name) {

arch/riscv/mm/init.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1566,7 +1566,7 @@ static void __meminit free_pte_table(pte_t *pte_start, pmd_t *pmd)
15661566
pmd_clear(pmd);
15671567
}
15681568

1569-
static void __meminit free_pmd_table(pmd_t *pmd_start, pud_t *pud)
1569+
static void __meminit free_pmd_table(pmd_t *pmd_start, pud_t *pud, bool is_vmemmap)
15701570
{
15711571
struct page *page = pud_page(*pud);
15721572
struct ptdesc *ptdesc = page_ptdesc(page);
@@ -1579,7 +1579,8 @@ static void __meminit free_pmd_table(pmd_t *pmd_start, pud_t *pud)
15791579
return;
15801580
}
15811581

1582-
pagetable_pmd_dtor(ptdesc);
1582+
if (!is_vmemmap)
1583+
pagetable_pmd_dtor(ptdesc);
15831584
if (PageReserved(page))
15841585
free_reserved_page(page);
15851586
else
@@ -1703,7 +1704,7 @@ static void __meminit remove_pud_mapping(pud_t *pud_base, unsigned long addr, un
17031704
remove_pmd_mapping(pmd_base, addr, next, is_vmemmap, altmap);
17041705

17051706
if (pgtable_l4_enabled)
1706-
free_pmd_table(pmd_base, pudp);
1707+
free_pmd_table(pmd_base, pudp, is_vmemmap);
17071708
}
17081709
}
17091710

arch/x86/events/intel/ds.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1468,7 +1468,7 @@ void intel_pmu_pebs_enable(struct perf_event *event)
14681468
* hence we need to drain when changing said
14691469
* size.
14701470
*/
1471-
intel_pmu_drain_large_pebs(cpuc);
1471+
intel_pmu_drain_pebs_buffer();
14721472
adaptive_pebs_record_size_update();
14731473
wrmsrl(MSR_PEBS_DATA_CFG, pebs_data_cfg);
14741474
cpuc->active_pebs_data_cfg = pebs_data_cfg;

arch/x86/include/asm/processor.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,8 @@ static inline unsigned long long l1tf_pfn_limit(void)
212212
return BIT_ULL(boot_cpu_data.x86_cache_bits - 1 - PAGE_SHIFT);
213213
}
214214

215+
void init_cpu_devs(void);
216+
void get_cpu_vendor(struct cpuinfo_x86 *c);
215217
extern void early_cpu_init(void);
216218
extern void identify_secondary_cpu(struct cpuinfo_x86 *);
217219
extern void print_cpu_info(struct cpuinfo_x86 *);

arch/x86/include/asm/static_call.h

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,4 +65,19 @@
6565

6666
extern bool __static_call_fixup(void *tramp, u8 op, void *dest);
6767

68+
extern void __static_call_update_early(void *tramp, void *func);
69+
70+
#define static_call_update_early(name, _func) \
71+
({ \
72+
typeof(&STATIC_CALL_TRAMP(name)) __F = (_func); \
73+
if (static_call_initialized) { \
74+
__static_call_update(&STATIC_CALL_KEY(name), \
75+
STATIC_CALL_TRAMP_ADDR(name), __F);\
76+
} else { \
77+
WRITE_ONCE(STATIC_CALL_KEY(name).func, _func); \
78+
__static_call_update_early(STATIC_CALL_TRAMP_ADDR(name),\
79+
__F); \
80+
} \
81+
})
82+
6883
#endif /* _ASM_STATIC_CALL_H */

0 commit comments

Comments
 (0)