Check the correct sysprop for P010 support for gralloc 3 and 4.
We need to check the first api level that the vendor shipped with.
Also check P010 support in the preamble of the relevant test rather than in allocate(), since otherwise either allocate() may incorrectly skip some tests or allocate() may succeed but with the wrong layout information.
Bug: 257442231
Test: VtsHalGraphicsMapperV4_0TargetTest
Change-Id: I00ae5aa01117704158c38f0689e91df99473e208
Merged-In: I00ae5aa01117704158c38f0689e91df99473e208
diff --git a/graphics/mapper/3.0/utils/vts/MapperVts.cpp b/graphics/mapper/3.0/utils/vts/MapperVts.cpp
index c470a4a..48e5736 100644
--- a/graphics/mapper/3.0/utils/vts/MapperVts.cpp
+++ b/graphics/mapper/3.0/utils/vts/MapperVts.cpp
@@ -99,11 +99,7 @@
descriptor, count,
[&](const auto& tmpError, const auto& tmpStride, const auto& tmpBuffers) {
if (tmpError != Error::NONE) {
- if (base::GetIntProperty("ro.vendor.build.version.sdk", 0, 0, INT_MAX) < 33) {
- GTEST_SKIP() << "Old vendor grallocs may not support P010";
- } else {
- GTEST_FAIL() << "failed to allocate buffers";
- }
+ GTEST_FAIL() << "failed to allocate buffers";
}
ASSERT_EQ(count, tmpBuffers.size()) << "invalid buffer array";