Skip to content

Commit 85140a1

Browse files
author
CKI KWF Bot
committed
Merge: update ACPI to v6.15
MR: https://gitlab.com/redhat/centos-stream/src/kernel/centos-stream-10/-/merge_requests/880 JIRA: https://issues.redhat.com/browse/RHEL-82670 JIRA: https://issues.redhat.com/browse/RHEL-89362 Omitted-fix: 0674188 (Fix applies to LoongArch, which is not supported.) Updates ACPI to v6.15, including the v6.14 commits. Signed-off-by: Mark Langsdorf <mlangsdo@redhat.com> Approved-by: John W. Linville <linville@redhat.com> Approved-by: Steve Best <sbest@redhat.com> Approved-by: Rafael Aquini <raquini@redhat.com> Approved-by: Jarod Wilson <jarod@redhat.com> Approved-by: CKI KWF Bot <cki-ci-bot+kwf-gitlab-com@redhat.com> Merged-by: CKI GitLab Kmaint Pipeline Bot <26919896-cki-kmaint-pipeline-bot@users.noreply.gitlab.com>
2 parents ebfdf60 + 8afacb1 commit 85140a1

File tree

115 files changed

+2265
-1300
lines changed

Some content is hidden

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

115 files changed

+2265
-1300
lines changed

Documentation/ABI/stable/sysfs-devices-node

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,12 @@ Description:
177177
The cache write policy: 0 for write-back, 1 for write-through,
178178
other or unknown.
179179

180+
What: /sys/devices/system/node/nodeX/memory_side_cache/indexY/address_mode
181+
Date: March 2025
182+
Contact: Dave Jiang <dave.jiang@intel.com>
183+
Description:
184+
The address mode: 0 for reserved, 1 for extended-linear.
185+
180186
What: /sys/devices/system/node/nodeX/x86/sgx_total_bytes
181187
Date: November 2021
182188
Contact: Jarkko Sakkinen <jarkko@kernel.org>

Documentation/arch/arm64/silicon-errata.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,8 +258,9 @@ stable kernels.
258258
+----------------+-----------------+-----------------+-----------------------------+
259259
| Hisilicon | Hip08 SMMU PMCG | #162001800 | N/A |
260260
+----------------+-----------------+-----------------+-----------------------------+
261-
| Hisilicon | Hip{08,09,10,10C| #162001900 | N/A |
262-
| | ,11} SMMU PMCG | | |
261+
| Hisilicon | Hip{08,09,09A,10| #162001900 | N/A |
262+
| | ,10C,11} | | |
263+
| | SMMU PMCG | | |
263264
+----------------+-----------------+-----------------+-----------------------------+
264265
| Hisilicon | Hip09 | #162100801 | HISILICON_ERRATUM_162100801 |
265266
+----------------+-----------------+-----------------+-----------------------------+

arch/powerpc/platforms/cell/axon_msi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ static void axon_msi_cascade(struct irq_desc *desc)
112112
pr_devel("axon_msi: woff %x roff %x msi %x\n",
113113
write_offset, msic->read_offset, msi);
114114

