diff options
author | David Herrmann <dh.herrmann@gmail.com> | 2013-08-13 13:10:30 -0400 |
---|---|---|
committer | David Herrmann <dh.herrmann@gmail.com> | 2014-03-16 07:23:42 -0400 |
commit | 44d847b7439bdea0b6c5640446427daa3ebcc7fa (patch) | |
tree | 53f8bef9b2f863ca0aa8989a98ee7ffa69add128 /drivers/gpu/drm/nouveau/nouveau_gem.c | |
parent | 6796cb16c088905bf3af40548fda68c09e6f6ee5 (diff) |
drm: init TTM dev_mapping in ttm_bo_device_init()
With dev->anon_inode we have a global address_space ready for operation
right from the beginning. Therefore, there is no need to do a delayed
setup with TTM. Instead, set dev_mapping during initialization in
ttm_bo_device_init() and remove any "if (dev_mapping)" conditions.
Cc: Dave Airlie <airlied@redhat.com>
Cc: Ben Skeggs <bskeggs@redhat.com>
Cc: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Cc: Alex Deucher <alexdeucher@gmail.com>
Cc: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_gem.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nouveau_gem.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_gem.c b/drivers/gpu/drm/nouveau/nouveau_gem.c index 5b193b898f5a..c90c0dc0afe8 100644 --- a/drivers/gpu/drm/nouveau/nouveau_gem.c +++ b/drivers/gpu/drm/nouveau/nouveau_gem.c | |||
@@ -228,8 +228,6 @@ nouveau_gem_ioctl_new(struct drm_device *dev, void *data, | |||
228 | struct nouveau_bo *nvbo = NULL; | 228 | struct nouveau_bo *nvbo = NULL; |
229 | int ret = 0; | 229 | int ret = 0; |
230 | 230 | ||
231 | drm->ttm.bdev.dev_mapping = drm->dev->anon_inode->i_mapping; | ||
232 | |||
233 | if (!pfb->memtype_valid(pfb, req->info.tile_flags)) { | 231 | if (!pfb->memtype_valid(pfb, req->info.tile_flags)) { |
234 | NV_ERROR(cli, "bad page flags: 0x%08x\n", req->info.tile_flags); | 232 | NV_ERROR(cli, "bad page flags: 0x%08x\n", req->info.tile_flags); |
235 | return -EINVAL; | 233 | return -EINVAL; |