From 105f756c503846442537016dedeab0e433820041 Mon Sep 17 00:00:00 2001 From: Ben Skeggs Date: Mon, 22 Jun 2020 19:36:18 +1000 Subject: [PATCH] drm/nouveau/kms/nv04: convert page_flip_emit() to new push macros Signed-off-by: Ben Skeggs Reviewed-by: Lyude Paul --- drivers/gpu/drm/nouveau/dispnv04/crtc.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/nouveau/dispnv04/crtc.c b/drivers/gpu/drm/nouveau/dispnv04/crtc.c index 3d33484..94782ba 100644 --- a/drivers/gpu/drm/nouveau/dispnv04/crtc.c +++ b/drivers/gpu/drm/nouveau/dispnv04/crtc.c @@ -44,6 +44,8 @@ #include #include +#include + #include #include @@ -1105,6 +1107,7 @@ nv04_page_flip_emit(struct nouveau_channel *chan, struct nouveau_fence_chan *fctx = chan->fence; struct nouveau_drm *drm = chan->drm; struct drm_device *dev = drm->dev; + struct nvif_push *push = chan->chan.push; unsigned long flags; int ret; @@ -1119,13 +1122,12 @@ nv04_page_flip_emit(struct nouveau_channel *chan, goto fail; /* Emit the pageflip */ - ret = RING_SPACE(chan, 2); + ret = PUSH_WAIT(push, 2); if (ret) goto fail; - BEGIN_NV04(chan, NvSubSw, NV_SW_PAGE_FLIP, 1); - OUT_RING (chan, 0x00000000); - FIRE_RING (chan); + PUSH_NVSQ(push, NV_SW, NV_SW_PAGE_FLIP, 0x00000000); + PUSH_KICK(push); ret = nouveau_fence_new(chan, false, pfence); if (ret) -- 2.7.4