xref: /linux/drivers/gpu/drm/nouveau/nvkm/engine/dma/priv.h (revision d0034a7a4ac7fae708146ac0059b9c47a1543f0d)
1 /* SPDX-License-Identifier: MIT */
2 #ifndef __NVKM_DMA_PRIV_H__
3 #define __NVKM_DMA_PRIV_H__
4 #define nvkm_dma(p) container_of((p), struct nvkm_dma, engine)
5 #include <engine/dma.h>
6 
7 struct nvkm_dmaobj_func {
8 	int (*bind)(struct nvkm_dmaobj *, struct nvkm_gpuobj *, int align,
9 		    struct nvkm_gpuobj **);
10 };
11 
12 int nvkm_dma_new_(const struct nvkm_dma_func *, struct nvkm_device *, enum nvkm_subdev_type, int,
13 		  struct nvkm_dma **);
14 
15 struct nvkm_dma_func {
16 	int (*class_new)(struct nvkm_dma *, const struct nvkm_oclass *,
17 			 void *data, u32 size, struct nvkm_dmaobj **);
18 };
19 #endif
20