]> git.ipfire.org Git - thirdparty/kernel/linux.git/blob - drivers/gpu/drm/nouveau/include/nvkm/core/oproxy.h
License cleanup: add SPDX GPL-2.0 license identifier to files with no license
[thirdparty/kernel/linux.git] / drivers / gpu / drm / nouveau / include / nvkm / core / oproxy.h
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef __NVKM_OPROXY_H__
3 #define __NVKM_OPROXY_H__
4 #define nvkm_oproxy(p) container_of((p), struct nvkm_oproxy, base)
5 #include <core/object.h>
6
7 struct nvkm_oproxy {
8 const struct nvkm_oproxy_func *func;
9 struct nvkm_object base;
10 struct nvkm_object *object;
11 };
12
13 struct nvkm_oproxy_func {
14 void (*dtor[2])(struct nvkm_oproxy *);
15 int (*init[2])(struct nvkm_oproxy *);
16 int (*fini[2])(struct nvkm_oproxy *, bool suspend);
17 };
18
19 void nvkm_oproxy_ctor(const struct nvkm_oproxy_func *,
20 const struct nvkm_oclass *, struct nvkm_oproxy *);
21 int nvkm_oproxy_new_(const struct nvkm_oproxy_func *,
22 const struct nvkm_oclass *, struct nvkm_oproxy **);
23 #endif