hardware: exynos5: hwc: add gsc's width alignment constraint.

1.M2M case
GSC's dst width should be aligned with 32 pixels in case of RGB888.

Bug: 7276111
Change-Id: I563f7367b7f368d24194d178c8b0ca3b445b6ec3
Signed-off-by: Sanghee Kim <haya93@samsung.com>
diff --git a/libhwc/hwc.cpp b/libhwc/hwc.cpp
index cd0844f..a63d54b 100644
--- a/libhwc/hwc.cpp
+++ b/libhwc/hwc.cpp
@@ -55,6 +55,8 @@
 const size_t MAX_PIXELS = 2560 * 1600 * 2;
 const size_t GSC_W_ALIGNMENT = 16;
 const size_t GSC_H_ALIGNMENT = 16;
+const size_t GSC_DST_W_ALIGNMENT_RGB888 = 32;
+const size_t GSC_DST_H_ALIGNMENT_RGB888 = 1;
 const size_t FIMD_GSC_IDX = 0;
 const size_t HDMI_GSC_IDX = 1;
 const int AVAILABLE_GSC_UNITS[] = { 0, 3 };
@@ -1079,8 +1081,8 @@
         if (src_handle->flags & GRALLOC_USAGE_PROTECTED)
             usage |= GRALLOC_USAGE_PROTECTED;
 
-        int w = ALIGN(WIDTH(layer.displayFrame), GSC_W_ALIGNMENT);
-        int h = ALIGN(HEIGHT(layer.displayFrame), GSC_H_ALIGNMENT);
+        int w = ALIGN(WIDTH(layer.displayFrame), GSC_DST_W_ALIGNMENT_RGB888);
+        int h = ALIGN(HEIGHT(layer.displayFrame), GSC_DST_H_ALIGNMENT_RGB888);
 
         for (size_t i = 0; i < NUM_GSC_DST_BUFS; i++) {
             if (gsc_data->dst_buf[i]) {