Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dledford/rdma
[firefly-linux-kernel-4.4.55.git] / drivers / gpu / drm / nouveau / nouveau_vga.c
index c7592ec8ecb8e430a49e836e05d64914dd2693ac..af89c3665b2abc5e8db0d9b13a9f921879208d5b 100644 (file)
 static unsigned int
 nouveau_vga_set_decode(void *priv, bool state)
 {
-       struct nvif_device *device = &nouveau_drm(priv)->device;
+       struct nouveau_drm *drm = nouveau_drm(priv);
+       struct nvif_object *device = &drm->device.object;
 
-       if (device->info.family == NV_DEVICE_INFO_V0_CURIE &&
-           device->info.chipset >= 0x4c)
+       if (drm->device.info.family == NV_DEVICE_INFO_V0_CURIE &&
+           drm->device.info.chipset >= 0x4c)
                nvif_wr32(device, 0x088060, state);
        else
-       if (device->info.chipset >= 0x40)
+       if (drm->device.info.chipset >= 0x40)
                nvif_wr32(device, 0x088054, state);
        else
                nvif_wr32(device, 0x001854, state);