FIRE_RING(screen->channel);
}
+static void
+nv50_texture_barrier(struct pipe_context *pipe)
+{
+ struct nouveau_channel *chan = nv50_context(pipe)->screen->base.channel;
+
+ BEGIN_RING(chan, RING_3D(SERIALIZE), 1);
+ OUT_RING (chan, 0);
+ BEGIN_RING(chan, RING_3D(TEX_CACHE_CTL), 1);
+ OUT_RING (chan, 0x20);
+}
+
void
nv50_default_flush_notify(struct nouveau_channel *chan)
{
pipe->clear = nv50_clear;
pipe->flush = nv50_flush;
+ pipe->texture_barrier = nv50_texture_barrier;
if (!screen->cur_ctx)
screen->cur_ctx = nv50;
FIRE_RING(screen->channel);
}
+static void
+nvc0_texture_barrier(struct pipe_context *pipe)
+{
+ struct nouveau_channel *chan = nvc0_context(pipe)->screen->base.channel;
+
+ IMMED_RING(chan, RING_3D(SERIALIZE), 0);
+ IMMED_RING(chan, RING_3D(TEX_CACHE_CTL), 0);
+}
+
static void
nvc0_context_unreference_resources(struct nvc0_context *nvc0)
{
pipe->clear = nvc0_clear;
pipe->flush = nvc0_flush;
+ pipe->texture_barrier = nvc0_texture_barrier;
if (!screen->cur_ctx)
screen->cur_ctx = nvc0;