aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/winsys
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2017-11-14 19:31:39 +0100
committerMarek Olšák <[email protected]>2017-11-27 14:44:04 +0100
commitec15ff78c3ed4a2b39a45ecf74292090fdc99c6e (patch)
tree402ff736cdafe380b67414ffa659d34e2257ab7b /src/gallium/winsys
parent474b4a919181a155187446ca0e0c0b3522fbdee2 (diff)
ac: change legacy_surf_level::slice_size to dword units
The next commit will reduce the size even more. v2: typecast to uint64_t manually v3: add more typecasts, add asserts Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/gallium/winsys')
-rw-r--r--src/gallium/winsys/radeon/drm/radeon_drm_surface.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/winsys/radeon/drm/radeon_drm_surface.c b/src/gallium/winsys/radeon/drm/radeon_drm_surface.c
index 43bf7ed295c..5ee01ff90f9 100644
--- a/src/gallium/winsys/radeon/drm/radeon_drm_surface.c
+++ b/src/gallium/winsys/radeon/drm/radeon_drm_surface.c
@@ -68,7 +68,7 @@ static void surf_level_winsys_to_drm(struct radeon_surface_level *level_drm,
unsigned bpe)
{
level_drm->offset = level_ws->offset;
- level_drm->slice_size = level_ws->slice_size;
+ level_drm->slice_size = (uint64_t)level_ws->slice_size_dw * 4;
level_drm->nblk_x = level_ws->nblk_x;
level_drm->nblk_y = level_ws->nblk_y;
level_drm->pitch_bytes = level_ws->nblk_x * bpe;
@@ -80,7 +80,7 @@ static void surf_level_drm_to_winsys(struct legacy_surf_level *level_ws,
unsigned bpe)
{
level_ws->offset = level_drm->offset;
- level_ws->slice_size = level_drm->slice_size;
+ level_ws->slice_size_dw = level_drm->slice_size / 4;
level_ws->nblk_x = level_drm->nblk_x;
level_ws->nblk_y = level_drm->nblk_y;
level_ws->mode = level_drm->mode;