]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blame - drivers/gpu/drm/nouveau/include/nvkm/subdev/bar.h
Merge remote-tracking branches 'asoc/topic/max98925', 'asoc/topic/max98927', 'asoc...
[mirror_ubuntu-bionic-kernel.git] / drivers / gpu / drm / nouveau / include / nvkm / subdev / bar.h
CommitLineData
b2441318 1/* SPDX-License-Identifier: GPL-2.0 */
245dcfe9
BS
2#ifndef __NVKM_BAR_H__
3#define __NVKM_BAR_H__
3863c9bc 4#include <core/subdev.h>
245dcfe9 5struct nvkm_vma;
3863c9bc 6
245dcfe9 7struct nvkm_bar {
32932281 8 const struct nvkm_bar_func *func;
5b0c189f 9 struct nvkm_subdev subdev;
3863c9bc 10
32932281 11 spinlock_t lock;
e2a4e78c
AC
12
13 /* whether the BAR supports to be ioremapped WC or should be uncached */
14 bool iomap_uncached;
3863c9bc
BS
15};
16
32932281
BS
17void nvkm_bar_flush(struct nvkm_bar *);
18struct nvkm_vm *nvkm_bar_kmap(struct nvkm_bar *);
19int nvkm_bar_umap(struct nvkm_bar *, u64 size, int type, struct nvkm_vma *);
3863c9bc 20
32932281
BS
21int nv50_bar_new(struct nvkm_device *, int, struct nvkm_bar **);
22int g84_bar_new(struct nvkm_device *, int, struct nvkm_bar **);
23int gf100_bar_new(struct nvkm_device *, int, struct nvkm_bar **);
24int gk20a_bar_new(struct nvkm_device *, int, struct nvkm_bar **);
3863c9bc 25#endif