modesetting: pci probing requires interface version 1.4

Set the drm interface version to 1.4 so we get the bus id correctly.

Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
Dave Airlie 2012-06-22 15:26:28 +01:00
parent ec79187d9a
commit 30ab80ef54

View File

@ -215,10 +215,21 @@ static Bool probe_hw_pci(char *dev, struct pci_device *pdev)
{
int fd = open_hw(dev);
char *id, *devid;
drmSetVersion sv;
if (fd == -1)
return FALSE;
sv.drm_di_major = 1;
sv.drm_di_minor = 4;
sv.drm_dd_major = -1;
sv.drm_dd_minor = -1;
if (drmSetInterfaceVersion(fd, &sv)) {
close(fd);
return FALSE;
}
id = drmGetBusid(fd);
devid = ms_DRICreatePCIBusID(pdev);
close(fd);