aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author[email protected] <[email protected]>2016-07-30 09:49:59 +0200
committerRob Clark <[email protected]>2016-07-30 09:25:42 -0400
commite713a9e61311249dfd6f76f3ab73da951b81239d (patch)
tree559eb38f228405b22d93c1aa283b5cc467fc0eb5
parent43492c7f2c56b618903b0f802071a6462ea8a435 (diff)
freedreno/a4xx: fix comparison out of range warnings
Signed-off-by: Francesco Ansanelli <[email protected]> Signed-off-by: Rob Clark <[email protected]>
-rw-r--r--src/gallium/drivers/freedreno/a4xx/fd4_screen.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/gallium/drivers/freedreno/a4xx/fd4_screen.c b/src/gallium/drivers/freedreno/a4xx/fd4_screen.c
index 57fecf14724..aa60658d7c6 100644
--- a/src/gallium/drivers/freedreno/a4xx/fd4_screen.c
+++ b/src/gallium/drivers/freedreno/a4xx/fd4_screen.c
@@ -52,14 +52,14 @@ fd4_screen_is_format_supported(struct pipe_screen *pscreen,
}
if ((usage & PIPE_BIND_VERTEX_BUFFER) &&
- (fd4_pipe2vtx(format) != ~0u)) {
+ (fd4_pipe2vtx(format) != (enum a4xx_vtx_fmt)~0)) {
retval |= PIPE_BIND_VERTEX_BUFFER;
}
if ((usage & PIPE_BIND_SAMPLER_VIEW) &&
(target == PIPE_BUFFER ||
util_format_get_blocksize(format) != 12) &&
- (fd4_pipe2tex(format) != ~0u)) {
+ (fd4_pipe2tex(format) != (enum a4xx_tex_fmt)~0)) {
retval |= PIPE_BIND_SAMPLER_VIEW;
}
@@ -67,8 +67,8 @@ fd4_screen_is_format_supported(struct pipe_screen *pscreen,
PIPE_BIND_DISPLAY_TARGET |
PIPE_BIND_SCANOUT |
PIPE_BIND_SHARED)) &&
- (fd4_pipe2color(format) != ~0u) &&
- (fd4_pipe2tex(format) != ~0u)) {
+ (fd4_pipe2color(format) != (enum a4xx_color_fmt)~0) &&
+ (fd4_pipe2tex(format) != (enum a4xx_tex_fmt)~0)) {
retval |= usage & (PIPE_BIND_RENDER_TARGET |
PIPE_BIND_DISPLAY_TARGET |
PIPE_BIND_SCANOUT |
@@ -76,13 +76,13 @@ fd4_screen_is_format_supported(struct pipe_screen *pscreen,
}
if ((usage & PIPE_BIND_DEPTH_STENCIL) &&
- (fd4_pipe2depth(format) != ~0u) &&
- (fd4_pipe2tex(format) != ~0u)) {
+ (fd4_pipe2depth(format) != (enum a4xx_depth_format)~0) &&
+ (fd4_pipe2tex(format) != (enum a4xx_tex_fmt)~0)) {
retval |= PIPE_BIND_DEPTH_STENCIL;
}
if ((usage & PIPE_BIND_INDEX_BUFFER) &&
- (fd_pipe2index(format) != ~0u)) {
+ (fd_pipe2index(format) != (enum pc_di_index_size)~0)) {
retval |= PIPE_BIND_INDEX_BUFFER;
}