diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2017-12-14 04:19:27 +0300 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2017-12-19 03:16:37 +0300 |
commit | 74a39954a4900a7dea7010e3063e2bf16b23934b (patch) | |
tree | f0f9dca38aec24eacabe89fa6cfb1b06d335627c /drivers/gpu/drm/nouveau/nouveau_bo.c | |
parent | f29f18eb952bc3e71deedf8bd8fc902f66853c48 (diff) | |
download | linux-74a39954a4900a7dea7010e3063e2bf16b23934b.tar.xz |
drm/nouveau: use alternate memory type for system-memory buffers with kind != 0
Fixes bug on Tegra where we'd strip kind information from system memory
(ie. all) buffers, resulting in misrendering.
Behaviour on dGPU should be unchanged.
Reported-by: Thierry Reding <treding@nvidia.com>
Fixes: d7722134b8 ("drm/nouveau: switch over to new memory and vmm interfaces")
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Tested-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_bo.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nouveau_bo.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_bo.c b/drivers/gpu/drm/nouveau/nouveau_bo.c index 42c1827bbb8e..435ff8662cfa 100644 --- a/drivers/gpu/drm/nouveau/nouveau_bo.c +++ b/drivers/gpu/drm/nouveau/nouveau_bo.c @@ -224,7 +224,7 @@ nouveau_bo_new(struct nouveau_cli *cli, u64 size, int align, /* Determine if we can get a cache-coherent map, forcing * uncached mapping if we can't. */ - if (mmu->type[drm->ttm.type_host].type & NVIF_MEM_UNCACHED) + if (!nouveau_drm_use_coherent_gpu_mapping(drm)) nvbo->force_coherent = true; } |