posix-clock: Fix return code on the poll method's error path
[linux/fpc-iii.git] / drivers / gpu / drm / nouveau / nvkm / subdev / fb / priv.h
blob62b9feb531dc1d5a7d47bf9c7216c43b61739ba4
1 #ifndef __NVKM_FB_PRIV_H__
2 #define __NVKM_FB_PRIV_H__
3 #define nvkm_fb(p) container_of((p), struct nvkm_fb, subdev)
4 #include <subdev/fb.h>
5 struct nvkm_bios;
7 struct nvkm_fb_func {
8 void *(*dtor)(struct nvkm_fb *);
9 void (*init)(struct nvkm_fb *);
10 void (*intr)(struct nvkm_fb *);
12 struct {
13 int regions;
14 void (*init)(struct nvkm_fb *, int i, u32 addr, u32 size,
15 u32 pitch, u32 flags, struct nvkm_fb_tile *);
16 void (*comp)(struct nvkm_fb *, int i, u32 size, u32 flags,
17 struct nvkm_fb_tile *);
18 void (*fini)(struct nvkm_fb *, int i, struct nvkm_fb_tile *);
19 void (*prog)(struct nvkm_fb *, int i, struct nvkm_fb_tile *);
20 } tile;
22 int (*ram_new)(struct nvkm_fb *, struct nvkm_ram **);
24 bool (*memtype_valid)(struct nvkm_fb *, u32 memtype);
27 void nvkm_fb_ctor(const struct nvkm_fb_func *, struct nvkm_device *device,
28 int index, struct nvkm_fb *);
29 int nvkm_fb_new_(const struct nvkm_fb_func *, struct nvkm_device *device,
30 int index, struct nvkm_fb **);
31 int nvkm_fb_bios_memtype(struct nvkm_bios *);
33 bool nv04_fb_memtype_valid(struct nvkm_fb *, u32 memtype);
35 void nv10_fb_tile_init(struct nvkm_fb *, int i, u32 addr, u32 size,
36 u32 pitch, u32 flags, struct nvkm_fb_tile *);
37 void nv10_fb_tile_fini(struct nvkm_fb *, int i, struct nvkm_fb_tile *);
38 void nv10_fb_tile_prog(struct nvkm_fb *, int, struct nvkm_fb_tile *);
40 void nv20_fb_tile_init(struct nvkm_fb *, int i, u32 addr, u32 size,
41 u32 pitch, u32 flags, struct nvkm_fb_tile *);
42 void nv20_fb_tile_fini(struct nvkm_fb *, int i, struct nvkm_fb_tile *);
43 void nv20_fb_tile_prog(struct nvkm_fb *, int, struct nvkm_fb_tile *);
45 void nv30_fb_init(struct nvkm_fb *);
46 void nv30_fb_tile_init(struct nvkm_fb *, int i, u32 addr, u32 size,
47 u32 pitch, u32 flags, struct nvkm_fb_tile *);
49 void nv40_fb_tile_comp(struct nvkm_fb *, int i, u32 size, u32 flags,
50 struct nvkm_fb_tile *);
52 void nv41_fb_init(struct nvkm_fb *);
53 void nv41_fb_tile_prog(struct nvkm_fb *, int, struct nvkm_fb_tile *);
55 void nv44_fb_init(struct nvkm_fb *);
56 void nv44_fb_tile_prog(struct nvkm_fb *, int, struct nvkm_fb_tile *);
58 void nv46_fb_tile_init(struct nvkm_fb *, int i, u32 addr, u32 size,
59 u32 pitch, u32 flags, struct nvkm_fb_tile *);
61 bool gf100_fb_memtype_valid(struct nvkm_fb *, u32);
62 #endif