From cf53dddaa8086253da888ff1b58116ac1f06a968 Mon Sep 17 00:00:00 2001 From: Hyeonmyeong Choi Date: Sat, 2 Feb 2013 18:41:33 +0900 Subject: [PATCH] include: Modify exynos_format.h for define ALIGN UP/DOWN Change-Id: I0c7e85dc6f2f3b3f859d54bd109b57d46f90e684 Signed-off-by: Hyeonmyeong Choi --- include/exynos_format.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) mode change 100644 => 100755 include/exynos_format.h diff --git a/include/exynos_format.h b/include/exynos_format.h old mode 100644 new mode 100755 index f4c0466..fff96ce --- a/include/exynos_format.h +++ b/include/exynos_format.h @@ -58,7 +58,9 @@ struct ADDRS { /* 12 Y/CbCr 4:2:0 64x32 macroblocks */ #define V4L2_PIX_FMT_NV12T v4l2_fourcc('T', 'V', '1', '2') -#define ALIGN(x, a) (((x) + (a) - 1) & ~((a) - 1)) +#define ALIGN_UP(x, a) (((x) + (a) - 1) & ~((a) - 1)) +#define ALIGN_DOWN(x, a) ((x) - (x % a)) +#define ALIGN(x, a) ALIGN_UP(x, a) #define ALIGN_TO_32B(x) ((((x) + (1 << 5) - 1) >> 5) << 5) #define ALIGN_TO_128B(x) ((((x) + (1 << 7) - 1) >> 7) << 7) #define ALIGN_TO_8KB(x) ((((x) + (1 << 13) - 1) >> 13) << 13) -- 2.20.1