diff options
Diffstat (limited to 'drivers/gpu/drm/nouveau/dispnv50/head907d.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/dispnv50/head907d.c | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/drivers/gpu/drm/nouveau/dispnv50/head907d.c b/drivers/gpu/drm/nouveau/dispnv50/head907d.c index 24e0d7c7a540..01be2b93a70a 100644 --- a/drivers/gpu/drm/nouveau/dispnv50/head907d.c +++ b/drivers/gpu/drm/nouveau/dispnv50/head907d.c @@ -194,18 +194,19 @@ head907d_core_set(struct nv50_head *head, struct nv50_head_atom *asyh) } } -void +int head907d_olut_clr(struct nv50_head *head) { - struct nv50_dmac *core = &nv50_disp(head->base.base.dev)->core->chan; - u32 *push; - if ((push = evo_wait(core, 4))) { - evo_mthd(push, 0x0448 + (head->base.index * 0x300), 1); - evo_data(push, 0x00000000); - evo_mthd(push, 0x045c + (head->base.index * 0x300), 1); - evo_data(push, 0x00000000); - evo_kick(push, core); - } + struct nvif_push *push = nv50_disp(head->base.base.dev)->core->chan.push; + const int i = head->base.index; + int ret; + + if ((ret = PUSH_WAIT(push, 4))) + return ret; + + PUSH_NVSQ(push, NV907D, 0x0448 + (i * 0x300), 0x00000000); + PUSH_NVSQ(push, NV907D, 0x045c + (i * 0x300), 0x00000000); + return 0; } int |