aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Documentation/kernel-parameters.txt1
-rw-r--r--arch/x86/xen/platform-pci-unplug.c5
-rw-r--r--include/xen/platform_pci.h1
3 files changed, 7 insertions, 0 deletions
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
index 2c85c0692b01..8bbe83b9d0b2 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -2631,6 +2631,7 @@ and is between 256 and 4096 characters. It is defined in the file
2631 all -- unplug all emulated devices (NICs and IDE disks) 2631 all -- unplug all emulated devices (NICs and IDE disks)
2632 ignore -- continue loading the Xen platform PCI driver even 2632 ignore -- continue loading the Xen platform PCI driver even
2633 if the version check failed 2633 if the version check failed
2634 never -- do not unplug even if version check succeeds
2634 2635
2635 xirc2ps_cs= [NET,PCMCIA] 2636 xirc2ps_cs= [NET,PCMCIA]
2636 Format: 2637 Format:
diff --git a/arch/x86/xen/platform-pci-unplug.c b/arch/x86/xen/platform-pci-unplug.c
index 554c002a1e1a..070dfa0654bd 100644
--- a/arch/x86/xen/platform-pci-unplug.c
+++ b/arch/x86/xen/platform-pci-unplug.c
@@ -72,6 +72,9 @@ void __init xen_unplug_emulated_devices(void)
72{ 72{
73 int r; 73 int r;
74 74
75 /* user explicitly requested no unplug */
76 if (xen_emul_unplug & XEN_UNPLUG_NEVER)
77 return;
75 /* check the version of the xen platform PCI device */ 78 /* check the version of the xen platform PCI device */
76 r = check_platform_magic(); 79 r = check_platform_magic();
77 /* If the version matches enable the Xen platform PCI driver. 80 /* If the version matches enable the Xen platform PCI driver.
@@ -127,6 +130,8 @@ static int __init parse_xen_emul_unplug(char *arg)
127 xen_emul_unplug |= XEN_UNPLUG_ALL_NICS; 130 xen_emul_unplug |= XEN_UNPLUG_ALL_NICS;
128 else if (!strncmp(p, "ignore", l)) 131 else if (!strncmp(p, "ignore", l))
129 xen_emul_unplug |= XEN_UNPLUG_IGNORE; 132 xen_emul_unplug |= XEN_UNPLUG_IGNORE;
133 else if (!strncmp(p, "never", l))
134 xen_emul_unplug |= XEN_UNPLUG_NEVER;
130 else 135 else
131 printk(KERN_WARNING "unrecognised option '%s' " 136 printk(KERN_WARNING "unrecognised option '%s' "
132 "in parameter 'xen_emul_unplug'\n", p); 137 "in parameter 'xen_emul_unplug'\n", p);
diff --git a/include/xen/platform_pci.h b/include/xen/platform_pci.h
index ce9d671c636c..123b7752fa6a 100644
--- a/include/xen/platform_pci.h
+++ b/include/xen/platform_pci.h
@@ -21,6 +21,7 @@
21#define XEN_UNPLUG_AUX_IDE_DISKS 4 21#define XEN_UNPLUG_AUX_IDE_DISKS 4
22#define XEN_UNPLUG_ALL 7 22#define XEN_UNPLUG_ALL 7
23#define XEN_UNPLUG_IGNORE 8 23#define XEN_UNPLUG_IGNORE 8
24#define XEN_UNPLUG_NEVER 16
24 25
25static inline int xen_must_unplug_nics(void) { 26static inline int xen_must_unplug_nics(void) {
26#if (defined(CONFIG_XEN_NETDEV_FRONTEND) || \ 27#if (defined(CONFIG_XEN_NETDEV_FRONTEND) || \