plane_test: Add support for specifying plane type

Currently, the tast.graphics.PlatformOverlays.* tests fail on most
devices. This is because plane_test tries to assign every plane as
type OVERLAY [1]. The code here compares each plane's type property
with desired_value which is always set to the enum value of OVERLAY.
In PlatformOverlays.24bpp_nv12_overlay, for example, the test runs
plane_test with a fullscreen XR24 buffer and a smaller NV12 one and
tries to assign both to OVERLAY planes. However, most devices only
support a single overlay plane (in addition to primary and cursor
planes). Thus, plane_test is unable to assign both planes and fails
the test.

This CL fixes this behavior by adding support for specifying plane
type in plane_test. If the type is unspecified, however, we default
to setting the first sequential plane to PRIMARY, and the rest to
OVERLAY. Thus, the tests are fixed because we now try to assign a
fullscreen XR24 PRIMARY plane and a smaller NV12 OVERLAY plane
instead of 2 OVERLAYS- just like in Chrome.

[1] https://source.chromium.org/chromium/chromiumos/platform/drm-tests/+/HEAD:plane_test.c;l=115;drc=593c97dac6faa9fa028848501b23c27263e316d4

Bug: b:217970618
Change-Id: I0d8a0046d1dd064ad26a0d580562bc2254fc05f7
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/drm-tests/+/3489410
Reviewed-by: Andrew Wolfers <aswolfers@chromium.org>
Reviewed-by: Miguel Casas <mcasas@google.com>
Tested-by: Brian Ho <hob@chromium.org>
Reviewed-by: Miguel Casas-Sanchez <mcasas@chromium.org>
Commit-Queue: Brian Ho <hob@chromium.org>
1 file changed