diff options
| -rw-r--r-- | drivers/block/xen-blkfront.c | 3 | ||||
| -rw-r--r-- | drivers/net/xen-netfront.c | 4 | ||||
| -rw-r--r-- | drivers/xen/platform-pci.c | 5 |
3 files changed, 7 insertions, 5 deletions
diff --git a/drivers/block/xen-blkfront.c b/drivers/block/xen-blkfront.c index 9fd3ee203b1e..4276ab035e00 100644 --- a/drivers/block/xen-blkfront.c +++ b/drivers/block/xen-blkfront.c | |||
| @@ -1452,6 +1452,9 @@ static int __init xlblk_init(void) | |||
| 1452 | if (!xen_domain()) | 1452 | if (!xen_domain()) |
| 1453 | return -ENODEV; | 1453 | return -ENODEV; |
| 1454 | 1454 | ||
| 1455 | if (!xen_platform_pci_unplug) | ||
| 1456 | return -ENODEV; | ||
| 1457 | |||
| 1455 | if (register_blkdev(XENVBD_MAJOR, DEV_NAME)) { | 1458 | if (register_blkdev(XENVBD_MAJOR, DEV_NAME)) { |
| 1456 | printk(KERN_WARNING "xen_blk: can't get major %d with name %s\n", | 1459 | printk(KERN_WARNING "xen_blk: can't get major %d with name %s\n", |
| 1457 | XENVBD_MAJOR, DEV_NAME); | 1460 | XENVBD_MAJOR, DEV_NAME); |
diff --git a/drivers/net/xen-netfront.c b/drivers/net/xen-netfront.c index fa679057630f..8cc0914b9f92 100644 --- a/drivers/net/xen-netfront.c +++ b/drivers/net/xen-netfront.c | |||
| @@ -47,6 +47,7 @@ | |||
| 47 | #include <xen/xenbus.h> | 47 | #include <xen/xenbus.h> |
| 48 | #include <xen/events.h> | 48 | #include <xen/events.h> |
| 49 | #include <xen/page.h> | 49 | #include <xen/page.h> |
| 50 | #include <xen/platform_pci.h> | ||
| 50 | #include <xen/grant_table.h> | 51 | #include <xen/grant_table.h> |
| 51 | 52 | ||
| 52 | #include <xen/interface/io/netif.h> | 53 | #include <xen/interface/io/netif.h> |
| @@ -1956,6 +1957,9 @@ static int __init netif_init(void) | |||
| 1956 | if (xen_initial_domain()) | 1957 | if (xen_initial_domain()) |
| 1957 | return 0; | 1958 | return 0; |
| 1958 | 1959 | ||
| 1960 | if (!xen_platform_pci_unplug) | ||
| 1961 | return -ENODEV; | ||
| 1962 | |||
| 1959 | printk(KERN_INFO "Initialising Xen virtual ethernet driver.\n"); | 1963 | printk(KERN_INFO "Initialising Xen virtual ethernet driver.\n"); |
| 1960 | 1964 | ||
| 1961 | return xenbus_register_frontend(&netfront_driver); | 1965 | return xenbus_register_frontend(&netfront_driver); |
diff --git a/drivers/xen/platform-pci.c b/drivers/xen/platform-pci.c index 319dd0a94d51..2389e581e23c 100644 --- a/drivers/xen/platform-pci.c +++ b/drivers/xen/platform-pci.c | |||
| @@ -186,11 +186,6 @@ static struct pci_driver platform_driver = { | |||
| 186 | 186 | ||
| 187 | static int __init platform_pci_module_init(void) | 187 | static int __init platform_pci_module_init(void) |
| 188 | { | 188 | { |
| 189 | /* no unplug has been done, IGNORE hasn't been specified: just | ||
| 190 | * return now */ | ||
| 191 | if (!xen_platform_pci_unplug) | ||
| 192 | return -ENODEV; | ||
| 193 | |||
| 194 | return pci_register_driver(&platform_driver); | 189 | return pci_register_driver(&platform_driver); |
| 195 | } | 190 | } |
| 196 | 191 | ||
