drm: qxl: Drop duplicated pci_device pointer attribute
authorGabriel Krisman Bertazi <krisman@collabora.co.uk>
Fri, 27 Jan 2017 01:05:47 +0000 (23:05 -0200)
committerGerd Hoffmann <kraxel@redhat.com>
Thu, 2 Feb 2017 09:02:36 +0000 (10:02 +0100)
qxl_device duplicates the pointer to struct pci_dev, which is not
needed since we already have it in the drm_device structure.  Clean it
up.

Signed-off-by: Gabriel Krisman Bertazi <krisman@collabora.co.uk>
Link: http://patchwork.freedesktop.org/patch/msgid/20170127010548.27970-3-krisman@collabora.co.uk
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
drivers/gpu/drm/qxl/qxl_drv.h
drivers/gpu/drm/qxl/qxl_ioctl.c
drivers/gpu/drm/qxl/qxl_kms.c

index a022de20513495837ecfe6d812c556edf9b8a0c1..05a96dde1916e8117162370b1285d0167b6b73d5 100644 (file)
@@ -243,7 +243,6 @@ struct qxl_device;
 
 struct qxl_device {
        struct drm_device               *ddev;
-       struct pci_dev                  *pdev;
        unsigned long flags;
 
        resource_size_t vram_base, vram_size;
index 5a4c8c492683048156b853b7a88fce4582b51b90..7ad5070f2550e015a37fb7a0766dd5d18b437452 100644 (file)
@@ -375,7 +375,7 @@ static int qxl_clientcap_ioctl(struct drm_device *dev, void *data,
        byte = param->index / 8;
        idx = param->index % 8;
 
-       if (qdev->pdev->revision < 4)
+       if (dev->pdev->revision < 4)
                return -ENOSYS;
 
        if (byte >= 58)
index 7632e38493fcbbd05561ec0442f070396d7da9a7..52d1bc1bb0ca4e4018a2a8948e7100a7bd87e16e 100644 (file)
@@ -123,7 +123,6 @@ int qxl_device_init(struct qxl_device *qdev,
        int r, sb;
 
        qdev->ddev = ddev;
-       qdev->pdev = pdev;
        qdev->flags = flags;
 
        mutex_init(&qdev->gem.mutex);