freedreno/a6xx: rename variable
authorRob Clark <robdclark@chromium.org>
Thu, 13 Jun 2019 17:09:18 +0000 (10:09 -0700)
committerRob Clark <robdclark@chromium.org>
Sat, 15 Jun 2019 14:33:04 +0000 (07:33 -0700)
The name 'separate' doesn't make a while lot of sense, as only one of
the cases is the blit actually split.  But split out from previous patch
in an attempt to reduce the noise.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Kristian H. Kristensen <hoegsberg@gmail.com>
src/gallium/drivers/freedreno/a6xx/fd6_blitter.c

index f707ad5..bf2677b 100644 (file)
@@ -565,7 +565,7 @@ static bool fd6_blit(struct fd_context *ctx, const struct pipe_blit_info *info);
 static bool
 handle_zs_blit(struct fd_context *ctx, const struct pipe_blit_info *info)
 {
-       struct pipe_blit_info separate = *info;
+       struct pipe_blit_info blit = *info;
 
        if (DEBUG_BLIT_FALLBACK) {
                fprintf(stderr, "---- handle_zs_blit: ");
@@ -580,67 +580,67 @@ handle_zs_blit(struct fd_context *ctx, const struct pipe_blit_info *info)
        switch (info->dst.format) {
        case PIPE_FORMAT_S8_UINT:
                debug_assert(info->mask == PIPE_MASK_S);
-               separate.mask = PIPE_MASK_R;
-               separate.src.format = PIPE_FORMAT_R8_UINT;
-               separate.dst.format = PIPE_FORMAT_R8_UINT;
-               return fd6_blit(ctx, &separate);
+               blit.mask = PIPE_MASK_R;
+               blit.src.format = PIPE_FORMAT_R8_UINT;
+               blit.dst.format = PIPE_FORMAT_R8_UINT;
+               return fd6_blit(ctx, &blit);
 
        case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                if (info->mask & PIPE_MASK_Z) {
-                       separate.mask = PIPE_MASK_R;
-                       separate.src.format = PIPE_FORMAT_R32_FLOAT;
-                       separate.dst.format = PIPE_FORMAT_R32_FLOAT;
-                       fd6_blit(ctx, &separate);
+                       blit.mask = PIPE_MASK_R;
+                       blit.src.format = PIPE_FORMAT_R32_FLOAT;
+                       blit.dst.format = PIPE_FORMAT_R32_FLOAT;
+                       fd6_blit(ctx, &blit);
                }
 
                if (info->mask & PIPE_MASK_S) {
-                       separate.mask = PIPE_MASK_R;
-                       separate.src.format = PIPE_FORMAT_R8_UINT;
-                       separate.dst.format = PIPE_FORMAT_R8_UINT;
-                       separate.src.resource = &fd_resource(info->src.resource)->stencil->base;
-                       separate.dst.resource = &fd_resource(info->dst.resource)->stencil->base;
-                       fd6_blit(ctx, &separate);
+                       blit.mask = PIPE_MASK_R;
+                       blit.src.format = PIPE_FORMAT_R8_UINT;
+                       blit.dst.format = PIPE_FORMAT_R8_UINT;
+                       blit.src.resource = &fd_resource(info->src.resource)->stencil->base;
+                       blit.dst.resource = &fd_resource(info->dst.resource)->stencil->base;
+                       fd6_blit(ctx, &blit);
                }
 
                return true;
 
        case PIPE_FORMAT_Z16_UNORM:
-               separate.mask = PIPE_MASK_R;
-               separate.src.format = PIPE_FORMAT_R16_UNORM;
-               separate.dst.format = PIPE_FORMAT_R16_UNORM;
-               return fd6_blit(ctx, &separate);
+               blit.mask = PIPE_MASK_R;
+               blit.src.format = PIPE_FORMAT_R16_UNORM;
+               blit.dst.format = PIPE_FORMAT_R16_UNORM;
+               return fd6_blit(ctx, &blit);
 
        case PIPE_FORMAT_Z32_UNORM:
        case PIPE_FORMAT_Z32_FLOAT:
                debug_assert(info->mask == PIPE_MASK_Z);
-               separate.mask = PIPE_MASK_R;
-               separate.src.format = PIPE_FORMAT_R32_UINT;
-               separate.dst.format = PIPE_FORMAT_R32_UINT;
-               return fd6_blit(ctx, &separate);
+               blit.mask = PIPE_MASK_R;
+               blit.src.format = PIPE_FORMAT_R32_UINT;
+               blit.dst.format = PIPE_FORMAT_R32_UINT;
+               return fd6_blit(ctx, &blit);
 
        case PIPE_FORMAT_Z24X8_UNORM:
-               separate.mask = PIPE_MASK_R;
-               separate.src.format = PIPE_FORMAT_R32_UINT;
-               separate.dst.format = PIPE_FORMAT_R32_UINT;
-               return fd6_blit(ctx, &separate);
+               blit.mask = PIPE_MASK_R;
+               blit.src.format = PIPE_FORMAT_R32_UINT;
+               blit.dst.format = PIPE_FORMAT_R32_UINT;
+               return fd6_blit(ctx, &blit);
 
        case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                switch (info->mask) {
                case PIPE_MASK_ZS:
-                       separate.mask = PIPE_MASK_R;
-                       separate.src.format = PIPE_FORMAT_R32_UINT;
-                       separate.dst.format = PIPE_FORMAT_R32_UINT;
-                       return fd6_blit(ctx, &separate);
+                       blit.mask = PIPE_MASK_R;
+                       blit.src.format = PIPE_FORMAT_R32_UINT;
+                       blit.dst.format = PIPE_FORMAT_R32_UINT;
+                       return fd6_blit(ctx, &blit);
                case PIPE_MASK_Z:
-                       separate.mask = PIPE_MASK_R | PIPE_MASK_G | PIPE_MASK_B;
-                       separate.src.format = PIPE_FORMAT_R8G8B8A8_UNORM;
-                       separate.dst.format = PIPE_FORMAT_R8G8B8A8_UNORM;
-                       return fd_blitter_blit(ctx, &separate);
+                       blit.mask = PIPE_MASK_R | PIPE_MASK_G | PIPE_MASK_B;
+                       blit.src.format = PIPE_FORMAT_R8G8B8A8_UNORM;
+                       blit.dst.format = PIPE_FORMAT_R8G8B8A8_UNORM;
+                       return fd_blitter_blit(ctx, &blit);
                case PIPE_MASK_S:
-                       separate.mask = PIPE_MASK_A;
-                       separate.src.format = PIPE_FORMAT_R8G8B8A8_UNORM;
-                       separate.dst.format = PIPE_FORMAT_R8G8B8A8_UNORM;
-                       return fd_blitter_blit(ctx, &separate);
+                       blit.mask = PIPE_MASK_A;
+                       blit.src.format = PIPE_FORMAT_R8G8B8A8_UNORM;
+                       blit.dst.format = PIPE_FORMAT_R8G8B8A8_UNORM;
+                       return fd_blitter_blit(ctx, &blit);
                default:
                        unreachable("");
                }