Skip to content

Commit 61671d8

Browse files
Ben SkeggsDanilo Krummrich
authored andcommitted
drm/nouveau/kms: remove push pointer from nv50_dmac
The struct itself lives in nv50_dmac already, just use that. Signed-off-by: Ben Skeggs <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 723388b commit 61671d8

30 files changed

+122
-124
lines changed

drivers/gpu/drm/nouveau/dispnv50/base507c.c

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
int
3636
base507c_update(struct nv50_wndw *wndw, u32 *interlock)
3737
{
38-
struct nvif_push *push = wndw->wndw.push;
38+
struct nvif_push *push = &wndw->wndw.push;
3939
int ret;
4040

4141
if ((ret = PUSH_WAIT(push, 2)))
@@ -48,7 +48,7 @@ base507c_update(struct nv50_wndw *wndw, u32 *interlock)
4848
int
4949
base507c_image_clr(struct nv50_wndw *wndw)
5050
{
51-
struct nvif_push *push = wndw->wndw.push;
51+
struct nvif_push *push = &wndw->wndw.push;
5252
int ret;
5353

5454
if ((ret = PUSH_WAIT(push, 4)))
@@ -65,7 +65,7 @@ base507c_image_clr(struct nv50_wndw *wndw)
6565
static int
6666
base507c_image_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
6767
{
68-
struct nvif_push *push = wndw->wndw.push;
68+
struct nvif_push *push = &wndw->wndw.push;
6969
int ret;
7070

7171
if ((ret = PUSH_WAIT(push, 13)))
@@ -118,7 +118,7 @@ base507c_image_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
118118
int
119119
base507c_xlut_clr(struct nv50_wndw *wndw)
120120
{
121-
struct nvif_push *push = wndw->wndw.push;
121+
struct nvif_push *push = &wndw->wndw.push;
122122
int ret;
123123

124124
if ((ret = PUSH_WAIT(push, 2)))
@@ -132,7 +132,7 @@ base507c_xlut_clr(struct nv50_wndw *wndw)
132132
int
133133
base507c_xlut_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
134134
{
135-
struct nvif_push *push = wndw->wndw.push;
135+
struct nvif_push *push = &wndw->wndw.push;
136136
int ret;
137137

138138
if ((ret = PUSH_WAIT(push, 2)))
@@ -158,7 +158,7 @@ base507c_ntfy_wait_begun(struct nouveau_bo *bo, u32 offset,
158158
int
159159
base507c_ntfy_clr(struct nv50_wndw *wndw)
160160
{
161-
struct nvif_push *push = wndw->wndw.push;
161+
struct nvif_push *push = &wndw->wndw.push;
162162
int ret;
163163

164164
if ((ret = PUSH_WAIT(push, 2)))
@@ -171,7 +171,7 @@ base507c_ntfy_clr(struct nv50_wndw *wndw)
171171
int
172172
base507c_ntfy_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
173173
{
174-
struct nvif_push *push = wndw->wndw.push;
174+
struct nvif_push *push = &wndw->wndw.push;
175175
int ret;
176176

177177
if ((ret = PUSH_WAIT(push, 3)))
@@ -195,7 +195,7 @@ base507c_ntfy_reset(struct nouveau_bo *bo, u32 offset)
195195
int
196196
base507c_sema_clr(struct nv50_wndw *wndw)
197197
{
198-
struct nvif_push *push = wndw->wndw.push;
198+
struct nvif_push *push = &wndw->wndw.push;
199199
int ret;
200200

201201
if ((ret = PUSH_WAIT(push, 2)))
@@ -208,7 +208,7 @@ base507c_sema_clr(struct nv50_wndw *wndw)
208208
int
209209
base507c_sema_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
210210
{
211-
struct nvif_push *push = wndw->wndw.push;
211+
struct nvif_push *push = &wndw->wndw.push;
212212
int ret;
213213

214214
if ((ret = PUSH_WAIT(push, 5)))

drivers/gpu/drm/nouveau/dispnv50/base827c.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
static int
2929
base827c_image_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
3030
{
31-
struct nvif_push *push = wndw->wndw.push;
31+
struct nvif_push *push = &wndw->wndw.push;
3232
int ret;
3333

3434
if ((ret = PUSH_WAIT(push, 13)))

drivers/gpu/drm/nouveau/dispnv50/base907c.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
static int
2929
base907c_image_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
3030
{
31-
struct nvif_push *push = wndw->wndw.push;
31+
struct nvif_push *push = &wndw->wndw.push;
3232
int ret;
3333

3434
if ((ret = PUSH_WAIT(push, 10)))
@@ -65,7 +65,7 @@ base907c_image_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
6565
static int
6666
base907c_xlut_clr(struct nv50_wndw *wndw)
6767
{
68-
struct nvif_push *push = wndw->wndw.push;
68+
struct nvif_push *push = &wndw->wndw.push;
6969
int ret;
7070

7171
if ((ret = PUSH_WAIT(push, 6)))
@@ -84,7 +84,7 @@ base907c_xlut_clr(struct nv50_wndw *wndw)
8484
static int
8585
base907c_xlut_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
8686
{
87-
struct nvif_push *push = wndw->wndw.push;
87+
struct nvif_push *push = &wndw->wndw.push;
8888
int ret;
8989

9090
if ((ret = PUSH_WAIT(push, 6)))
@@ -156,7 +156,7 @@ base907c_csc(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw,
156156
static int
157157
base907c_csc_clr(struct nv50_wndw *wndw)
158158
{
159-
struct nvif_push *push = wndw->wndw.push;
159+
struct nvif_push *push = &wndw->wndw.push;
160160
int ret;
161161

162162
if ((ret = PUSH_WAIT(push, 2)))
@@ -170,7 +170,7 @@ base907c_csc_clr(struct nv50_wndw *wndw)
170170
static int
171171
base907c_csc_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
172172
{
173-
struct nvif_push *push = wndw->wndw.push;
173+
struct nvif_push *push = &wndw->wndw.push;
174174
int ret;
175175

176176
if ((ret = PUSH_WAIT(push, 13)))

drivers/gpu/drm/nouveau/dispnv50/core507d.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
int
3434
core507d_update(struct nv50_core *core, u32 *interlock, bool ntfy)
3535
{
36-
struct nvif_push *push = core->chan.push;
36+
struct nvif_push *push = &core->chan.push;
3737
int ret;
3838

3939
if ((ret = PUSH_WAIT(push, (ntfy ? 2 : 0) + 3)))
@@ -80,7 +80,7 @@ core507d_ntfy_init(struct nouveau_bo *bo, u32 offset)
8080
int
8181
core507d_read_caps(struct nv50_disp *disp)
8282
{
83-
struct nvif_push *push = disp->core->chan.push;
83+
struct nvif_push *push = &disp->core->chan.push;
8484
int ret;
8585

8686
ret = PUSH_WAIT(push, 6);
@@ -130,7 +130,7 @@ core507d_caps_init(struct nouveau_drm *drm, struct nv50_disp *disp)
130130
int
131131
core507d_init(struct nv50_core *core)
132132
{
133-
struct nvif_push *push = core->chan.push;
133+
struct nvif_push *push = &core->chan.push;
134134
int ret;
135135

136136
if ((ret = PUSH_WAIT(push, 2)))

drivers/gpu/drm/nouveau/dispnv50/corec37d.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
int
3434
corec37d_wndw_owner(struct nv50_core *core)
3535
{
36-
struct nvif_push *push = core->chan.push;
36+
struct nvif_push *push = &core->chan.push;
3737
const u32 windows = 8; /*XXX*/
3838
int ret, i;
3939

@@ -51,7 +51,7 @@ corec37d_wndw_owner(struct nv50_core *core)
5151
int
5252
corec37d_update(struct nv50_core *core, u32 *interlock, bool ntfy)
5353
{
54-
struct nvif_push *push = core->chan.push;
54+
struct nvif_push *push = &core->chan.push;
5555
int ret;
5656

5757
if ((ret = PUSH_WAIT(push, (ntfy ? 2 * 2 : 0) + 5)))
@@ -127,7 +127,7 @@ int corec37d_caps_init(struct nouveau_drm *drm, struct nv50_disp *disp)
127127
static int
128128
corec37d_init(struct nv50_core *core)
129129
{
130-
struct nvif_push *push = core->chan.push;
130+
struct nvif_push *push = &core->chan.push;
131131
const u32 windows = 8; /*XXX*/
132132
int ret, i;
133133

drivers/gpu/drm/nouveau/dispnv50/corec57d.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
static int
3030
corec57d_init(struct nv50_core *core)
3131
{
32-
struct nvif_push *push = core->chan.push;
32+
struct nvif_push *push = &core->chan.push;
3333
const u32 windows = 8; /*XXX*/
3434
int ret, i;
3535

drivers/gpu/drm/nouveau/dispnv50/crc907d.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ static int
2626
crc907d_set_src(struct nv50_head *head, int or, enum nv50_crc_source_type source,
2727
struct nv50_crc_notifier_ctx *ctx)
2828
{
29-
struct nvif_push *push = nv50_disp(head->base.base.dev)->core->chan.push;
29+
struct nvif_push *push = &nv50_disp(head->base.base.dev)->core->chan.push;
3030
const int i = head->base.index;
3131
u32 crc_args = NVDEF(NV907D, HEAD_SET_CRC_CONTROL, CONTROLLING_CHANNEL, CORE) |
3232
NVDEF(NV907D, HEAD_SET_CRC_CONTROL, EXPECT_BUFFER_COLLAPSE, FALSE) |
@@ -74,7 +74,7 @@ crc907d_set_src(struct nv50_head *head, int or, enum nv50_crc_source_type source
7474
static int
7575
crc907d_set_ctx(struct nv50_head *head, struct nv50_crc_notifier_ctx *ctx)
7676
{
77-
struct nvif_push *push = nv50_disp(head->base.base.dev)->core->chan.push;
77+
struct nvif_push *push = &nv50_disp(head->base.base.dev)->core->chan.push;
7878
const int i = head->base.index;
7979
int ret;
8080

drivers/gpu/drm/nouveau/dispnv50/crcc37d.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ static int
1515
crcc37d_set_src(struct nv50_head *head, int or, enum nv50_crc_source_type source,
1616
struct nv50_crc_notifier_ctx *ctx)
1717
{
18-
struct nvif_push *push = nv50_disp(head->base.base.dev)->core->chan.push;
18+
struct nvif_push *push = &nv50_disp(head->base.base.dev)->core->chan.push;
1919
const int i = head->base.index;
2020
u32 crc_args = NVVAL(NVC37D, HEAD_SET_CRC_CONTROL, CONTROLLING_CHANNEL, i * 4) |
2121
NVDEF(NVC37D, HEAD_SET_CRC_CONTROL, EXPECT_BUFFER_COLLAPSE, FALSE) |
@@ -53,7 +53,7 @@ crcc37d_set_src(struct nv50_head *head, int or, enum nv50_crc_source_type source
5353

5454
int crcc37d_set_ctx(struct nv50_head *head, struct nv50_crc_notifier_ctx *ctx)
5555
{
56-
struct nvif_push *push = nv50_disp(head->base.base.dev)->core->chan.push;
56+
struct nvif_push *push = &nv50_disp(head->base.base.dev)->core->chan.push;
5757
const int i = head->base.index;
5858
int ret;
5959

drivers/gpu/drm/nouveau/dispnv50/crcc57d.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
static int crcc57d_set_src(struct nv50_head *head, int or, enum nv50_crc_source_type source,
1414
struct nv50_crc_notifier_ctx *ctx)
1515
{
16-
struct nvif_push *push = nv50_disp(head->base.base.dev)->core->chan.push;
16+
struct nvif_push *push = &nv50_disp(head->base.base.dev)->core->chan.push;
1717
const int i = head->base.index;
1818
u32 crc_args = NVDEF(NVC57D, HEAD_SET_CRC_CONTROL, CONTROLLING_CHANNEL, CORE) |
1919
NVDEF(NVC57D, HEAD_SET_CRC_CONTROL, EXPECT_BUFFER_COLLAPSE, FALSE) |

drivers/gpu/drm/nouveau/dispnv50/dac507d.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ static int
2929
dac507d_ctrl(struct nv50_core *core, int or, u32 ctrl,
3030
struct nv50_head_atom *asyh)
3131
{
32-
struct nvif_push *push = core->chan.push;
32+
struct nvif_push *push = &core->chan.push;
3333
u32 sync = 0;
3434
int ret;
3535

0 commit comments

Comments
 (0)