Skip to contentSkip to conversation

Rename sbi_save to parse_dtb to improve code readability

PATCH New Palmer Dabbelt 1 participant 1 message Feb 15, 2018 1 message not in the archive RISC-V

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

PATCH 1/1 Rename sbi_save to parse_dtb to improve code readability

Quoted 29 lines · Michael Clark

From: Michael Clark <[email protected]>

The sbi_ prefix would seem to indicate an SBI interface, and save is not very specific. After applying this patch, reading head.S makes more sense.

---
 arch/riscv/kernel/head.S  | 2 +-
 arch/riscv/kernel/setup.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
arch/riscv/kernel/head.S +1 -1
index 226eeb1..6e07ed3 100644
@@ -64,7 +64,7 @@ ENTRY(_start)
 	/* Start the kernel */
 	mv a0, s0
 	mv a1, s1
-	call sbi_save
+	call parse_dtb
 	tail start_kernel
 
 relocate:
arch/riscv/kernel/setup.c +0 -0
index c6f332b..41d3400 100644

arch/riscv/kernel/setup.c asmlinkage void __init setup_vm(void) · line 171

Quoted 8 lines
arch/riscv/kernel/setup.c +1 -1
@@ -165,7 +165,7 @@ asmlinkage void __init setup_vm(void)
 #endif
 }
 
-void __init sbi_save(unsigned int hartid, void *dtb)
+void __init parse_dtb(unsigned int hartid, void *dtb)
 {
 	early_init_dt_scan(__va(dtb));
 }

Thanks.