Commit 69732102 authored by Pingfan Liu's avatar Pingfan Liu Committed by Thomas Gleixner
Browse files

x86/realmode: Remove trampoline_status



There is no reader of trampoline_status, it's only written.

It turns out that after commit ce4b1b16 ("x86/smpboot: Initialize
secondary CPU only if master CPU will wait for it"), trampoline_status is
not needed any more.

Signed-off-by: default avatarPingfan Liu <kernelfans@gmail.com>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Link: https://lkml.kernel.org/r/1563266424-3472-1-git-send-email-kernelfans@gmail.com
parent 5f9e832c
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -20,7 +20,6 @@ struct real_mode_header {
	u32	ro_end;
	/* SMP trampoline */
	u32	trampoline_start;
	u32	trampoline_status;
	u32	trampoline_header;
#ifdef CONFIG_X86_64
	u32	trampoline_pgd;
+0 −5
Original line number Diff line number Diff line
@@ -1023,8 +1023,6 @@ int common_cpu_up(unsigned int cpu, struct task_struct *idle)
static int do_boot_cpu(int apicid, int cpu, struct task_struct *idle,
		       int *cpu0_nmi_registered)
{
	volatile u32 *trampoline_status =
		(volatile u32 *) __va(real_mode_header->trampoline_status);
	/* start_ip had better be page-aligned! */
	unsigned long start_ip = real_mode_header->trampoline_start;

@@ -1116,9 +1114,6 @@ static int do_boot_cpu(int apicid, int cpu, struct task_struct *idle,
		}
	}

	/* mark "stuck" area as not stuck */
	*trampoline_status = 0;

	if (x86_platform.legacy.warm_reset) {
		/*
		 * Cleanup possible dangling ends...
+0 −1
Original line number Diff line number Diff line
@@ -19,7 +19,6 @@ GLOBAL(real_mode_header)
	.long	pa_ro_end
	/* SMP trampoline */
	.long	pa_trampoline_start
	.long	pa_trampoline_status
	.long	pa_trampoline_header
#ifdef CONFIG_X86_64
	.long	pa_trampoline_pgd;
+0 −3
Original line number Diff line number Diff line
@@ -41,9 +41,6 @@ ENTRY(trampoline_start)

	movl	tr_start, %eax	# where we need to go

	movl	$0xA5A5A5A5, trampoline_status
				# write marker for master knows we're running

	/*
	 * GDT tables in non default location kernel can be beyond 16MB and
	 * lgdt will not be able to load the address as in real mode default
+0 −3
Original line number Diff line number Diff line
@@ -49,9 +49,6 @@ ENTRY(trampoline_start)
	mov	%ax, %es
	mov	%ax, %ss

	movl	$0xA5A5A5A5, trampoline_status
	# write marker for master knows we're running

	# Setup stack
	movl	$rm_stack_end, %esp

Loading