7#ifndef ZEPHYR_INCLUDE_ARCH_RISCV_ARCH_INLINES_H_
8#define ZEPHYR_INCLUDE_ARCH_RISCV_ARCH_INLINES_H_
17#ifdef CONFIG_RISCV_S_MODE
30#if defined(CONFIG_SMP) || defined(CONFIG_USERSPACE)
31#ifdef CONFIG_RISCV_S_MODE
37 return &_kernel.cpus[0];
41#ifdef CONFIG_RISCV_CURRENT_VIA_GP
43register struct k_thread *__arch_current_thread __asm__(
"gp");
45#define arch_current_thread() __arch_current_thread
46#define arch_current_thread_set(thread) ({ __arch_current_thread = (thread); })
52 return CONFIG_MP_MAX_NUM_CPUS;
static ALWAYS_INLINE _cpu_t * arch_curr_cpu(void)
Definition arch_inlines.h:18
#define csr_read(csr)
Definition csr.h:210
static ALWAYS_INLINE unsigned int arch_num_cpus(void)
Definition arch_inlines.h:12
static ALWAYS_INLINE uint32_t arch_proc_id(void)
Definition arch_inlines.h:15
__UINT32_TYPE__ uint32_t
Definition stdint.h:90
__UINTPTR_TYPE__ uintptr_t
Definition stdint.h:105
Thread Structure.
Definition thread.h:259