minigbm: amdgpu: enable handling of NV12 & NV21 format
This patch does the below:
1. Adds DRM_FORMAT_NV12 & DRM_FORMAT_NV21
to the list of formats supported by amdgpu driver
2. bo_create() updates parameter's of video planes
appropriately.
3. add DRM_FORMAT_NV21 in drv.c & helpers.c
This patch is a step towards enabling overlay based video rendering
capability available in hardware.
BUG=b:
37526302
TEST=emerge-kahlee media-libs/minigbm
TEST=Boots to UI on jadeite & kahlee
TEST=With all the changes in kernel(not upstreamed) execute below:
plane_test --format AR24 --size 500x50 -p --format NV12 --size 500x500
plane_test --format AR24 --size 500x50 -p --format NV12 --size 1280x720
plane_test --format AR24 --size 500x50 -p --format NV12 --size 1366x768
plane_test --format AR24 --size 500x50 -p --format NV21 --size 1366x768
TEST=displays same colored layers on video and RGB plane.
Change-Id: If75a4586b636b600a5b4b2d909f10bcf03613cc2
Signed-off-by: Shirish S <shirish.s@amd.com>
Reviewed-on: https://chromium-review.googlesource.com/479043
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>