intel: Allow opening the device only through platform information

Only fail to open the device based on the PCI address, if and only if we
do not have sufficient platform information to find the correct system
device.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
Chris Wilson 2013-10-03 14:52:11 +01:00
parent a47f8683fe
commit a0476ee6d0
2 changed files with 3 additions and 3 deletions

View File

@ -183,6 +183,9 @@ static int __intel_open_device(const struct pci_device *pci, char **path)
char id[20];
int ret;
if (pci == NULL)
return -1;
snprintf(id, sizeof(id),
"pci:%04x:%02x:%02x.%d",
pci->domain, pci->bus, pci->dev, pci->func);

View File

@ -546,9 +546,6 @@ intel_platform_probe(DriverPtr driver,
{
unsigned scrn_flags = 0;
if (!dev->pdev)
return FALSE;
if (intel_open_device(entity_num, dev->pdev, dev) == -1)
return FALSE;