summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau/nouveau_mem.h
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2017-11-01 03:56:20 +1000
committerBen Skeggs <bskeggs@redhat.com>2017-11-02 13:32:33 +1000
commitd7722134b8254bcee6086230723814cddf9ab54b (patch)
tree7c814c6dd29b328f527e9a7af802e0736fa82ad9 /drivers/gpu/drm/nouveau/nouveau_mem.h
parent10842ba074e95efad1ac7de2f5279910988f3e68 (diff)
drm/nouveau: switch over to new memory and vmm interfaces
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_mem.h')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_mem.h21
1 files changed, 6 insertions, 15 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_mem.h b/drivers/gpu/drm/nouveau/nouveau_mem.h
index 3e34566116c4..f6d039e73812 100644
--- a/drivers/gpu/drm/nouveau/nouveau_mem.h
+++ b/drivers/gpu/drm/nouveau/nouveau_mem.h
@@ -1,12 +1,11 @@
#ifndef __NOUVEAU_MEM_H__
#define __NOUVEAU_MEM_H__
-#include <core/memory.h>
-#include <subdev/fb.h>
-#include <subdev/mmu.h>
-
#include <drm/ttm/ttm_bo_api.h>
struct ttm_dma_tt;
+#include <nvif/mem.h>
+#include <nvif/vmm.h>
+
static inline struct nouveau_mem *
nouveau_mem(struct ttm_mem_reg *reg)
{
@@ -17,16 +16,8 @@ struct nouveau_mem {
struct nouveau_cli *cli;
u8 kind;
u8 comp;
- struct {
- u8 page;
- } mem;
- struct nvkm_vma vma[2];
-
- struct nvkm_mem __mem;
- struct nvkm_mem *_mem;
- struct nvkm_vma bar_vma;
-
- struct nvkm_memory memory;
+ struct nvif_mem mem;
+ struct nvif_vma vma[2];
};
int nouveau_mem_new(struct nouveau_cli *, u8 kind, u8 comp,
@@ -35,5 +26,5 @@ void nouveau_mem_del(struct ttm_mem_reg *);
int nouveau_mem_vram(struct ttm_mem_reg *, bool contig, u8 page);
int nouveau_mem_host(struct ttm_mem_reg *, struct ttm_dma_tt *);
void nouveau_mem_fini(struct nouveau_mem *);
-int nouveau_mem_map(struct nouveau_mem *, struct nvkm_vmm *, struct nvkm_vma *);
+int nouveau_mem_map(struct nouveau_mem *, struct nvif_vmm *, struct nvif_vma *);
#endif