On Mon, Aug 11, 2014 at 8:29 PM, Kristian Høgsberg <k...@bitplanet.net> wrote:
> diff --git a/src/mesa/drivers/dri/i965/intel_tex_copy.c 
> b/src/mesa/drivers/dri/i965/intel_tex_copy.c
> index 97f1569..2456080 100644
> --- a/src/mesa/drivers/dri/i965/intel_tex_copy.c
> +++ b/src/mesa/drivers/dri/i965/intel_tex_copy.c
> @@ -79,6 +79,8 @@ intel_copy_texsubimage(struct brw_context *brw,
>     int dst_slice = slice + intelImage->base.Base.Face +
>                     intelImage->base.Base.TexObject->MinLayer;
>
> +   _mesa_unlock_texture(&brw->ctx, intelImage->base.Base.TexObject);
> +
>     /* blit from src buffer to texture */
>     if (!intel_miptree_blit(brw,
>                             irb->mt, irb->mt_level, irb->mt_layer,
> @@ -89,6 +91,8 @@ intel_copy_texsubimage(struct brw_context *brw,
>        return false;
>     }
>
> +   _mesa_lock_texture(&brw->ctx, intelImage->base.Base.TexObject);
> +
>     return true;
>  }

Just happened to notice in some aimless scrolling... you return above,
so in one path you don't relock the texture, but in the other you do.
Usually that sort of thing leads to trouble, but perhaps there's
something going on here which makes it OK. If that's the case,
probably deserves a comment.

  -ilia
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to