Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

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

Pull RISC-V fixes from Palmer Dabbelt:

- A fix for a build warning in the jump_label code

- One of the git://github -> https://github cleanups, for the SiFive
drivers

- A fix for the kasan initialization code, this still likely warrants
some cleanups but that's a bigger problem and at least this fixes the
crashes in the short term

- A pair of fixes for extension support detection on mixed LLVM/GNU
toolchains

- A fix for a runtime warning in the /proc/cpuinfo code

* tag 'riscv-for-linus-6.1-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux:
RISC-V: Fix /proc/cpuinfo cpumask warning
riscv: fix detection of toolchain Zihintpause support
riscv: fix detection of toolchain Zicbom support
riscv: mm: add missing memcpy in kasan_init
MAINTAINERS: git://github.com -> https://github.com for sifive
riscv: jump_label: mark arguments as const to satisfy asm constraints

+30 -15
+1 -1
MAINTAINERS
··· 18787 18787 M: Paul Walmsley <paul.walmsley@sifive.com> 18788 18788 L: linux-riscv@lists.infradead.org 18789 18789 S: Supported 18790 - T: git git://github.com/sifive/riscv-linux.git 18790 + T: git https://github.com/sifive/riscv-linux.git 18791 18791 N: sifive 18792 18792 K: [^@]sifive 18793 18793
+13 -4
arch/riscv/Kconfig
··· 411 411 412 412 If you don't know what to do here, say Y. 413 413 414 - config CC_HAS_ZICBOM 414 + config TOOLCHAIN_HAS_ZICBOM 415 415 bool 416 - default y if 64BIT && $(cc-option,-mabi=lp64 -march=rv64ima_zicbom) 417 - default y if 32BIT && $(cc-option,-mabi=ilp32 -march=rv32ima_zicbom) 416 + default y 417 + depends on !64BIT || $(cc-option,-mabi=lp64 -march=rv64ima_zicbom) 418 + depends on !32BIT || $(cc-option,-mabi=ilp32 -march=rv32ima_zicbom) 419 + depends on LLD_VERSION >= 150000 || LD_VERSION >= 23800 418 420 419 421 config RISCV_ISA_ZICBOM 420 422 bool "Zicbom extension support for non-coherent DMA operation" 421 - depends on CC_HAS_ZICBOM 423 + depends on TOOLCHAIN_HAS_ZICBOM 422 424 depends on !XIP_KERNEL && MMU 423 425 select RISCV_DMA_NONCOHERENT 424 426 select RISCV_ALTERNATIVE ··· 434 432 non-coherent DMA support on devices that need it. 435 433 436 434 If you don't know what to do here, say Y. 435 + 436 + config TOOLCHAIN_HAS_ZIHINTPAUSE 437 + bool 438 + default y 439 + depends on !64BIT || $(cc-option,-mabi=lp64 -march=rv64ima_zihintpause) 440 + depends on !32BIT || $(cc-option,-mabi=ilp32 -march=rv32ima_zihintpause) 441 + depends on LLD_VERSION >= 150000 || LD_VERSION >= 23600 437 442 438 443 config FPU 439 444 bool "FPU support"
+2 -4
arch/riscv/Makefile
··· 59 59 riscv-march-$(toolchain-need-zicsr-zifencei) := $(riscv-march-y)_zicsr_zifencei 60 60 61 61 # Check if the toolchain supports Zicbom extension 62 - toolchain-supports-zicbom := $(call cc-option-yn, -march=$(riscv-march-y)_zicbom) 63 - riscv-march-$(toolchain-supports-zicbom) := $(riscv-march-y)_zicbom 62 + riscv-march-$(CONFIG_TOOLCHAIN_HAS_ZICBOM) := $(riscv-march-y)_zicbom 64 63 65 64 # Check if the toolchain supports Zihintpause extension 66 - toolchain-supports-zihintpause := $(call cc-option-yn, -march=$(riscv-march-y)_zihintpause) 67 - riscv-march-$(toolchain-supports-zihintpause) := $(riscv-march-y)_zihintpause 65 + riscv-march-$(CONFIG_TOOLCHAIN_HAS_ZIHINTPAUSE) := $(riscv-march-y)_zihintpause 68 66 69 67 KBUILD_CFLAGS += -march=$(subst fd,,$(riscv-march-y)) 70 68 KBUILD_AFLAGS += -march=$(riscv-march-y)
+4 -4
arch/riscv/include/asm/jump_label.h
··· 14 14 15 15 #define JUMP_LABEL_NOP_SIZE 4 16 16 17 - static __always_inline bool arch_static_branch(struct static_key *key, 18 - bool branch) 17 + static __always_inline bool arch_static_branch(struct static_key * const key, 18 + const bool branch) 19 19 { 20 20 asm_volatile_goto( 21 21 " .option push \n\t" ··· 35 35 return true; 36 36 } 37 37 38 - static __always_inline bool arch_static_branch_jump(struct static_key *key, 39 - bool branch) 38 + static __always_inline bool arch_static_branch_jump(struct static_key * const key, 39 + const bool branch) 40 40 { 41 41 asm_volatile_goto( 42 42 " .option push \n\t"
+1 -1
arch/riscv/include/asm/vdso/processor.h
··· 21 21 * Reduce instruction retirement. 22 22 * This assumes the PC changes. 23 23 */ 24 - #ifdef __riscv_zihintpause 24 + #ifdef CONFIG_TOOLCHAIN_HAS_ZIHINTPAUSE 25 25 __asm__ __volatile__ ("pause"); 26 26 #else 27 27 /* Encoding of the pause instruction */
+3
arch/riscv/kernel/cpu.c
··· 213 213 214 214 static void *c_start(struct seq_file *m, loff_t *pos) 215 215 { 216 + if (*pos == nr_cpu_ids) 217 + return NULL; 218 + 216 219 *pos = cpumask_next(*pos - 1, cpu_online_mask); 217 220 if ((*pos) < nr_cpu_ids) 218 221 return (void *)(uintptr_t)(1 + *pos);
+6 -1
arch/riscv/mm/kasan_init.c
··· 113 113 base_pud = pt_ops.get_pud_virt(pfn_to_phys(_pgd_pfn(*pgd))); 114 114 } else if (pgd_none(*pgd)) { 115 115 base_pud = memblock_alloc(PTRS_PER_PUD * sizeof(pud_t), PAGE_SIZE); 116 + memcpy(base_pud, (void *)kasan_early_shadow_pud, 117 + sizeof(pud_t) * PTRS_PER_PUD); 116 118 } else { 117 119 base_pud = (pud_t *)pgd_page_vaddr(*pgd); 118 120 if (base_pud == lm_alias(kasan_early_shadow_pud)) { ··· 175 173 base_p4d = pt_ops.get_p4d_virt(pfn_to_phys(_pgd_pfn(*pgd))); 176 174 } else { 177 175 base_p4d = (p4d_t *)pgd_page_vaddr(*pgd); 178 - if (base_p4d == lm_alias(kasan_early_shadow_p4d)) 176 + if (base_p4d == lm_alias(kasan_early_shadow_p4d)) { 179 177 base_p4d = memblock_alloc(PTRS_PER_PUD * sizeof(p4d_t), PAGE_SIZE); 178 + memcpy(base_p4d, (void *)kasan_early_shadow_p4d, 179 + sizeof(p4d_t) * PTRS_PER_P4D); 180 + } 180 181 } 181 182 182 183 p4dp = base_p4d + p4d_index(vaddr);