Skip to content

Commit e661f98

Browse files
committed
Merge tag 'riscv-for-linus-6.5-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux
Pull RISC-V fixes from Palmer Dabbelt: - A pair of fixes for build-related failures in the selftests - A fix for a sparse warning in acpi_os_ioremap() - A fix to restore the kernel PA offset in vmcoreinfo, to fix crash handling * tag 'riscv-for-linus-6.5-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux: Documentation: kdump: Add va_kernel_pa_offset for RISCV64 riscv: Export va_kernel_pa_offset in vmcoreinfo RISC-V: ACPI: Fix acpi_os_ioremap to return iomem address selftests: riscv: Fix compilation error with vstate_exec_nolibc.c selftests/riscv: fix potential build failure during the "emit_tests" step
2 parents ea4f142 + 640c503 commit e661f98

File tree

5 files changed

+11
-5
lines changed

5 files changed

+11
-5
lines changed

Documentation/admin-guide/kdump/vmcoreinfo.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -624,3 +624,9 @@ Used to get the correct ranges:
624624
* VMALLOC_START ~ VMALLOC_END : vmalloc() / ioremap() space.
625625
* VMEMMAP_START ~ VMEMMAP_END : vmemmap space, used for struct page array.
626626
* KERNEL_LINK_ADDR : start address of Kernel link and BPF
627+
628+
va_kernel_pa_offset
629+
-------------------
630+
631+
Indicates the offset between the kernel virtual and physical mappings.
632+
Used to translate virtual to physical addresses.

arch/riscv/include/asm/acpi.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ typedef u64 phys_cpuid_t;
1919
#define PHYS_CPUID_INVALID INVALID_HARTID
2020

2121
/* ACPI table mapping after acpi_permanent_mmap is set */
22-
void *acpi_os_ioremap(acpi_physical_address phys, acpi_size size);
22+
void __iomem *acpi_os_ioremap(acpi_physical_address phys, acpi_size size);
2323
#define acpi_os_ioremap acpi_os_ioremap
2424

2525
#define acpi_strict 1 /* No out-of-spec workarounds on RISC-V */

arch/riscv/kernel/acpi.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -215,9 +215,9 @@ void __init __acpi_unmap_table(void __iomem *map, unsigned long size)
215215
early_iounmap(map, size);
216216
}
217217

218-
void *acpi_os_ioremap(acpi_physical_address phys, acpi_size size)
218+
void __iomem *acpi_os_ioremap(acpi_physical_address phys, acpi_size size)
219219
{
220-
return memremap(phys, size, MEMREMAP_WB);
220+
return (void __iomem *)memremap(phys, size, MEMREMAP_WB);
221221
}
222222

223223
#ifdef CONFIG_PCI

arch/riscv/kernel/crash_core.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,6 @@ void arch_crash_save_vmcoreinfo(void)
1818
vmcoreinfo_append_str("NUMBER(MODULES_END)=0x%lx\n", MODULES_END);
1919
#endif
2020
vmcoreinfo_append_str("NUMBER(KERNEL_LINK_ADDR)=0x%lx\n", KERNEL_LINK_ADDR);
21+
vmcoreinfo_append_str("NUMBER(va_kernel_pa_offset)=0x%lx\n",
22+
kernel_map.va_kernel_pa_offset);
2123
}

tools/testing/selftests/riscv/vector/vstate_exec_nolibc.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
// SPDX-License-Identifier: GPL-2.0-only
2-
#include <sys/prctl.h>
3-
42
#define THIS_PROGRAM "./vstate_exec_nolibc"
53

64
int main(int argc, char **argv)

0 commit comments

Comments
 (0)