xen: pvhvm: allow user to request no emulated device unplug
[deliverable/linux.git] / arch / x86 / xen / platform-pci-unplug.c
index 554c002a1e1afcd13a71c90a25eff86057e56832..070dfa0654bdcbf7ee882589db68ce9b69ad17ae 100644 (file)
@@ -72,6 +72,9 @@ void __init xen_unplug_emulated_devices(void)
 {
        int r;
 
+       /* user explicitly requested no unplug */
+       if (xen_emul_unplug & XEN_UNPLUG_NEVER)
+               return;
        /* check the version of the xen platform PCI device */
        r = check_platform_magic();
        /* If the version matches enable the Xen platform PCI driver.
@@ -127,6 +130,8 @@ static int __init parse_xen_emul_unplug(char *arg)
                        xen_emul_unplug |= XEN_UNPLUG_ALL_NICS;
                else if (!strncmp(p, "ignore", l))
                        xen_emul_unplug |= XEN_UNPLUG_IGNORE;
+               else if (!strncmp(p, "never", l))
+                       xen_emul_unplug |= XEN_UNPLUG_NEVER;
                else
                        printk(KERN_WARNING "unrecognised option '%s' "
                                 "in parameter 'xen_emul_unplug'\n", p);
This page took 0.073322 seconds and 5 git commands to generate.