Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1b3a5d02 authored by Robin Holt's avatar Robin Holt Committed by Linus Torvalds
Browse files

reboot: move arch/x86 reboot= handling to generic kernel



Merge together the unicore32, arm, and x86 reboot= command line
parameter handling.

Signed-off-by: default avatarRobin Holt <holt@sgi.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Russell King <rmk+kernel@arm.linux.org.uk>
Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
Cc: Russ Anderson <rja@sgi.com>
Cc: Robin Holt <holt@sgi.com>
Acked-by: default avatarIngo Molnar <mingo@kernel.org>
Acked-by: default avatarGuan Xuetao <gxt@mprc.pku.edu.cn>
Acked-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 7b6d864b
Loading
Loading
Loading
Loading
+11 −3
Original line number Diff line number Diff line
@@ -2681,9 +2681,17 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
			Run specified binary instead of /init from the ramdisk,
			used for early userspace startup. See initrd.

	reboot=		[BUGS=X86-32,BUGS=ARM,BUGS=IA-64] Rebooting mode
			Format: <reboot_mode>[,<reboot_mode2>[,...]]
			See arch/*/kernel/reboot.c or arch/*/kernel/process.c
	reboot=		[KNL]
			Format (x86 or x86_64):
				[w[arm] | c[old] | h[ard] | s[oft] | g[pio]] \
				[[,]s[mp]#### \
				[[,]b[ios] | a[cpi] | k[bd] | t[riple] | e[fi] | p[ci]] \
				[[,]f[orce]
			Where reboot_mode is one of warm (soft) or cold (hard) or gpio,
			      reboot_type is one of bios, acpi, kbd, triple, efi, or pci,
			      reboot_force is either force or not specified,
			      reboot_cpu is s[mp]#### with #### being the processor
					to be used for rebooting.

	relax_domain_level=
			[KNL, SMP] Set scheduler's default relax_domain_level.
+0 −10
Original line number Diff line number Diff line
@@ -176,16 +176,6 @@ void arch_cpu_idle(void)
		default_idle();
}

enum reboot_mode reboot_mode = REBOOT_HARD;

static int __init reboot_setup(char *str)
{
	if ('s' == str[0])
		reboot_mode = REBOOT_SOFT;
	return 1;
}
__setup("reboot=", reboot_setup);

/*
 * Called by kexec, immediately prior to machine_kexec().
 *
+0 −10
Original line number Diff line number Diff line
@@ -51,16 +51,6 @@ void arch_cpu_idle(void)
	local_irq_enable();
}

static enum reboot_mode reboot_mode = REBOOT_HARD;

int __init reboot_setup(char *str)
{
	if ('s' == str[0])
		reboot_mode = REBOOT_SOFT;
	return 1;
}
__setup("reboot=", reboot_setup);

void machine_halt(void)
{
	gpio_set_value(GPO_SOFT_OFF, 0);
+0 −12
Original line number Diff line number Diff line
#ifndef _ASM_X86_EMERGENCY_RESTART_H
#define _ASM_X86_EMERGENCY_RESTART_H

enum reboot_type {
	BOOT_TRIPLE = 't',
	BOOT_KBD = 'k',
	BOOT_BIOS = 'b',
	BOOT_ACPI = 'a',
	BOOT_EFI = 'e',
	BOOT_CF9 = 'p',
	BOOT_CF9_COND = 'q',
};

extern enum reboot_type reboot_type;

extern void machine_emergency_restart(void);

#endif /* _ASM_X86_EMERGENCY_RESTART_H */
+1 −1
Original line number Diff line number Diff line
@@ -25,6 +25,7 @@
#include <linux/kdebug.h>
#include <linux/delay.h>
#include <linux/crash_dump.h>
#include <linux/reboot.h>

#include <asm/uv/uv_mmrs.h>
#include <asm/uv/uv_hub.h>
@@ -36,7 +37,6 @@
#include <asm/ipi.h>
#include <asm/smp.h>
#include <asm/x86_init.h>
#include <asm/emergency-restart.h>
#include <asm/nmi.h>

/* BMC sets a bit this MMR non-zero before sending an NMI */
Loading