ilo: rename cache_seqno to uploaded
authorChia-I Wu <olvaffe@gmail.com>
Thu, 20 Jun 2013 03:36:36 +0000 (11:36 +0800)
committerChia-I Wu <olvaffe@gmail.com>
Thu, 20 Jun 2013 03:36:54 +0000 (11:36 +0800)
It has been used as a bool since shader cache rework.

src/gallium/drivers/ilo/ilo_shader.c
src/gallium/drivers/ilo/ilo_shader.h

index 90682d291a231451b6ba511e18fd22462de5b5c6..584e1301f3578685589ce5fd341691c186c8d416 100644 (file)
@@ -74,7 +74,7 @@ ilo_shader_cache_add(struct ilo_shader_cache *shc,
 
    shader->cache = shc;
    LIST_FOR_EACH_ENTRY(sh, &shader->variants, list)
-      sh->cache_seqno = false;
+      sh->uploaded = false;
 
    list_add(&shader->list, &shc->changed);
 }
@@ -118,7 +118,7 @@ ilo_shader_cache_upload_shader(struct ilo_shader_cache *shc,
    LIST_FOR_EACH_ENTRY(sh, &shader->variants, list) {
       int err;
 
-      if (incremental && sh->cache_seqno)
+      if (incremental && sh->uploaded)
          continue;
 
       /* kernels must be aligned to 64-byte */
@@ -128,7 +128,7 @@ ilo_shader_cache_upload_shader(struct ilo_shader_cache *shc,
       if (unlikely(err))
          return -1;
 
-      sh->cache_seqno = true;
+      sh->uploaded = true;
       sh->cache_offset = offset;
 
       offset += sh->kernel_size;
@@ -154,7 +154,7 @@ ilo_shader_cache_get_upload_size(struct ilo_shader_cache *shc,
 
          /* see ilo_shader_cache_upload_shader() */
          LIST_FOR_EACH_ENTRY(sh, &shader->variants, list) {
-            if (!incremental || !sh->cache_seqno)
+            if (!incremental || !sh->uploaded)
                offset = align(offset, 64) + sh->kernel_size;
          }
       }
@@ -165,7 +165,7 @@ ilo_shader_cache_get_upload_size(struct ilo_shader_cache *shc,
 
       /* see ilo_shader_cache_upload_shader() */
       LIST_FOR_EACH_ENTRY(sh, &shader->variants, list) {
-         if (!incremental || !sh->cache_seqno)
+         if (!incremental || !sh->uploaded)
             offset = align(offset, 64) + sh->kernel_size;
       }
    }
index a19f85e4b35279bce386f9127e7cbd5929bfe4b8..9318785adbd700ba0e37535ee1ecb0645f7562ed 100644 (file)
@@ -120,7 +120,7 @@ struct ilo_shader {
    struct list_head list;
 
    /* managed by shader cache */
-   uint32_t cache_seqno;
+   bool uploaded;
    uint32_t cache_offset;
 };