int efi_create_mapping(struct mm_struct *mm, efi_memory_desc_t *md);
 int efi_set_mapping_permissions(struct mm_struct *mm, efi_memory_desc_t *md, bool);
 
-#define arch_efi_call_virt_setup()      ({             \
-               sync_kernel_mappings(efi_mm.pgd);       \
-               efi_virtmap_load();                     \
-       })
-#define arch_efi_call_virt_teardown()   efi_virtmap_unload()
-
 #define ARCH_EFI_IRQ_FLAGS_MASK (SR_IE | SR_SPIE)
 
 /* Load initrd anywhere in system RAM */
 
 #define EFI_KIMG_PREFERRED_ADDRESS     efi_get_kimg_min_align()
 
-void efi_virtmap_load(void);
-void efi_virtmap_unload(void);
+void arch_efi_call_virt_setup(void);
+void arch_efi_call_virt_teardown(void);
 
 unsigned long stext_offset(void);
 
 
 }
 early_initcall(riscv_enable_runtime_services);
 
-void efi_virtmap_load(void)
+static void efi_virtmap_load(void)
 {
        preempt_disable();
        switch_mm(current->active_mm, &efi_mm, NULL);
 }
 
-void efi_virtmap_unload(void)
+static void efi_virtmap_unload(void)
 {
        switch_mm(&efi_mm, current->active_mm, NULL);
        preempt_enable();
 }
+
+void arch_efi_call_virt_setup(void)
+{
+       sync_kernel_mappings(efi_mm.pgd);
+       efi_virtmap_load();
+}
+
+void arch_efi_call_virt_teardown(void)
+{
+       efi_virtmap_unload();
+}