rockchip: Don't align height in NV12 format

crrev.com/c/1729176 corrected a wrong NV12 buffer allocation on rockchip. After
the CL, the width and height both are aligned by 16. Since GBM API doesn't
notify the aligned height to an application. The application must handle the
planes with offsets.

It turns out that Camera HAL on ChromeOS doesn't handle the allocated buffer
with offsets. In other words, it doesn't think of extra data between planes.
This causes, in a camera preview, a green line at bottom and a strange blue line
due to misposition of color planes.

This CL is a temproal workaround for the Camera HAL issue. This CL changes
minigbm implementation to not align height. This works because present video
encoder and decoder always calls GBM API with the height already aligned by
video driver. Note that a camera stack on encoding process will have to allocate
a proper buffer with non-aligned height in the future. This must be a temporal
workaround.

BUG=b:140152839
TEST=Confirm no green line in camera view and recorded video with Camera app
Change-Id: Ide53fa6801fc4bdabcfbe46004d01f5ab83a002f
Reviewed-on: https://chromium-review.googlesource.com/1775953
Tested-by: Hirokazu Honda <hiroh@chromium.org>
Commit-Ready: Hirokazu Honda <hiroh@chromium.org>
Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org>
Reviewed-by: Tomasz Figa <tfiga@chromium.org>
1 file changed