summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/nouveau/nvkm/engine/device
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2015-08-20 04:54:20 (GMT)
committerBen Skeggs <bskeggs@redhat.com>2015-08-28 02:40:44 (GMT)
commit8de65bd0901e2ee7a485a158bfe9e4631cc00644 (patch)
treeca9033713ff66a001a1697fa966cf86500094328 /drivers/gpu/drm/nouveau/nvkm/engine/device
parent551d341755e2ade4a915d889524a4187f2cd210e (diff)
downloadlinux-8de65bd0901e2ee7a485a158bfe9e4631cc00644.tar.xz
drm/nouveau/devinit: run devinit scripts right after preinit
This ensures we have a valid mask of disabled engines before we start trying to execute fini()/init() on the subdevs, potentially touching devices that don't exist. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nvkm/engine/device')
-rw-r--r--drivers/gpu/drm/nouveau/nvkm/engine/device/base.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/device/base.c b/drivers/gpu/drm/nouveau/nvkm/engine/device/base.c
index 2d8ef80..99a0769 100644
--- a/drivers/gpu/drm/nouveau/nvkm/engine/device/base.c
+++ b/drivers/gpu/drm/nouveau/nvkm/engine/device/base.c
@@ -2167,7 +2167,9 @@ nvkm_device_preinit(struct nvkm_device *device)
}
}
- /*XXX: devinit */
+ ret = nvkm_devinit_post(device->devinit, &device->disable_mask);
+ if (ret)
+ goto fail;
time = ktime_to_us(ktime_get()) - time;
nvdev_trace(device, "preinit completed in %lldus\n", time);