ilo: pipe_texture::usage is not a bitfield
authorChia-I Wu <olvaffe@gmail.com>
Thu, 20 Feb 2014 08:59:24 +0000 (16:59 +0800)
committerChia-I Wu <olvaffe@gmail.com>
Sat, 22 Feb 2014 14:45:12 +0000 (22:45 +0800)
It happens to work because PIPE_USAGE_STAGING is 0x100.

src/gallium/drivers/ilo/ilo_resource.c

index f6d3f747407e80ca320717ae82c76be87c5753e9..cb8e1cbbb53d2106893e606e7b5470ce85036476 100644 (file)
@@ -608,7 +608,7 @@ tex_layout_init_hiz(struct tex_layout *layout)
    layout->hiz = true;
 
    /* no point in having HiZ */
-   if (templ->usage & PIPE_USAGE_STAGING)
+   if (templ->usage == PIPE_USAGE_STAGING)
       layout->hiz = false;
 
    if (layout->dev->gen == ILO_GEN(6)) {