diff options
author | Jerome Glisse <jglisse@redhat.com> | 2012-06-11 15:01:12 -0400 |
---|---|---|
committer | Jerome Glisse <jglisse@redhat.com> | 2012-06-11 15:01:12 -0400 |
commit | 325e2e52a96ede6a19e891f769c803cb9ba85e10 (patch) | |
tree | 60497da005020a6ea5caf01d5bf0dc4b654d77ce /radeon | |
parent | 9e0026d35c56374b53a0b3837e24412bc9a4d8c9 (diff) |
radeon: always properly initialize stencil_offset field
Reported-by: Vadim Girlin <vadimgirlin@gmail.com>
Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Diffstat (limited to 'radeon')
-rw-r--r-- | radeon/radeon_surface.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/radeon/radeon_surface.c b/radeon/radeon_surface.c index adf209d0..704d8e79 100644 --- a/radeon/radeon_surface.c +++ b/radeon/radeon_surface.c @@ -565,8 +565,6 @@ static int eg_surface_init_1d(struct radeon_surface_manager *surf_man, tilew = 8; xalign = surf_man->hw_info.group_bytes / (tilew * surf->bpe * surf->nsamples); if (surf->flags & RADEON_SURF_SBUFFER) { - surf->stencil_offset = 0; - surf->stencil_tile_split = 0; xalign = surf_man->hw_info.group_bytes / (tilew * surf->nsamples); } xalign = MAX2(tilew, xalign); @@ -607,7 +605,6 @@ static int eg_surface_init_2d(struct radeon_surface_manager *surf_man, unsigned slice_pt; unsigned i; - surf->stencil_offset = 0; /* compute tile values */ tilew = 8; tileh = 8; @@ -749,6 +746,9 @@ static int eg_surface_init(struct radeon_surface_manager *surf_man, return r; } + surf->stencil_offset = 0; + surf->stencil_tile_split = 0; + /* check tiling mode */ switch (mode) { case RADEON_SURF_MODE_LINEAR: |