Commit | Line | Data |
---|---|---|
b7019ac5 | 1 | /* SPDX-License-Identifier: MIT */ |
b8bf04e1 BS |
2 | #ifndef __NV20_GR_H__ |
3 | #define __NV20_GR_H__ | |
27f3d6cf BS |
4 | #define nv20_gr(p) container_of((p), struct nv20_gr, base) |
5 | #include "priv.h" | |
b8bf04e1 | 6 | |
bfee3f3d | 7 | struct nv20_gr { |
e3c71eb2 | 8 | struct nvkm_gr base; |
227c95d9 | 9 | struct nvkm_memory *ctxtab; |
b8bf04e1 BS |
10 | }; |
11 | ||
864d37c3 BS |
12 | int nv20_gr_new_(const struct nvkm_gr_func *, struct nvkm_device *, enum nvkm_subdev_type, int, |
13 | struct nvkm_gr **); | |
c85ee6ca BS |
14 | void *nv20_gr_dtor(struct nvkm_gr *); |
15 | int nv20_gr_oneinit(struct nvkm_gr *); | |
16 | int nv20_gr_init(struct nvkm_gr *); | |
17 | void nv20_gr_intr(struct nvkm_gr *); | |
18 | void nv20_gr_tile(struct nvkm_gr *, int, struct nvkm_fb_tile *); | |
19 | ||
20 | int nv30_gr_init(struct nvkm_gr *); | |
21 | ||
27f3d6cf | 22 | #define nv20_gr_chan(p) container_of((p), struct nv20_gr_chan, object) |
4246b92c | 23 | #include <core/object.h> |
27f3d6cf | 24 | |
b8bf04e1 | 25 | struct nv20_gr_chan { |
27f3d6cf BS |
26 | struct nvkm_object object; |
27 | struct nv20_gr *gr; | |
b8bf04e1 | 28 | int chid; |
27f3d6cf | 29 | struct nvkm_memory *inst; |
b8bf04e1 BS |
30 | }; |
31 | ||
27f3d6cf | 32 | void *nv20_gr_chan_dtor(struct nvkm_object *); |
c85ee6ca BS |
33 | int nv20_gr_chan_init(struct nvkm_object *); |
34 | int nv20_gr_chan_fini(struct nvkm_object *, bool); | |
b8bf04e1 | 35 | #endif |