From: Marek Vasut Date: Mon, 18 Nov 2019 18:12:49 +0000 (+0100) Subject: etnaviv: Replace bitwise OR with logical OR X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f51ee564f5739b0b668358f9a8fe6ef990eb2210;p=mesa.git etnaviv: Replace bitwise OR with logical OR The test here is testing whether either variable is non-zero. While currently the test works fine, it's fragile. Replace it with logical OR to avoid the fragility. Signed-off-by: Marek Vasut Reviewed-by: Christian Gmeiner --- diff --git a/src/gallium/drivers/etnaviv/etnaviv_shader.c b/src/gallium/drivers/etnaviv/etnaviv_shader.c index 0415538e287..937a83c8979 100644 --- a/src/gallium/drivers/etnaviv/etnaviv_shader.c +++ b/src/gallium/drivers/etnaviv/etnaviv_shader.c @@ -212,7 +212,7 @@ etna_link_shaders(struct etna_context *ctx, struct compiled_shader_state *cs, cs->ps_inst_mem_size = fs->code_size; cs->PS_INST_MEM = fs->code; - if (vs->needs_icache | fs->needs_icache) { + if (vs->needs_icache || fs->needs_icache) { /* If either of the shaders needs ICACHE, we use it for both. It is * either switched on or off for the entire shader processor. */