summaryrefslogtreecommitdiff
path: root/radeon
diff options
context:
space:
mode:
authorMarek Olšák <maraeo@gmail.com>2012-07-29 14:10:07 +0200
committerMarek Olšák <maraeo@gmail.com>2012-08-09 16:37:20 +0200
commitad66c17209811acdae21e44290a449523882a734 (patch)
tree8013e5f82c7afe185e9aef4a898d85580c33b862 /radeon
parent93fef04b1e3a83e2f884880ed1c3395f67b038ab (diff)
radeon: simplify ZS buffer checking on r600
Setting those flags has no effect anywhere else. Reviewed-by: Christian König <christian.koenig@amd.com>
Diffstat (limited to 'radeon')
-rw-r--r--radeon/radeon_surface.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/radeon/radeon_surface.c b/radeon/radeon_surface.c
index c80f7f49..5800c334 100644
--- a/radeon/radeon_surface.c
+++ b/radeon/radeon_surface.c
@@ -385,14 +385,7 @@ static int r6_surface_init(struct radeon_surface_manager *surf_man,
/* tiling mode */
mode = (surf->flags >> RADEON_SURF_MODE_SHIFT) & RADEON_SURF_MODE_MASK;
- /* always enable z & stencil together */
- if (surf->flags & RADEON_SURF_ZBUFFER) {
- surf->flags |= RADEON_SURF_SBUFFER;
- }
- if (surf->flags & RADEON_SURF_SBUFFER) {
- surf->flags |= RADEON_SURF_ZBUFFER;
- }
- if (surf->flags & RADEON_SURF_ZBUFFER) {
+ if (surf->flags & (RADEON_SURF_ZBUFFER | RADEON_SURF_SBUFFER)) {
/* zbuffer only support 1D or 2D tiled surface */
switch (mode) {
case RADEON_SURF_MODE_1D: