Commit 2772d7df authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'riscv-for-linus-6.5-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux

Pull RISC-V fixes from Palmer Dabbelt:

 - fix a formatting error in the hwprobe documentation

 - fix a spurious warning in the RISC-V PMU driver

 - fix memory detection on rv32 (problem does not manifest on any known
   system)

 - avoid parsing legacy parsing of I in ACPI ISA strings

* tag 'riscv-for-linus-6.5-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux:
  RISC-V: Don't include Zicsr or Zifencei in I from ACPI
  riscv: mm: fix truncation warning on RV32
  perf: RISC-V: Remove PERF_HES_STOPPED flag checking in riscv_pmu_start()
  Documentation: RISC-V: hwprobe: Fix a formatting error
parents bde7f150 ab2dbc7a
...@@ -49,7 +49,7 @@ The following keys are defined: ...@@ -49,7 +49,7 @@ The following keys are defined:
privileged ISA, with the following known exceptions (more exceptions may be privileged ISA, with the following known exceptions (more exceptions may be
added, but only if it can be demonstrated that the user ABI is not broken): added, but only if it can be demonstrated that the user ABI is not broken):
* The :fence.i: instruction cannot be directly executed by userspace * The ``fence.i`` instruction cannot be directly executed by userspace
programs (it may still be executed in userspace via a programs (it may still be executed in userspace via a
kernel-controlled mechanism such as the vDSO). kernel-controlled mechanism such as the vDSO).
......
...@@ -317,19 +317,14 @@ void __init riscv_fill_hwcap(void) ...@@ -317,19 +317,14 @@ void __init riscv_fill_hwcap(void)
#undef SET_ISA_EXT_MAP #undef SET_ISA_EXT_MAP
} }
/*
* Linux requires the following extensions, so we may as well
* always set them.
*/
set_bit(RISCV_ISA_EXT_ZICSR, isainfo->isa);
set_bit(RISCV_ISA_EXT_ZIFENCEI, isainfo->isa);
/* /*
* These ones were as they were part of the base ISA when the * These ones were as they were part of the base ISA when the
* port & dt-bindings were upstreamed, and so can be set * port & dt-bindings were upstreamed, and so can be set
* unconditionally where `i` is in riscv,isa on DT systems. * unconditionally where `i` is in riscv,isa on DT systems.
*/ */
if (acpi_disabled) { if (acpi_disabled) {
set_bit(RISCV_ISA_EXT_ZICSR, isainfo->isa);
set_bit(RISCV_ISA_EXT_ZIFENCEI, isainfo->isa);
set_bit(RISCV_ISA_EXT_ZICNTR, isainfo->isa); set_bit(RISCV_ISA_EXT_ZICNTR, isainfo->isa);
set_bit(RISCV_ISA_EXT_ZIHPM, isainfo->isa); set_bit(RISCV_ISA_EXT_ZIHPM, isainfo->isa);
} }
......
...@@ -1346,7 +1346,7 @@ static void __init reserve_crashkernel(void) ...@@ -1346,7 +1346,7 @@ static void __init reserve_crashkernel(void)
*/ */
crash_base = memblock_phys_alloc_range(crash_size, PMD_SIZE, crash_base = memblock_phys_alloc_range(crash_size, PMD_SIZE,
search_start, search_start,
min(search_end, (unsigned long) SZ_4G)); min(search_end, (unsigned long)(SZ_4G - 1)));
if (crash_base == 0) { if (crash_base == 0) {
/* Try again without restricting region to 32bit addressible memory */ /* Try again without restricting region to 32bit addressible memory */
crash_base = memblock_phys_alloc_range(crash_size, PMD_SIZE, crash_base = memblock_phys_alloc_range(crash_size, PMD_SIZE,
......
...@@ -181,9 +181,6 @@ void riscv_pmu_start(struct perf_event *event, int flags) ...@@ -181,9 +181,6 @@ void riscv_pmu_start(struct perf_event *event, int flags)
uint64_t max_period = riscv_pmu_ctr_get_width_mask(event); uint64_t max_period = riscv_pmu_ctr_get_width_mask(event);
u64 init_val; u64 init_val;
if (WARN_ON_ONCE(!(event->hw.state & PERF_HES_STOPPED)))
return;
if (flags & PERF_EF_RELOAD) if (flags & PERF_EF_RELOAD)
WARN_ON_ONCE(!(event->hw.state & PERF_HES_UPTODATE)); WARN_ON_ONCE(!(event->hw.state & PERF_HES_UPTODATE));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment