Commit 0a4693e8 authored by Ben Skeggs's avatar Ben Skeggs

drm/nouveau/kms/nv50-: convert wndw scale_set() to new push macros

Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
Reviewed-by: default avatarLyude Paul <lyude@redhat.com>
parent 8944d8b3
...@@ -10,7 +10,7 @@ int ovly507e_acquire(struct nv50_wndw *, struct nv50_wndw_atom *, ...@@ -10,7 +10,7 @@ int ovly507e_acquire(struct nv50_wndw *, struct nv50_wndw_atom *,
struct nv50_head_atom *); struct nv50_head_atom *);
void ovly507e_release(struct nv50_wndw *, struct nv50_wndw_atom *, void ovly507e_release(struct nv50_wndw *, struct nv50_wndw_atom *,
struct nv50_head_atom *); struct nv50_head_atom *);
void ovly507e_scale_set(struct nv50_wndw *, struct nv50_wndw_atom *); int ovly507e_scale_set(struct nv50_wndw *, struct nv50_wndw_atom *);
void ovly507e_update(struct nv50_wndw *, u32 *); void ovly507e_update(struct nv50_wndw *, u32 *);
extern const u32 ovly827e_format[]; extern const u32 ovly827e_format[];
......
...@@ -41,17 +41,19 @@ ovly507e_update(struct nv50_wndw *wndw, u32 *interlock) ...@@ -41,17 +41,19 @@ ovly507e_update(struct nv50_wndw *wndw, u32 *interlock)
} }
} }
void int
ovly507e_scale_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw) ovly507e_scale_set(struct nv50_wndw *wndw, struct nv50_wndw_atom *asyw)
{ {
u32 *push; struct nvif_push *push = wndw->wndw.push;
if ((push = evo_wait(&wndw->wndw, 4))) { int ret;
evo_mthd(push, 0x00e0, 3);
evo_data(push, asyw->scale.sy << 16 | asyw->scale.sx); if ((ret = PUSH_WAIT(push, 4)))
evo_data(push, asyw->scale.sh << 16 | asyw->scale.sw); return ret;
evo_data(push, asyw->scale.dw);
evo_kick(push, &wndw->wndw); PUSH_NVSQ(push, NV507E, 0x00e0, asyw->scale.sy << 16 | asyw->scale.sx,
} 0x00e4, asyw->scale.sh << 16 | asyw->scale.sw,
0x00e8, asyw->scale.dw);
return 0;
} }
static int static int
......
...@@ -76,7 +76,7 @@ struct nv50_wndw_func { ...@@ -76,7 +76,7 @@ struct nv50_wndw_func {
int (*xlut_clr)(struct nv50_wndw *); int (*xlut_clr)(struct nv50_wndw *);
int (*image_set)(struct nv50_wndw *, struct nv50_wndw_atom *); int (*image_set)(struct nv50_wndw *, struct nv50_wndw_atom *);
int (*image_clr)(struct nv50_wndw *); int (*image_clr)(struct nv50_wndw *);
void (*scale_set)(struct nv50_wndw *, struct nv50_wndw_atom *); int (*scale_set)(struct nv50_wndw *, struct nv50_wndw_atom *);
void (*blend_set)(struct nv50_wndw *, struct nv50_wndw_atom *); void (*blend_set)(struct nv50_wndw *, struct nv50_wndw_atom *);
void (*update)(struct nv50_wndw *, u32 *interlock); void (*update)(struct nv50_wndw *, u32 *interlock);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment