ia64/linux-2.6.18-xen.hg

changeset 770:78d81e85e8cd

Bind PCI back driver to PCI device specified by "guestdev=".

This patch binds PCI back driver to PCI device specified by
"guestdev=" boot parameter.

Signed-off-by: Yuji Shimada <shimada-yxb@necst.nec.co.jp>
author Keir Fraser <keir.fraser@citrix.com>
date Mon Jan 05 10:54:08 2009 +0000 (2009-01-05)
parents 2fdc121e9b5d
children cfb171ddbb33
files drivers/xen/pciback/pci_stub.c
line diff
     1.1 --- a/drivers/xen/pciback/pci_stub.c	Mon Jan 05 10:53:44 2009 +0000
     1.2 +++ b/drivers/xen/pciback/pci_stub.c	Mon Jan 05 10:54:08 2009 +0000
     1.3 @@ -427,6 +427,16 @@ static int __devinit pcistub_probe(struc
     1.4  
     1.5  		dev_info(&dev->dev, "seizing device\n");
     1.6  		err = pcistub_seize(dev);
     1.7 +#ifdef CONFIG_PCI_GUESTDEV
     1.8 +	} else if (dev->hdr_type == PCI_HEADER_TYPE_NORMAL) {
     1.9 +		if (!pci_is_guestdev(dev)) {
    1.10 +			err = -ENODEV;
    1.11 +			goto out;
    1.12 +		}
    1.13 +
    1.14 +		dev_info(&dev->dev, "seizing device\n");
    1.15 +		err = pcistub_seize(dev);
    1.16 +#endif /* CONFIG_PCI_GUESTDEV */
    1.17  	} else
    1.18  		/* Didn't find the device */
    1.19  		err = -ENODEV;