1 /* SPDX-License-Identifier: MIT */
2 #ifndef __NVKM_SW_PRIV_H__
3 #define __NVKM_SW_PRIV_H__
4 #define nvkm_sw(p) container_of((p), struct nvkm_sw, engine)
5 #include <engine/sw.h>
6 struct nvkm_sw_chan;
7 
8 int nvkm_sw_new_(const struct nvkm_sw_func *, struct nvkm_device *, enum nvkm_subdev_type, int,
9 		 struct nvkm_sw **);
10 
11 struct nvkm_sw_chan_sclass {
12 	int (*ctor)(struct nvkm_sw_chan *, const struct nvkm_oclass *,
13 		    void *data, u32 size, struct nvkm_object **);
14 	struct nvkm_sclass base;
15 };
16 
17 struct nvkm_sw_func {
18 	int (*chan_new)(struct nvkm_sw *, struct nvkm_chan *,
19 			const struct nvkm_oclass *, struct nvkm_object **);
20 	const struct nvkm_sw_chan_sclass sclass[];
21 };
22 #endif
23