These changes are the raw update to linux-4.4.6-rt14. Kernel sources
[kvmfornfv.git] / kernel / drivers / gpu / drm / nouveau / include / nvkm / subdev / bar.h
1 #ifndef __NVKM_BAR_H__
2 #define __NVKM_BAR_H__
3 #include <core/subdev.h>
4 struct nvkm_vma;
5
6 struct nvkm_bar {
7         const struct nvkm_bar_func *func;
8         struct nvkm_subdev subdev;
9
10         spinlock_t lock;
11
12         /* whether the BAR supports to be ioremapped WC or should be uncached */
13         bool iomap_uncached;
14 };
15
16 void nvkm_bar_flush(struct nvkm_bar *);
17 struct nvkm_vm *nvkm_bar_kmap(struct nvkm_bar *);
18 int nvkm_bar_umap(struct nvkm_bar *, u64 size, int type, struct nvkm_vma *);
19
20 int nv50_bar_new(struct nvkm_device *, int, struct nvkm_bar **);
21 int g84_bar_new(struct nvkm_device *, int, struct nvkm_bar **);
22 int gf100_bar_new(struct nvkm_device *, int, struct nvkm_bar **);
23 int gk20a_bar_new(struct nvkm_device *, int, struct nvkm_bar **);
24 #endif