115-
if (msi < nr_irqs && irq_get_chip_data(msi) == msic) {
115+
if (msi < irq_get_nr_irqs() && irq_get_chip_data(msi) == msic) {
116116
generic_handle_irq(msi);
117117
msic->fifo_virt[idx] = cpu_to_le32(0xffffffff);
118118
} else {

arch/s390/kernel/irq.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ int show_interrupts(struct seq_file *p, void *v)
257257
seq_putc(p, '\n');
258258
goto out;
259259
}
260-
if (index < nr_irqs) {
260+
if (index < irq_get_nr_irqs()) {
261261
show_msi_interrupt(p, index);
262262
goto out;
263263
}

arch/x86/include/asm/cpuid.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ enum cpuid_regs_idx {
2020
};
2121

2222
#define CPUID_TSC_LEAF 0x15
23+
#define CPUID_MWAIT_LEAF 5
2324

2425
#ifdef CONFIG_X86_32
2526
extern int have_cpuid_p(void);

arch/x86/include/asm/mwait.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
#define MWAIT_HINT2SUBSTATE(hint) ((hint) & MWAIT_CSTATE_MASK)
1616
#define MWAIT_C1_SUBSTATE_MASK 0xf0
1717

18-
#define CPUID_MWAIT_LEAF 5
1918
#define CPUID5_ECX_EXTENSIONS_SUPPORTED 0x1
2019
#define CPUID5_ECX_INTERRUPT_BREAK 0x2
2120

arch/x86/include/asm/smp.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,7 @@ void wbinvd_on_cpu(int cpu);
114114
int wbinvd_on_all_cpus(void);
115115

116116
void smp_kick_mwait_play_dead(void);
117+
void __noreturn mwait_play_dead(unsigned int eax_hint);
117118

118119
void native_smp_send_reschedule(int cpu);
119120
void native_send_call_func_ipi(const struct cpumask *mask);
@@ -164,6 +165,8 @@ static inline struct cpumask *cpu_llc_shared_mask(int cpu)
164165
{
165166
return (struct cpumask *)cpumask_of(0);
166167
}
168+
169+
static inline void __noreturn mwait_play_dead(unsigned int eax_hint) { BUG(); }
167170
#endif /* CONFIG_SMP */
168171

169172
#ifdef CONFIG_DEBUG_NMI_SELFTEST

arch/x86/kernel/acpi/boot.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1171,7 +1171,8 @@ static int __init acpi_parse_madt_ioapic_entries(void)
11711171
}
11721172

11731173
count = acpi_table_parse_madt(ACPI_MADT_TYPE_INTERRUPT_OVERRIDE,
1174-
acpi_parse_int_src_ovr, nr_irqs);
1174+
acpi_parse_int_src_ovr,
1175+
irq_get_nr_irqs());
11751176
if (count < 0) {
11761177
pr_err("Error parsing interrupt source overrides entry\n");
11771178
/* TBD: Cleanup to allow fallback to MPS */
@@ -1191,7 +1192,8 @@ static int __init acpi_parse_madt_ioapic_entries(void)
11911192
mp_config_acpi_legacy_irqs();
11921193

11931194
count = acpi_table_parse_madt(ACPI_MADT_TYPE_NMI_SOURCE,
1194-
acpi_parse_nmi_src, nr_irqs);
1195+
acpi_parse_nmi_src,
1196+
irq_get_nr_irqs());
11951197
if (count < 0) {
11961198
pr_err("Error parsing NMI SRC entry\n");
11971199
/* TBD: Cleanup to allow fallback to MPS */

arch/x86/kernel/acpi/cstate.c

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,10 @@
1313
#include <linux/sched.h>
1414

1515
#include <acpi/processor.h>
16+
#include <asm/cpuid.h>
1617
#include <asm/mwait.h>
1718
#include <asm/special_insns.h>
19+
#include <asm/smp.h>
1820

1921
/*
2022
* Initialize bm_flags based on the CPU cache properties
@@ -204,6 +206,16 @@ int acpi_processor_ffh_cstate_probe(unsigned int cpu,
204206
}
205207
EXPORT_SYMBOL_GPL(acpi_processor_ffh_cstate_probe);
206208

209+
void __noreturn acpi_processor_ffh_play_dead(struct acpi_processor_cx *cx)
210+
{
211+
unsigned int cpu = smp_processor_id();
212+
struct cstate_entry *percpu_entry;
213+
214+
percpu_entry = per_cpu_ptr(cpu_cstate_entry, cpu);
215+
mwait_play_dead(percpu_entry->states[cx->index].eax);
216+
}
217+
EXPORT_SYMBOL_GPL(acpi_processor_ffh_play_dead);
218+
207219
void __cpuidle acpi_processor_ffh_cstate_enter(struct acpi_processor_cx *cx)
208220
{
209221
unsigned int cpu = smp_processor_id();

arch/x86/kernel/acpi/madt_wakeup.c

Lines changed: 15 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -70,58 +70,6 @@ static void __init free_pgt_page(void *pgt, void *dummy)
7070
return memblock_free(pgt, PAGE_SIZE);
7171
}
7272

73-
/*
74-
* Make sure asm_acpi_mp_play_dead() is present in the identity mapping at
75-
* the same place as in the kernel page tables. asm_acpi_mp_play_dead() switches
76-
* to the identity mapping and the function has be present at the same spot in
77-
* the virtual address space before and after switching page tables.
78-
*/
79-
static int __init init_transition_pgtable(pgd_t *pgd)
80-
{
81-
pgprot_t prot = PAGE_KERNEL_EXEC_NOENC;
82-
unsigned long vaddr, paddr;
83-
p4d_t *p4d;
84-
pud_t *pud;
85-
pmd_t *pmd;
86-
pte_t *pte;
87-
88-
vaddr = (unsigned long)asm_acpi_mp_play_dead;
89-
pgd += pgd_index(vaddr);
90-
if (!pgd_present(*pgd)) {
91-
p4d = (p4d_t *)alloc_pgt_page(NULL);
92-
if (!p4d)
93-
return -ENOMEM;
94-
set_pgd(pgd, __pgd(__pa(p4d) | _KERNPG_TABLE));
95-
}
96-
p4d = p4d_offset(pgd, vaddr);
97-
if (!p4d_present(*p4d)) {
98-
pud = (pud_t *)alloc_pgt_page(NULL);
99-
if (!pud)
100-
return -ENOMEM;
101-
set_p4d(p4d, __p4d(__pa(pud) | _KERNPG_TABLE));
102-
}
103-
pud = pud_offset(p4d, vaddr);
104-
if (!pud_present(*pud)) {
105-
pmd = (pmd_t *)alloc_pgt_page(NULL);
106-
if (!pmd)
107-
return -ENOMEM;
108-
set_pud(pud, __pud(__pa(pmd) | _KERNPG_TABLE));
109-
}
110-
pmd = pmd_offset(pud, vaddr);
111-
if (!pmd_present(*pmd)) {
112-
pte = (pte_t *)alloc_pgt_page(NULL);
113-
if (!pte)
114-
return -ENOMEM;
115-
set_pmd(pmd, __pmd(__pa(pte) | _KERNPG_TABLE));
116-
}
117-
pte = pte_offset_kernel(pmd, vaddr);
118-
119-
paddr = __pa(vaddr);
120-
set_pte(pte, pfn_pte(paddr >> PAGE_SHIFT, prot));
121-
122-
return 0;
123-
}
124-
12573
static int __init acpi_mp_setup_reset(u64 reset_vector)
12674
{
12775
struct x86_mapping_info info = {
@@ -130,15 +78,14 @@ static int __init acpi_mp_setup_reset(u64 reset_vector)
13078
.page_flag = __PAGE_KERNEL_LARGE_EXEC,
13179
.kernpg_flag = _KERNPG_TABLE_NOENC,
13280
};
81+
unsigned long mstart, mend;
13382
pgd_t *pgd;
13483

13584
pgd = alloc_pgt_page(NULL);
13685
if (!pgd)
13786
return -ENOMEM;
13887

13988
for (int i = 0; i < nr_pfn_mapped; i++) {
140-
unsigned long mstart, mend;
141-
14289
mstart = pfn_mapped[i].start << PAGE_SHIFT;
14390
mend = pfn_mapped[i].end << PAGE_SHIFT;
14491
if (kernel_ident_mapping_init(&info, pgd, mstart, mend)) {
@@ -147,14 +94,24 @@ static int __init acpi_mp_setup_reset(u64 reset_vector)
14794
}
14895
}
14996

150-
if (kernel_ident_mapping_init(&info, pgd,
151-
PAGE_ALIGN_DOWN(reset_vector),
152-
PAGE_ALIGN(reset_vector + 1))) {
97+
mstart = PAGE_ALIGN_DOWN(reset_vector);
98+
mend = mstart + PAGE_SIZE;
99+
if (kernel_ident_mapping_init(&info, pgd, mstart, mend)) {
153100
kernel_ident_mapping_free(&info, pgd);
154101
return -ENOMEM;
155102
}
156103

157-
if (init_transition_pgtable(pgd)) {
104+
/*
105+
* Make sure asm_acpi_mp_play_dead() is present in the identity mapping
106+
* at the same place as in the kernel page tables.
107+
* asm_acpi_mp_play_dead() switches to the identity mapping and the
108+
* function must be present at the same spot in the virtual address space
109+
* before and after switching page tables.
110+
*/
111+
info.offset = __START_KERNEL_map - phys_base;
112+
mstart = PAGE_ALIGN_DOWN(__pa(asm_acpi_mp_play_dead));
113+
mend = mstart + PAGE_SIZE;
114+
if (kernel_ident_mapping_init(&info, pgd, mstart, mend)) {
158115
kernel_ident_mapping_free(&info, pgd);
159116
return -ENOMEM;
160117
}

0 commit comments

Comments
 (0)