Commit 8c4dd606 authored by Tim Gardner's avatar Tim Gardner Committed by Linus Torvalds

edd: add default mode CONFIG_EDD_OFF=n, override with edd={on,off}

Add a kernel parameter option to 'edd' to enable/disable BIOS Enhanced Disk
Drive Services.  CONFIG_EDD_OFF disables EDD while still compiling EDD into
the kernel.  Default behavior can be forced using 'edd=on' or 'edd=off' as
a kernel parameter.

[akpm@linux-foundation.org: fix kernel-parameters.txt]
Signed-off-by: default avatarTim Gardner <tim.gardner@canonical.com>
Signed-off-by: default avatarMatt Domsch <Matt_Domsch@dell.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: "Randy.Dunlap" <rdunlap@xenotime.net>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent d7321cd6
...@@ -627,8 +627,7 @@ and is between 256 and 4096 characters. It is defined in the file ...@@ -627,8 +627,7 @@ and is between 256 and 4096 characters. It is defined in the file
eata= [HW,SCSI] eata= [HW,SCSI]
edd= [EDD] edd= [EDD]
Format: {"of[f]" | "sk[ipmbr]"} Format: {"off" | "on" | "skip[mbr]"}
See comment in arch/i386/boot/edd.S
eisa_irq_edge= [PARISC,HW] eisa_irq_edge= [PARISC,HW]
See header of drivers/parisc/eisa.c. See header of drivers/parisc/eisa.c.
......
...@@ -126,17 +126,25 @@ void query_edd(void) ...@@ -126,17 +126,25 @@ void query_edd(void)
{ {
char eddarg[8]; char eddarg[8];
int do_mbr = 1; int do_mbr = 1;
#ifdef CONFIG_EDD_OFF
int do_edd = 0;
#else
int do_edd = 1; int do_edd = 1;
#endif
int be_quiet; int be_quiet;
int devno; int devno;
struct edd_info ei, *edp; struct edd_info ei, *edp;
u32 *mbrptr; u32 *mbrptr;
if (cmdline_find_option("edd", eddarg, sizeof eddarg) > 0) { if (cmdline_find_option("edd", eddarg, sizeof eddarg) > 0) {
if (!strcmp(eddarg, "skipmbr") || !strcmp(eddarg, "skip")) if (!strcmp(eddarg, "skipmbr") || !strcmp(eddarg, "skip")) {
do_edd = 1;
do_mbr = 0; do_mbr = 0;
}
else if (!strcmp(eddarg, "off")) else if (!strcmp(eddarg, "off"))
do_edd = 0; do_edd = 0;
else if (!strcmp(eddarg, "on"))
do_edd = 1;
} }
be_quiet = cmdline_find_option_bool("quiet"); be_quiet = cmdline_find_option_bool("quiet");
......
...@@ -17,6 +17,15 @@ config EDD ...@@ -17,6 +17,15 @@ config EDD
obscure configurations. Most disk controller BIOS vendors do obscure configurations. Most disk controller BIOS vendors do
not yet implement this feature. not yet implement this feature.
config EDD_OFF
bool "Sets default behavior for EDD detection to off"
depends on EDD
default n
help
Say Y if you want EDD disabled by default, even though it is compiled into the
kernel. Say N if you want EDD enabled by default. EDD can be dynamically set
using the kernel parameter 'edd={on|skipmbr|off}'.
config EFI_VARS config EFI_VARS
tristate "EFI Variable Support via sysfs" tristate "EFI Variable Support via sysfs"
depends on EFI depends on EFI
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment