etnaviv: pass correct layout to etna_resource_alloc for scanout resources

Since b96277653033 (etnaviv: rework compatible render base) the base resource
may be linear and a render compatible resource is allocated as needed. As
scanout surfaces without a modifier are always assumed to be linear, make
sure to pass the correct layout to etna_resource_alloc().

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7367>
diff --git a/src/gallium/drivers/etnaviv/etnaviv_resource.c b/src/gallium/drivers/etnaviv/etnaviv_resource.c
index 07224ca..78c4e49 100644
--- a/src/gallium/drivers/etnaviv/etnaviv_resource.c
+++ b/src/gallium/drivers/etnaviv/etnaviv_resource.c
@@ -352,7 +352,7 @@
     * and a texture-compatible base buffer in other cases
     *
     */
-   if (templat->bind & (PIPE_BIND_SCANOUT | PIPE_BIND_DEPTH_STENCIL)) {
+   if (templat->bind & PIPE_BIND_DEPTH_STENCIL) {
       if (screen->specs.pixel_pipes > 1 && !screen->specs.single_buffer)
          layout |= ETNA_LAYOUT_BIT_MULTI;
       if (screen->specs.can_supertile)
@@ -362,7 +362,8 @@
       layout |= ETNA_LAYOUT_BIT_SUPER;
    }
 
-   if ((templat->bind & PIPE_BIND_LINEAR) || /* linear base requested */
+   if (/* linear base or scanout without modifier requested */
+       (templat->bind & (PIPE_BIND_LINEAR | PIPE_BIND_SCANOUT)) ||
        templat->target == PIPE_BUFFER || /* buffer always linear */
        /* compressed textures don't use tiling, they have their own "tiles" */
        util_format_is_compressed(templat->format)) {