summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/nouveau/nv04_fence.c
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2020-06-22 20:18:06 +1000
committerBen Skeggs <bskeggs@redhat.com>2020-07-24 18:50:58 +1000
commit7aa638cfdb285946f989ac1e132e9c3378f26db6 (patch)
tree763987bdbbaccf913ab07b3871a38c891471f7cc /drivers/gpu/drm/nouveau/nv04_fence.c
parent183b70bbdf61c89afa4aa5945a5cda85d005a2ed (diff)
drm/nouveau/fence: convert emit() to new push macros
Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Reviewed-by: Lyude Paul <lyude@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nv04_fence.c')
-rw-r--r--drivers/gpu/drm/nouveau/nv04_fence.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/gpu/drm/nouveau/nv04_fence.c b/drivers/gpu/drm/nouveau/nv04_fence.c
index c41e82be4893..5b71a5a5cd85 100644
--- a/drivers/gpu/drm/nouveau/nv04_fence.c
+++ b/drivers/gpu/drm/nouveau/nv04_fence.c
@@ -21,12 +21,12 @@
*
* Authors: Ben Skeggs
*/
-
#include "nouveau_drv.h"
#include "nouveau_dma.h"
#include "nouveau_fence.h"
#include <nvif/if0004.h>
+#include <nvif/push006c.h>
struct nv04_fence_chan {
struct nouveau_fence_chan base;
@@ -39,12 +39,11 @@ struct nv04_fence_priv {
static int
nv04_fence_emit(struct nouveau_fence *fence)
{
- struct nouveau_channel *chan = fence->channel;
- int ret = RING_SPACE(chan, 2);
+ struct nvif_push *push = fence->channel->chan.push;
+ int ret = PUSH_WAIT(push, 2);
if (ret == 0) {
- BEGIN_NV04(chan, NvSubSw, 0x0150, 1);
- OUT_RING (chan, fence->base.seqno);
- FIRE_RING (chan);
+ PUSH_NVSQ(push, NV_SW, 0x0150, fence->base.seqno);
+ PUSH_KICK(push);
}
return ret;
}