projects
/
cascardo
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
x86/boot: Rework reserve_real_mode() to allow multiple tries
[cascardo/linux.git]
/
arch
/
x86
/
include
/
asm
/
realmode.h
diff --git
a/arch/x86/include/asm/realmode.h
b/arch/x86/include/asm/realmode.h
index
8d67777
..
b2988c0
100644
(file)
--- a/
arch/x86/include/asm/realmode.h
+++ b/
arch/x86/include/asm/realmode.h
@@
-58,6
+58,15
@@
extern unsigned char boot_gdt[];
extern unsigned char secondary_startup_64[];
#endif
extern unsigned char secondary_startup_64[];
#endif
+static inline size_t real_mode_size_needed(void)
+{
+ if (real_mode_header)
+ return 0; /* already allocated. */
+
+ return ALIGN(real_mode_blob_end - real_mode_blob, PAGE_SIZE);
+}
+
+void set_real_mode_mem(phys_addr_t mem, size_t size);
void reserve_real_mode(void);
#endif /* _ARCH_X86_REALMODE_H */
void reserve_real_mode(void);
#endif /* _ARCH_X86_REALMODE_H */