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

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

Pull more RISC-V updates from Palmer Dabbelt:

 - Kconfig select statements are now sorted alphanumerically

 - first-level interrupts are now handled via a full irqchip driver

 - CPU hotplug is fixed

 - vDSO calls now use the common vDSO infrastructure

* tag 'riscv-for-linus-5.8-mw1' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux:
  riscv: set the permission of vdso_data to read-only
  riscv: use vDSO common flow to reduce the latency of the time-related functions
  riscv: fix build warning of missing prototypes
  RISC-V: Don't mark init section as non-executable
  RISC-V: Force select RISCV_INTC for CONFIG_RISCV
  RISC-V: Remove do_IRQ() function
  clocksource/drivers/timer-riscv: Use per-CPU timer interrupt
  irqchip: RISC-V per-HART local interrupt controller driver
  RISC-V: Rename and move plic_find_hart_id() to arch directory
  RISC-V: self-contained IPI handling routine
  RISC-V: Sort select statements alphanumerically
parents 55d728b2 01f76386
Loading
Loading
Loading
Loading
+40 −34
Original line number Diff line number Diff line
@@ -12,64 +12,70 @@ config 32BIT

config RISCV
	def_bool y
	select OF
	select OF_EARLY_FLATTREE
	select OF_IRQ
	select ARCH_CLOCKSOURCE_INIT
	select ARCH_HAS_BINFMT_FLAT
	select ARCH_HAS_DEBUG_VIRTUAL if MMU
	select ARCH_HAS_DEBUG_WX
	select ARCH_HAS_GCOV_PROFILE_ALL
	select ARCH_HAS_GIGANTIC_PAGE
	select ARCH_HAS_MMIOWB
	select ARCH_HAS_PTE_SPECIAL
	select ARCH_HAS_SET_DIRECT_MAP
	select ARCH_HAS_SET_MEMORY
	select ARCH_HAS_STRICT_KERNEL_RWX if MMU
	select ARCH_WANT_DEFAULT_TOPDOWN_MMAP_LAYOUT if MMU
	select ARCH_WANT_FRAME_POINTERS
	select ARCH_WANT_HUGE_PMD_SHARE if 64BIT
	select CLONE_BACKWARDS
	select COMMON_CLK
	select EDAC_SUPPORT
	select GENERIC_ARCH_TOPOLOGY if SMP
	select GENERIC_ATOMIC64 if !64BIT
	select GENERIC_CLOCKEVENTS
	select GENERIC_GETTIMEOFDAY if HAVE_GENERIC_VDSO
	select GENERIC_IOREMAP
	select GENERIC_IRQ_MULTI_HANDLER
	select GENERIC_IRQ_SHOW
	select GENERIC_PCI_IOMAP
	select GENERIC_PTDUMP if MMU
	select GENERIC_SCHED_CLOCK
	select GENERIC_SMP_IDLE_THREAD
	select GENERIC_STRNCPY_FROM_USER if MMU
	select GENERIC_STRNLEN_USER if MMU
	select GENERIC_SMP_IDLE_THREAD
	select GENERIC_ATOMIC64 if !64BIT
	select GENERIC_IOREMAP
	select GENERIC_PTDUMP if MMU
	select GENERIC_TIME_VSYSCALL if MMU && 64BIT
	select HANDLE_DOMAIN_IRQ
	select HAVE_ARCH_AUDITSYSCALL
	select HAVE_ARCH_KASAN if MMU && 64BIT
	select HAVE_ARCH_KGDB
	select HAVE_ARCH_KGDB_QXFER_PKT
	select HAVE_ARCH_MMAP_RND_BITS if MMU
	select HAVE_ARCH_SECCOMP_FILTER
	select HAVE_ARCH_TRACEHOOK
	select HAVE_ASM_MODVERSIONS
	select HAVE_COPY_THREAD_TLS
	select HAVE_DMA_CONTIGUOUS if MMU
	select HAVE_EBPF_JIT if MMU
	select HAVE_FUTEX_CMPXCHG if FUTEX
	select HAVE_GENERIC_VDSO if MMU && 64BIT
	select HAVE_PCI
	select HAVE_PERF_EVENTS
	select HAVE_PERF_REGS
	select HAVE_PERF_USER_STACK_DUMP
	select HAVE_SYSCALL_TRACEPOINTS
	select IRQ_DOMAIN
	select SPARSE_IRQ
	select SYSCTL_EXCEPTION_TRACE
	select HAVE_ARCH_TRACEHOOK
	select HAVE_PCI
	select MODULES_USE_ELF_RELA if MODULES
	select MODULE_SECTIONS if MODULES
	select THREAD_INFO_IN_TASK
	select OF
	select OF_EARLY_FLATTREE
	select OF_IRQ
	select PCI_DOMAINS_GENERIC if PCI
	select PCI_MSI if PCI
	select RISCV_INTC
	select RISCV_TIMER
	select GENERIC_IRQ_MULTI_HANDLER
	select GENERIC_ARCH_TOPOLOGY if SMP
	select ARCH_HAS_PTE_SPECIAL
	select ARCH_HAS_MMIOWB
	select ARCH_HAS_DEBUG_VIRTUAL if MMU
	select HAVE_EBPF_JIT if MMU
	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 if MMU
	select ARCH_WANT_HUGE_PMD_SHARE if 64BIT
	select SPARSEMEM_STATIC if 32BIT
	select ARCH_WANT_DEFAULT_TOPDOWN_MMAP_LAYOUT if MMU
	select HAVE_ARCH_MMAP_RND_BITS if MMU
	select ARCH_HAS_GCOV_PROFILE_ALL
	select HAVE_COPY_THREAD_TLS
	select HAVE_ARCH_KASAN if MMU && 64BIT
	select HAVE_ARCH_KGDB
	select HAVE_ARCH_KGDB_QXFER_PKT
	select SPARSE_IRQ
	select SYSCTL_EXCEPTION_TRACE
	select THREAD_INFO_IN_TASK

