Commit cb7e3669 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

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

Pull RISC-V updates from Paul Walmsley

 - Replacement of __ASSEMBLY__ with __ASSEMBLER__ in header files (other
   architectures have already merged this type of cleanup)

 - The introduction of ioremap_wc() for RISC-V

 - Cleanup of the RISC-V kprobes code to use mostly-extant macros rather
   than open code

 - A RISC-V kprobes unit test

 - An architecture-specific endianness swap macro set implementation,
   leveraging some dedicated RISC-V instructions for this purpose if
   they are available

 - The ability to identity and communicate to userspace the presence
   of a MIPS P8700-specific ISA extension, and to leverage its
   MIPS-specific PAUSE implementation in cpu_relax()

 - Several other miscellaneous cleanups

* tag 'riscv-for-linus-6.18-mw1' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux: (39 commits)
  riscv: errata: Fix the PAUSE Opcode for MIPS P8700
  riscv: hwprobe: Document MIPS xmipsexectl vendor extension
  riscv: hwprobe: Add MIPS vendor extension probing
  riscv: Add xmipsexectl instructions
  riscv: Add xmipsexectl as a vendor extension
  dt-bindings: riscv: Add xmipsexectl ISA extension description
  riscv: cpufeature: add validation for zfa, zfh and zfhmin
  perf: riscv: skip empty batches in counter start
  selftests: riscv: Add README for RISC-V KSelfTest
  riscv: sbi: Switch to new sys-off handler API
  riscv: Move vendor errata definitions to new header
  RISC-V: ACPI: enable parsing the BGRT table
  riscv: Enable ARCH_HAVE_NMI_SAFE_CMPXCHG
  riscv: pi: use 'targets' instead of extra-y in Makefile
  riscv: introduce asm/swab.h
  riscv: mmap(): use unsigned offset type in riscv_sys_mmap
  drivers/perf: riscv: Remove redundant ternary operators
  riscv: mm: Use mmu-type from FDT to limit SATP mode
  riscv: mm: Return intended SATP mode for noXlvl options
  riscv: kprobes: Remove duplication of RV_EXTRACT_ITYPE_IMM
  ...
parents feafee28 0b0ca959
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -327,6 +327,15 @@ The following keys are defined:
  * :c:macro:`RISCV_HWPROBE_MISALIGNED_VECTOR_UNSUPPORTED`: Misaligned vector accesses are
    not supported at all and will generate a misaligned address fault.

* :c:macro:`RISCV_HWPROBE_KEY_VENDOR_EXT_MIPS_0`: A bitmask containing the
  mips vendor extensions that are compatible with the
  :c:macro:`RISCV_HWPROBE_BASE_BEHAVIOR_IMA`: base system behavior.

  * MIPS

    * :c:macro:`RISCV_HWPROBE_VENDOR_EXT_XMIPSEXECTL`: The xmipsexectl vendor
        extension is supported in the MIPS ISA extensions spec.

* :c:macro:`RISCV_HWPROBE_KEY_VENDOR_EXT_THEAD_0`: A bitmask containing the
  thead vendor extensions that are compatible with the
  :c:macro:`RISCV_HWPROBE_BASE_BEHAVIOR_IMA`: base system behavior.
+6 −0
Original line number Diff line number Diff line
@@ -662,6 +662,12 @@ properties:
            Registers in the AX45MP datasheet.
            https://www.andestech.com/wp-content/uploads/AX45MP-1C-Rev.-5.0.0-Datasheet.pdf

        # MIPS
        - const: xmipsexectl
          description:
            The MIPS extension for execution control as documented in
            https://mips.com/wp-content/uploads/2025/06/P8700_Programmers_Reference_Manual_Rev1.84_5-31-2025.pdf

        # SiFive
        - const: xsfvqmaccdod
          description:
+1 −0
Original line number Diff line number Diff line
@@ -54,6 +54,7 @@ config RISCV
	select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST
	select ARCH_HAS_UBSAN
	select ARCH_HAS_VDSO_ARCH_DATA if GENERIC_VDSO_DATA_STORE
	select ARCH_HAVE_NMI_SAFE_CMPXCHG
	select ARCH_KEEP_MEMBLOCK if ACPI
	select ARCH_MHP_MEMMAP_ON_MEMORY_ENABLE	if 64BIT && MMU
	select ARCH_OPTIONAL_KERNEL_RWX if ARCH_HAS_STRICT_KERNEL_RWX
+23 −0
Original line number Diff line number Diff line
@@ -21,6 +21,29 @@ config ERRATA_ANDES_CMO

	  If you don't know what to do here, say "Y".

config ERRATA_MIPS
	bool "MIPS errata"
	depends on RISCV_ALTERNATIVE
	help
	  All MIPS errata Kconfig depend on this Kconfig. Disabling
	  this Kconfig will disable all MIPS errata. Please say "Y"
	  here if your platform uses MIPS CPU cores.

	  Otherwise, please say "N" here to avoid unnecessary overhead.

config ERRATA_MIPS_P8700_PAUSE_OPCODE
	bool "Fix the PAUSE Opcode for MIPS P8700"
	depends on ERRATA_MIPS && 64BIT
	default n
	help
	   The RISCV MIPS P8700 uses a different opcode for PAUSE.
	   It is a 'hint' encoding of the SLLI instruction,
	   with rd=0, rs1=0 and imm=5. It will behave as a NOP
	   instruction if no additional behavior beyond that of
	   SLLI is implemented.

	   If you are not using the P8700 processor, say n.

config ERRATA_SIFIVE
	bool "SiFive errata"
	depends on RISCV_ALTERNATIVE
+13 −0
Original line number Diff line number Diff line
@@ -16,6 +16,19 @@ config RISCV_ISA_VENDOR_EXT_ANDES
	  If you don't know what to do here, say Y.
endmenu

menu "MIPS"
config RISCV_ISA_VENDOR_EXT_MIPS
	bool "MIPS vendor extension support"
	select RISCV_ISA_VENDOR_EXT
	default y
	help
	  Say N here to disable detection of and support for all MIPS vendor
	  extensions. Without this option enabled, MIPS vendor extensions will
	  not be detected at boot and their presence not reported to userspace.

	  If you don't know what to do here, say Y.
endmenu

menu "SiFive"
config RISCV_ISA_VENDOR_EXT_SIFIVE
	bool "SiFive vendor extension support"
Loading