[Mesa-dev] [PATCH mesa] i965: searching the cache doesn't need to modify it
Eric Engestrom
eric.engestrom at intel.com
Tue Aug 7 10:59:13 UTC 2018
Signed-off-by: Eric Engestrom <eric.engestrom at intel.com>
---
src/mesa/drivers/dri/i965/brw_program_cache.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_program_cache.c b/src/mesa/drivers/dri/i965/brw_program_cache.c
index 600b0611c8b89095e393..dd8b1cdb8f134ed05193 100644
--- a/src/mesa/drivers/dri/i965/brw_program_cache.c
+++ b/src/mesa/drivers/dri/i965/brw_program_cache.c
@@ -142,11 +142,11 @@ brw_cache_item_equals(const struct brw_cache_item *a,
(memcmp(a->key, b->key, a->key_size) == 0);
}
-static struct brw_cache_item *
-search_cache(struct brw_cache *cache, GLuint hash,
- struct brw_cache_item *lookup)
+static const struct brw_cache_item *
+search_cache(const struct brw_cache *cache, GLuint hash,
+ const struct brw_cache_item *lookup)
{
- struct brw_cache_item *c;
+ const struct brw_cache_item *c;
#if 0
int bucketcount = 0;
@@ -198,7 +198,7 @@ brw_search_cache(struct brw_cache *cache, enum brw_cache_id cache_id,
const void *key, GLuint key_size, uint32_t *inout_offset,
void *inout_prog_data, bool flag_state)
{
- struct brw_cache_item *item;
+ const struct brw_cache_item *item;
struct brw_cache_item lookup;
GLuint hash;
--
Cheers,
Eric
More information about the mesa-dev
mailing list