[Intel-gfx] [PATCH igt 03/10] lib/igt_fb: fix open-coded ALIGN()
Paulo Zanoni
paulo.r.zanoni at intel.com
Fri Nov 13 09:12:44 PST 2015
Maybe this will help someone's life in the future.
Signed-off-by: Paulo Zanoni <paulo.r.zanoni at intel.com>
---
lib/igt_fb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index 088bc0d..2818c9f 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -104,7 +104,7 @@ static int create_bo_for_fb(int fd, int width, int height, int bpp,
;
} else {
/* Scan-out has a 64 byte alignment restriction */
- stride = (width * (bpp / 8) + 63) & ~63;
+ stride = ALIGN(width * (bpp / 8), 64);
size = stride * height;
}
--
2.6.2
More information about the Intel-gfx
mailing list