summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2017-03-22 11:12:27 -0700
committerKenneth Graunke <[email protected]>2017-04-10 14:31:23 -0700
commitc5cdb0f40574344f1b606fb6978b3714ac82d52a (patch)
tree2da3b1ce3f25f45bf95f7dccd3df25ab02c88608 /src/mesa/drivers/dri
parent1d476e64e5e592d0bb85012e408829d54ad36fa7 (diff)
i965/drm: Use ALIGN, not ROUND_UP_TO.
ROUND_UP_TO handles a NPOT alignment, but all the alignments we use are power of two anyway, so there's no need. Reviewed-by: Chris Wilson <[email protected]> Acked-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r--src/mesa/drivers/dri/i965/intel_bufmgr_gem.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_bufmgr_gem.c b/src/mesa/drivers/dri/i965/intel_bufmgr_gem.c
index 3b9272b32ba..d2bc3ed66cb 100644
--- a/src/mesa/drivers/dri/i965/intel_bufmgr_gem.c
+++ b/src/mesa/drivers/dri/i965/intel_bufmgr_gem.c
@@ -319,7 +319,7 @@ drm_bacon_gem_bo_tile_size(drm_bacon_bufmgr_gem *bufmgr_gem, unsigned long size,
return size;
/* 965+ just need multiples of page size for tiling */
- return ROUND_UP_TO(size, 4096);
+ return ALIGN(size, 4096);
}
/*
@@ -345,7 +345,7 @@ drm_bacon_gem_bo_tile_pitch(drm_bacon_bufmgr_gem *bufmgr_gem,
tile_width = 128;
/* 965 is flexible */
- return ROUND_UP_TO(pitch, tile_width);
+ return ALIGN(pitch, tile_width);
}
static struct drm_bacon_gem_bo_bucket *