[PATCH 1/8] efi/x86: Use C wrapper instead of inline assembly

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Call the C wrappers instead of inline assembly for cli and lgdt
instructions.

Signed-off-by: Arvind Sankar <nivedita@xxxxxxxxxxxx>
---
 arch/x86/boot/compressed/eboot.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/arch/x86/boot/compressed/eboot.c b/arch/x86/boot/compressed/eboot.c
index 287393d725f0..f89caae60057 100644
--- a/arch/x86/boot/compressed/eboot.c
+++ b/arch/x86/boot/compressed/eboot.c
@@ -9,6 +9,7 @@
 #pragma GCC visibility push(hidden)
 
 #include <linux/efi.h>
+#include <linux/irqflags.h>
 #include <linux/pci.h>
 
 #include <asm/efi.h>
@@ -877,8 +878,8 @@ struct boot_params *efi_main(efi_handle_t handle,
 		desc++;
 	}
 
-	asm volatile("cli");
-	asm volatile ("lgdt %0" : : "m" (*gdt));
+	raw_local_irq_disable();
+	native_load_gdt(gdt);
 
 	return boot_params;
 fail:
-- 
2.24.1




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux