| /linux/arch/riscv/kernel/ |
| H A D | cpu_ops_sbi.c | 26 static int sbi_hsm_hart_start(unsigned long hartid, unsigned long saddr, in sbi_hsm_hart_start() argument 32 hartid, saddr, priv, 0, 0, 0); in sbi_hsm_hart_start() 52 static int sbi_hsm_hart_get_status(unsigned long hartid) in sbi_hsm_hart_get_status() argument 57 hartid, 0, 0, 0, 0, 0); in sbi_hsm_hart_get_status() 68 unsigned long hartid = cpuid_to_hartid_map(cpuid); in sbi_cpu_start() local 79 return sbi_hsm_hart_start(hartid, boot_addr, hsm_data); in sbi_cpu_start() 94 unsigned long hartid = cpuid_to_hartid_map(cpuid); in sbi_cpu_is_stopped() local 96 rc = sbi_hsm_hart_get_status(hartid); in sbi_cpu_is_stopped()
|
| H A D | cpu.c | 125 int riscv_of_parent_hartid(struct device_node *node, unsigned long *hartid) in riscv_of_parent_hartid() argument 129 *hartid = (unsigned long)of_get_cpu_hwid(node, 0); in riscv_of_parent_hartid() 130 if (*hartid == ~0UL) { in riscv_of_parent_hartid()
|
| H A D | hibernate.c | 59 unsigned long hartid; member 101 hdr->hartid = cpuid_to_hartid_map(sleep_cpu); in arch_hibernation_header_save() 125 sleep_cpu = riscv_hartid_to_cpuid(hdr->hartid); in arch_hibernation_header_restore()
|
| H A D | smp.c | 71 int riscv_hartid_to_cpuid(unsigned long hartid) in riscv_hartid_to_cpuid() argument 76 if (cpuid_to_hartid_map(i) == hartid) in riscv_hartid_to_cpuid()
|
| /linux/drivers/firmware/efi/libstub/ |
| H A D | riscv.c | 16 static unsigned long hartid; variable 37 hartid = (unsigned long) fdt32_to_cpu(*(fdt32_t *)prop); in get_boot_hartid_from_fdt() 39 hartid = (unsigned long) fdt64_to_cpu(__get_unaligned_t(fdt64_t, prop)); in get_boot_hartid_from_fdt() 56 return efi_call_proto(boot_protocol, get_boot_hartid, &hartid); in get_boot_hartid_from_efi() 97 jump_kernel(hartid, fdt); in efi_enter_kernel()
|
| /linux/drivers/clocksource/ |
| H A D | timer-riscv.c | 211 unsigned long hartid; in riscv_timer_init_dt() local 214 error = riscv_of_processor_hartid(n, &hartid); in riscv_timer_init_dt() 217 n, hartid); in riscv_timer_init_dt() 221 cpuid = riscv_hartid_to_cpuid(hartid); in riscv_timer_init_dt() 223 pr_warn("Invalid cpuid for hartid [%lu]\n", hartid); in riscv_timer_init_dt()
|
| /linux/Documentation/translations/zh_CN/arch/riscv/ |
| H A D | boot.rst | 31 * ``$a0`` 应包含当前核心的hartid。 93 使用UEFI启动时,EFI stub 需要引导hartid以便将其传递给 ``$a1`` 中的 94 RISC-V内核。EFI stub使用以下方法之一获取引导hartid: 97 - ``boot-hartid`` 设备树子节点(**已弃用**)。
|
| /linux/arch/riscv/include/asm/ |
| H A D | smp.h | 40 int riscv_hartid_to_cpuid(unsigned long hartid); 77 static inline int riscv_hartid_to_cpuid(unsigned long hartid) in riscv_hartid_to_cpuid() argument 79 if (hartid == boot_cpu_hartid) in riscv_hartid_to_cpuid()
|
| H A D | processor.h | 185 int riscv_of_processor_hartid(struct device_node *node, unsigned long *hartid); 186 int riscv_early_of_processor_hartid(struct device_node *node, unsigned long *hartid); 187 int riscv_of_parent_hartid(struct device_node *node, unsigned long *hartid);
|
| H A D | suspend.h | 43 int __cpu_resume_enter(unsigned long hartid, unsigned long context);
|
| H A D | kexec.h | 52 unsigned long hartid,
|
| /linux/arch/riscv/mm/ |
| H A D | cacheflush.c | 124 unsigned long hartid; in cbo_get_block_size() local 127 if (riscv_of_processor_hartid(node, &hartid)) in cbo_get_block_size() 135 *first_hartid = hartid; in cbo_get_block_size() 138 name, *first_hartid, hartid); in cbo_get_block_size()
|
| /linux/drivers/irqchip/ |
| H A D | irq-riscv-imsic-state.c | 652 u32 index, unsigned long *hartid) in imsic_get_parent_hartid() argument 658 if (hartid) in imsic_get_parent_hartid() 659 *hartid = acpi_rintc_index_to_hartid(index); in imsic_get_parent_hartid() 661 if (!hartid || (*hartid == INVALID_HARTID)) in imsic_get_parent_hartid() 678 return riscv_of_parent_hartid(parent.np, hartid); in imsic_get_parent_hartid() 696 unsigned long hartid; in imsic_parse_fwnode() local 705 while (!imsic_get_parent_hartid(fwnode, *nr_parent_irqs, &hartid)) in imsic_parse_fwnode() 792 unsigned long reloff, hartid; in imsic_setup_state() local 883 rc = imsic_get_parent_hartid(fwnode, i, &hartid); in imsic_setup_state() 889 cpu = riscv_hartid_to_cpuid(hartid); in imsic_setup_state()
|
| H A D | irq-sifive-plic.c | 591 unsigned long hartid; in plic_parse_context_parent() local 595 hartid = acpi_rintc_ext_parent_to_hartid(id, context); in plic_parse_context_parent() 596 if (hartid == INVALID_HARTID) in plic_parse_context_parent() 599 *parent_cpu = riscv_hartid_to_cpuid(hartid); in plic_parse_context_parent() 608 rc = riscv_of_parent_hartid(parent.np, &hartid); in plic_parse_context_parent() 613 *parent_cpu = riscv_hartid_to_cpuid(hartid); in plic_parse_context_parent()
|
| H A D | irq-riscv-intc.c | 214 unsigned long hartid; in riscv_intc_init() local 217 rc = riscv_of_parent_hartid(node, &hartid); in riscv_intc_init() 229 if (riscv_hartid_to_cpuid(hartid) != smp_processor_id()) { in riscv_intc_init()
|
| /linux/Documentation/arch/riscv/ |
| H A D | boot.rst | 26 * ``$a0`` to contain the hartid of the current core. 95 When booting with UEFI, the EFI stub requires the boot hartid in order to pass 96 it to the RISC-V kernel in ``$a1``. The EFI stub retrieves the boot hartid using 100 - ``boot-hartid`` devicetree subnode (**deprecated**).
|
| /linux/arch/riscv/ |
| H A D | Kconfig | 1054 variable. This method cannot support CPU hotplug and sparse hartid
|