Merge branch 'pci/controller/vmd'
- Create "domain" symlink for vmd before adding devices below the VMD bridge so it's available when mdadm assembles RAID devices from them (Jiwei Sun) * pci/controller/vmd: PCI: vmd: Create domain symlink before pci_bus_add_devices()
This commit is contained in:
commit
d098215aec
@ -925,6 +925,9 @@ static int vmd_enable_domain(struct vmd_dev *vmd, unsigned long features)
|
|||||||
dev_set_msi_domain(&vmd->bus->dev,
|
dev_set_msi_domain(&vmd->bus->dev,
|
||||||
dev_get_msi_domain(&vmd->dev->dev));
|
dev_get_msi_domain(&vmd->dev->dev));
|
||||||
|
|
||||||
|
WARN(sysfs_create_link(&vmd->dev->dev.kobj, &vmd->bus->dev.kobj,
|
||||||
|
"domain"), "Can't create symlink to domain\n");
|
||||||
|
|
||||||
vmd_acpi_begin();
|
vmd_acpi_begin();
|
||||||
|
|
||||||
pci_scan_child_bus(vmd->bus);
|
pci_scan_child_bus(vmd->bus);
|
||||||
@ -964,9 +967,6 @@ static int vmd_enable_domain(struct vmd_dev *vmd, unsigned long features)
|
|||||||
pci_bus_add_devices(vmd->bus);
|
pci_bus_add_devices(vmd->bus);
|
||||||
|
|
||||||
vmd_acpi_end();
|
vmd_acpi_end();
|
||||||
|
|
||||||
WARN(sysfs_create_link(&vmd->dev->dev.kobj, &vmd->bus->dev.kobj,
|
|
||||||
"domain"), "Can't create symlink to domain\n");
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1042,8 +1042,8 @@ static void vmd_remove(struct pci_dev *dev)
|
|||||||
{
|
{
|
||||||
struct vmd_dev *vmd = pci_get_drvdata(dev);
|
struct vmd_dev *vmd = pci_get_drvdata(dev);
|
||||||
|
|
||||||
sysfs_remove_link(&vmd->dev->dev.kobj, "domain");
|
|
||||||
pci_stop_root_bus(vmd->bus);
|
pci_stop_root_bus(vmd->bus);
|
||||||
|
sysfs_remove_link(&vmd->dev->dev.kobj, "domain");
|
||||||
pci_remove_root_bus(vmd->bus);
|
pci_remove_root_bus(vmd->bus);
|
||||||
vmd_cleanup_srcu(vmd);
|
vmd_cleanup_srcu(vmd);
|
||||||
vmd_detach_resources(vmd);
|
vmd_detach_resources(vmd);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user