diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2014-08-09 22:10:20 +0400 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2014-08-09 23:12:59 +0400 |
commit | 3ee6f5b5036be4fd4e64be4233f29ee1c552c005 (patch) | |
tree | 32e85ff5165e36304dff76c46a8779bd34728de8 /drivers/gpu/drm/nouveau/nouveau_drm.c | |
parent | b12f0ae9e8dfee55c7757f9c4be3b1154c366754 (diff) | |
download | linux-3ee6f5b5036be4fd4e64be4233f29ee1c552c005.tar.xz |
drm/nouveau: store a pointer to vm in nouveau_cli
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_drm.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nouveau_drm.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_drm.c b/drivers/gpu/drm/nouveau/nouveau_drm.c index 64ec1d34b484..fe99765d9fa0 100644 --- a/drivers/gpu/drm/nouveau/nouveau_drm.c +++ b/drivers/gpu/drm/nouveau/nouveau_drm.c @@ -415,9 +415,11 @@ nouveau_drm_load(struct drm_device *dev, unsigned long flags) if (device->card_type >= NV_50) { ret = nouveau_vm_new(nv_device(drm->device), 0, (1ULL << 40), - 0x1000, &drm->client.base.vm); + 0x1000, &drm->client.vm); if (ret) goto fail_device; + + drm->client.base.vm = drm->client.vm; } ret = nouveau_ttm_init(drm); @@ -725,11 +727,13 @@ nouveau_drm_open(struct drm_device *dev, struct drm_file *fpriv) if (nv_device(drm->device)->card_type >= NV_50) { ret = nouveau_vm_new(nv_device(drm->device), 0, (1ULL << 40), - 0x1000, &cli->base.vm); + 0x1000, &cli->vm); if (ret) { nouveau_cli_destroy(cli); goto out_suspend; } + + cli->base.vm = cli->vm; } fpriv->driver_priv = cli; |