freedreno: fix off-by-one error in BEGIN_RING()

Signed-off-by: Rob Clark <robdclark@gmail.com>
This commit is contained in:
Rob Clark 2018-10-13 12:34:09 -04:00
parent 669dd22983
commit cbf9fe50b5

View File

@ -274,7 +274,7 @@ OUT_RB(struct fd_ringbuffer *ring, struct fd_ringbuffer *target)
static inline void BEGIN_RING(struct fd_ringbuffer *ring, uint32_t ndwords)
{
if (ring->cur + ndwords >= ring->end)
if (ring->cur + ndwords > ring->end)
fd_ringbuffer_grow(ring, ndwords);
}