For layered rendering we need to emit per layer rendering commands
lists so we we can end up requiring a fairly large buffer for this
if the number of layers is large enough.
Reviewed-by: Alejandro PiƱeiro <apinheiro@igalia.com>
         if (cl_offset(cl) + space + cl_packet_length(BRANCH) <= cl->size)
                 return;
 
-        struct v3d_bo *new_bo = v3d_bo_alloc(cl->job->v3d->screen, 4096, "CL");
+        struct v3d_bo *new_bo = v3d_bo_alloc(cl->job->v3d->screen, space, "CL");
         assert(space <= new_bo->size);
 
         /* Chain to the new BO from the old one. */