xref: /netbsd-src/sys/external/bsd/drm2/dist/drm/nouveau/nvkm/engine/fifo/nv04.h (revision 41ec02673d281bbb3d38e6c78504ce6e30c228c1)
1 /*	$NetBSD: nv04.h,v 1.3 2021/12/18 23:45:35 riastradh Exp $	*/
2 
3 /* SPDX-License-Identifier: MIT */
4 #ifndef __NV04_FIFO_H__
5 #define __NV04_FIFO_H__
6 #define nv04_fifo(p) container_of((p), struct nv04_fifo, base)
7 #include "priv.h"
8 
9 struct nv04_fifo_ramfc {
10 	unsigned bits:6;
11 	unsigned ctxs:5;
12 	unsigned ctxp:8;
13 	unsigned regs:5;
14 	unsigned regp;
15 };
16 
17 struct nv04_fifo {
18 	struct nvkm_fifo base;
19 	const struct nv04_fifo_ramfc *ramfc;
20 };
21 
22 int nv04_fifo_new_(const struct nvkm_fifo_func *, struct nvkm_device *,
23 		   int index, int nr, const struct nv04_fifo_ramfc *,
24 		   struct nvkm_fifo **);
25 void nv04_fifo_init(struct nvkm_fifo *);
26 #endif
27