config ARCH_MMAP_RND_BITS_MIN
	default 18 if 64BIT
@@ -196,11 +202,11 @@ config ARCH_RV64I
	bool "RV64I"
	select 64BIT
	select ARCH_SUPPORTS_INT128 if CC_HAS_INT128 && GCC_VERSION >= 50000
	select HAVE_FUNCTION_TRACER
	select HAVE_FUNCTION_GRAPH_TRACER
	select HAVE_FTRACE_MCOUNT_RECORD
	select HAVE_DYNAMIC_FTRACE if MMU
	select HAVE_DYNAMIC_FTRACE_WITH_REGS if HAVE_DYNAMIC_FTRACE
	select HAVE_FTRACE_MCOUNT_RECORD
	select HAVE_FUNCTION_GRAPH_TRACER
	select HAVE_FUNCTION_TRACER
	select SWIOTLB if MMU

endchoice
+7 −0
Original line number Diff line number Diff line
/* SPDX-License-Identifier: GPL-2.0 */
#ifndef _ASM_CLOCKSOURCE_H
#define _ASM_CLOCKSOURCE_H

#include <asm/vdso/clocksource.h>

#endif
+0 −5
Original line number Diff line number Diff line
@@ -10,11 +10,6 @@
#include <linux/interrupt.h>
#include <linux/linkage.h>

#define NR_IRQS         0

void riscv_timer_interrupt(void);
void riscv_software_interrupt(void);

#include <asm-generic/irq.h>

#endif /* _ASM_RISCV_IRQ_H */
+3 −10
Original line number Diff line number Diff line
@@ -8,6 +8,8 @@

#include <linux/const.h>

#include <vdso/processor.h>

#include <asm/ptrace.h>

/*
@@ -58,16 +60,6 @@ static inline void release_thread(struct task_struct *dead_task)
extern unsigned long get_wchan(struct task_struct *p);


static inline void cpu_relax(void)
{
#ifdef __riscv_muldiv
	int dummy;
	/* In lieu of a halt instruction, induce a long-latency stall. */
	__asm__ __volatile__ ("div %0, %0, zero" : "=r" (dummy));
#endif
	barrier();
}

static inline void wait_for_interrupt(void)
{
	__asm__ __volatile__ ("wfi");
@@ -75,6 +67,7 @@ static inline void wait_for_interrupt(void)

struct device_node;
int riscv_of_processor_hartid(struct device_node *node);
int riscv_of_parent_hartid(struct device_node *node);

extern void riscv_fill_hwcap(void);

+3 −0
Original line number Diff line number Diff line
@@ -28,6 +28,9 @@ void show_ipi_stats(struct seq_file *p, int prec);
/* SMP initialization hook for setup_arch */
void __init setup_smp(void);

/* Called from C code, this handles an IPI. */
void handle_IPI(struct pt_regs *regs);

/* Hook for the generic smp_call_function_many() routine. */
void arch_send_call_function_ipi_mask(struct cpumask *mask);

Loading