Commit eab40026 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull RISC-V updates from Palmer Dabbelt:
 "This contains a handful of new features:

   - Partial support for the Kendryte K210.

     There are still a few outstanding issues that I have patches for,
     but I don't actually have a board to test them so they're not
     included yet.

   - SBI v0.2 support.

   - Fixes to support for building with LLVM-based toolchains. The
     resulting images are known not to boot yet.

  I don't anticipate a part two, but I'll probably have something early
  in the RCs to finish up the K210 support"

* tag 'riscv-for-linus-5.7' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux: (38 commits)
  riscv: create a loader.bin boot image for Kendryte SoC
  riscv: Kendryte K210 default config
  riscv: Add Kendryte K210 device tree
  riscv: Select required drivers for Kendryte SOC
  riscv: Add Kendryte K210 SoC support
  riscv: Add SOC early init support
  riscv: Unaligned load/store handling for M_MODE
  RISC-V: Support cpu hotplug
  RISC-V: Add supported for ordered booting method using HSM
  RISC-V: Add SBI HSM extension definitions
  RISC-V: Export SBI error to linux error mapping function
  RISC-V: Add cpu_ops and modify default booting method
  RISC-V: Move relocate and few other functions out of __init
  RISC-V: Implement new SBI v0.2 extensions
  RISC-V: Introduce a new config for SBI v0.1
  RISC-V: Add SBI v0.2 extension definitions
  RISC-V: Add basic support for SBI v0.2
  RISC-V: Mark existing SBI as 0.1 SBI.
  riscv: Use macro definition instead of magic number
  riscv: Add support to dump the kernel page tables
  ...
parents 5d30bcac 37809df4
Loading
Loading
Loading
Loading
+25 −1
Original line number Diff line number Diff line
@@ -20,7 +20,6 @@ config RISCV
	select CLONE_BACKWARDS
	select COMMON_CLK
	select GENERIC_CLOCKEVENTS
	select GENERIC_CPU_DEVICES
	select GENERIC_IRQ_SHOW
	select GENERIC_PCI_IOMAP
	select GENERIC_SCHED_CLOCK
@@ -29,6 +28,7 @@ config RISCV
	select GENERIC_SMP_IDLE_THREAD
	select GENERIC_ATOMIC64 if !64BIT
	select GENERIC_IOREMAP
	select GENERIC_PTDUMP if MMU
	select HAVE_ARCH_AUDITSYSCALL
	select HAVE_ARCH_SECCOMP_FILTER
	select HAVE_ASM_MODVERSIONS
@@ -58,6 +58,9 @@ config RISCV
	select HAVE_EBPF_JIT
	select EDAC_SUPPORT
	select ARCH_HAS_GIGANTIC_PAGE
	select ARCH_HAS_SET_DIRECT_MAP
	select ARCH_HAS_SET_MEMORY
	select ARCH_HAS_STRICT_KERNEL_RWX
	select ARCH_WANT_HUGE_PMD_SHARE if 64BIT
	select SPARSEMEM_STATIC if 32BIT
	select ARCH_WANT_DEFAULT_TOPDOWN_MMAP_LAYOUT if MMU
@@ -129,6 +132,9 @@ config ARCH_SELECT_MEMORY_MODEL
config ARCH_WANT_GENERAL_HUGETLB
	def_bool y

config ARCH_SUPPORTS_DEBUG_PAGEALLOC
	def_bool y

config SYS_SUPPORTS_HUGETLBFS
	def_bool y

@@ -247,6 +253,17 @@ config NR_CPUS
	depends on SMP
	default "8"

config HOTPLUG_CPU
	bool "Support for hot-pluggable CPUs"
	depends on SMP
	select GENERIC_IRQ_MIGRATION
	help

	  Say Y here to experiment with turning CPUs off and on.  CPUs
	  can be controlled through /sys/devices/system/cpu.

	  Say N if you want to disable CPU hotplug.

choice
	prompt "CPU Tuning"
	default TUNE_GENERIC
@@ -307,6 +324,13 @@ config SECCOMP
	  and the task is only allowed to execute a few safe syscalls
	  defined by each seccomp mode.

config RISCV_SBI_V01
	bool "SBI v0.1 support"
	default y
	depends on RISCV_SBI
	help
	  This config allows kernel to use SBI v0.1 APIs. This will be
	  deprecated in future once legacy M-mode software are no longer in use.
endmenu

menu "Boot options"
+10 −0
Original line number Diff line number Diff line
@@ -20,4 +20,14 @@ config SOC_VIRT
       help
         This enables support for QEMU Virt Machine.

config SOC_KENDRYTE
	bool "Kendryte K210 SoC"
	depends on !MMU
	select BUILTIN_DTB
	select SERIAL_SIFIVE if TTY
	select SERIAL_SIFIVE_CONSOLE if TTY
	select SIFIVE_PLIC
	help
	  This enables support for Kendryte K210 SoC platform hardware.

endmenu
+3 −3
Original line number Diff line number Diff line
@@ -85,12 +85,12 @@ PHONY += vdso_install
vdso_install:
	$(Q)$(MAKE) $(build)=arch/riscv/kernel/vdso $@

ifeq ($(CONFIG_RISCV_M_MODE),y)
KBUILD_IMAGE := $(boot)/loader
ifeq ($(CONFIG_RISCV_M_MODE)$(CONFIG_SOC_KENDRYTE),yy)
KBUILD_IMAGE := $(boot)/loader.bin
else
KBUILD_IMAGE := $(boot)/Image.gz
endif
BOOT_TARGETS := Image Image.gz loader
BOOT_TARGETS := Image Image.gz loader loader.bin

all:	$(notdir $(KBUILD_IMAGE))

+3 −0
Original line number Diff line number Diff line
@@ -41,6 +41,9 @@ $(obj)/Image.lzma: $(obj)/Image FORCE
$(obj)/Image.lzo: $(obj)/Image FORCE
	$(call if_changed,lzo)

$(obj)/loader.bin: $(obj)/loader FORCE
	$(call if_changed,objcopy)

install:
	$(CONFIG_SHELL) $(srctree)/$(src)/install.sh $(KERNELRELEASE) \
	$(obj)/Image System.map "$(INSTALL_PATH)"
+1 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0
subdir-y += sifive
subdir-y += kendryte
Loading