Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/bochs: Fix the ID mismatch error

When running RISC-V QEMU with the Bochs device attached via PCIe the
probe of the Bochs device fails with:
[drm:bochs_hw_init] *ERROR* ID mismatch

This was introduced by this commit:
7780eb9ce8 bochs: convert to drm_dev_register

To fix the error we ensure that pci_enable_device() is called before
bochs_load().

Fixes: 7780eb9ce80f ("bochs: convert to drm_dev_register")
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Reported-by: David Abdurachmanov <david.abdurachmanov@gmail.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20190221003231.31625-1-alistair.francis@wdc.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>

authored by

Alistair Francis and committed by
Dave Airlie
17fb465f 22163229

+4
+4
drivers/gpu/drm/bochs/bochs_drv.c
··· 154 154 if (IS_ERR(dev)) 155 155 return PTR_ERR(dev); 156 156 157 + ret = pci_enable_device(pdev); 158 + if (ret) 159 + goto err_free_dev; 160 + 157 161 dev->pdev = pdev; 158 162 pci_set_drvdata(pdev, dev); 159 163