x86/boot: Remove KEEP_SEGMENTS support
Commit a24e785111a3 ("i386: paravirt boot sequence") added this flag for use by paravirtualized environments such as Xen. However, Xen never made use of this flag [1], and it was only ever used by lguest [2]. Commit ecda85e70277 ("x86/lguest: Remove lguest support") removed lguest, so KEEP_SEGMENTS has lost its last user. [1] https://lore.kernel.org/lkml/4D4B097C.5050405@goop.org [2] https://www.mail-archive.com/lguest@lists.ozlabs.org/msg00469.html Signed-off-by: Arvind Sankar <nivedita@alum.mit.edu> Link: https://lore.kernel.org/r/20200202171353.3736319-2-nivedita@alum.mit.edu Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
This commit is contained in:
parent
9f9223778e
commit
67a6af7ad1
@ -490,15 +490,11 @@ Protocol: 2.00+
|
|||||||
kernel) to not write early messages that require
|
kernel) to not write early messages that require
|
||||||
accessing the display hardware directly.
|
accessing the display hardware directly.
|
||||||
|
|
||||||
Bit 6 (write): KEEP_SEGMENTS
|
Bit 6 (obsolete): KEEP_SEGMENTS
|
||||||
|
|
||||||
Protocol: 2.07+
|
Protocol: 2.07+
|
||||||
|
|
||||||
- If 0, reload the segment registers in the 32bit entry point.
|
- This flag is obsolete.
|
||||||
- If 1, do not reload the segment registers in the 32bit entry point.
|
|
||||||
|
|
||||||
Assume that %cs %ds %ss %es are all set to flat segments with
|
|
||||||
a base of 0 (or the equivalent for their environment).
|
|
||||||
|
|
||||||
Bit 7 (write): CAN_USE_HEAP
|
Bit 7 (write): CAN_USE_HEAP
|
||||||
|
|
||||||
|
@ -63,13 +63,6 @@
|
|||||||
__HEAD
|
__HEAD
|
||||||
SYM_FUNC_START(startup_32)
|
SYM_FUNC_START(startup_32)
|
||||||
cld
|
cld
|
||||||
/*
|
|
||||||
* Test KEEP_SEGMENTS flag to see if the bootloader is asking
|
|
||||||
* us to not reload segments
|
|
||||||
*/
|
|
||||||
testb $KEEP_SEGMENTS, BP_loadflags(%esi)
|
|
||||||
jnz 1f
|
|
||||||
|
|
||||||
cli
|
cli
|
||||||
movl $__BOOT_DS, %eax
|
movl $__BOOT_DS, %eax
|
||||||
movl %eax, %ds
|
movl %eax, %ds
|
||||||
@ -77,7 +70,6 @@ SYM_FUNC_START(startup_32)
|
|||||||
movl %eax, %fs
|
movl %eax, %fs
|
||||||
movl %eax, %gs
|
movl %eax, %gs
|
||||||
movl %eax, %ss
|
movl %eax, %ss
|
||||||
1:
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Calculate the delta between where we were compiled to run
|
* Calculate the delta between where we were compiled to run
|
||||||
|
@ -53,19 +53,11 @@ SYM_FUNC_START(startup_32)
|
|||||||
* all need to be under the 4G limit.
|
* all need to be under the 4G limit.
|
||||||
*/
|
*/
|
||||||
cld
|
cld
|
||||||
/*
|
|
||||||
* Test KEEP_SEGMENTS flag to see if the bootloader is asking
|
|
||||||
* us to not reload segments
|
|
||||||
*/
|
|
||||||
testb $KEEP_SEGMENTS, BP_loadflags(%esi)
|
|
||||||
jnz 1f
|
|
||||||
|
|
||||||
cli
|
cli
|
||||||
movl $(__BOOT_DS), %eax
|
movl $(__BOOT_DS), %eax
|
||||||
movl %eax, %ds
|
movl %eax, %ds
|
||||||
movl %eax, %es
|
movl %eax, %es
|
||||||
movl %eax, %ss
|
movl %eax, %ss
|
||||||
1:
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Calculate the delta between where we were compiled to run
|
* Calculate the delta between where we were compiled to run
|
||||||
|
@ -67,11 +67,6 @@ __HEAD
|
|||||||
SYM_CODE_START(startup_32)
|
SYM_CODE_START(startup_32)
|
||||||
movl pa(initial_stack),%ecx
|
movl pa(initial_stack),%ecx
|
||||||
|
|
||||||
/* test KEEP_SEGMENTS flag to see if the bootloader is asking
|
|
||||||
us to not reload segments */
|
|
||||||
testb $KEEP_SEGMENTS, BP_loadflags(%esi)
|
|
||||||
jnz 2f
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Set segments to known values.
|
* Set segments to known values.
|
||||||
*/
|
*/
|
||||||
@ -82,7 +77,6 @@ SYM_CODE_START(startup_32)
|
|||||||
movl %eax,%fs
|
movl %eax,%fs
|
||||||
movl %eax,%gs
|
movl %eax,%gs
|
||||||
movl %eax,%ss
|
movl %eax,%ss
|
||||||
2:
|
|
||||||
leal -__PAGE_OFFSET(%ecx),%esp
|
leal -__PAGE_OFFSET(%ecx),%esp
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user