diff options
Diffstat (limited to 'libs')
| -rw-r--r-- | libs/binder/include/binder/IInterface.h | 10 | ||||
| -rw-r--r-- | libs/binder/tests/binderLibTest.cpp | 15 | ||||
| -rw-r--r-- | libs/nativewindow/AHardwareBuffer.cpp | 9 | ||||
| -rw-r--r-- | libs/ui/include/ui/PublicFormat.h | 1 |
4 files changed, 13 insertions, 22 deletions
diff --git a/libs/binder/include/binder/IInterface.h b/libs/binder/include/binder/IInterface.h index 30e005c2d2..5924a2d878 100644 --- a/libs/binder/include/binder/IInterface.h +++ b/libs/binder/include/binder/IInterface.h @@ -220,8 +220,6 @@ constexpr const char* const kManualInterfaces[] = { "android.app.IActivityManager", "android.app.IUidObserver", "android.drm.IDrm", - "android.dvr.IVsyncCallback", - "android.dvr.IVsyncService", "android.gfx.tests.ICallback", "android.gfx.tests.IIPCTest", "android.gfx.tests.ISafeInterfaceTest", @@ -264,17 +262,12 @@ constexpr const char* const kManualInterfaces[] = { "android.media.IResourceManagerService", "android.os.IComplexTypeInterface", "android.os.IPermissionController", - "android.os.IPingResponder", "android.os.IProcessInfoService", "android.os.ISchedulingPolicyService", - "android.os.IStringConstants", "android.os.storage.IObbActionListener", "android.os.storage.IStorageEventListener", "android.os.storage.IStorageManager", "android.os.storage.IStorageShutdownObserver", - "android.service.vr.IPersistentVrStateCallbacks", - "android.service.vr.IVrManager", - "android.service.vr.IVrStateCallbacks", "android.ui.ISurfaceComposer", "android.utils.IMemory", "android.utils.IMemoryHeap", @@ -286,9 +279,6 @@ constexpr const char* const kManualInterfaces[] = { "com.android.internal.os.IShellCallback", "drm.IDrmManagerService", "drm.IDrmServiceListener", - "IAAudioClient", - "IAAudioService", - "VtsFuzzer", nullptr, }; diff --git a/libs/binder/tests/binderLibTest.cpp b/libs/binder/tests/binderLibTest.cpp index 9e92f95416..08fa03cfd6 100644 --- a/libs/binder/tests/binderLibTest.cpp +++ b/libs/binder/tests/binderLibTest.cpp @@ -43,6 +43,7 @@ #include <input/BlockingQueue.h> #include <processgroup/processgroup.h> #include <utils/Flattenable.h> +#include <utils/SystemClock.h> #include <linux/sched.h> #include <sys/epoll.h> @@ -1837,14 +1838,6 @@ TEST_F(BinderLibTest, ThreadPoolStarted) { EXPECT_TRUE(reply.readBool()); } -size_t epochMillis() { - using std::chrono::duration_cast; - using std::chrono::milliseconds; - using std::chrono::seconds; - using std::chrono::system_clock; - return duration_cast<milliseconds>(system_clock::now().time_since_epoch()).count(); -} - TEST_F(BinderLibTest, HangingServices) { Parcel data, reply; sp<IBinder> server = addServer(); @@ -1853,7 +1846,7 @@ TEST_F(BinderLibTest, HangingServices) { data.writeInt32(delay); // b/266537959 - must take before taking lock, since countdown is started in the remote // process there. - size_t epochMsBefore = epochMillis(); + int64_t timeBefore = uptimeMillis(); EXPECT_THAT(server->transact(BINDER_LIB_TEST_PROCESS_TEMPORARY_LOCK, data, &reply), NO_ERROR); std::vector<std::thread> ts; for (size_t i = 0; i < kKernelThreads + 1; i++) { @@ -1867,10 +1860,10 @@ TEST_F(BinderLibTest, HangingServices) { for (auto &t : ts) { t.join(); } - size_t epochMsAfter = epochMillis(); + int64_t timeAfter = uptimeMillis(); // deadlock occurred and threads only finished after 1s passed. - EXPECT_GE(epochMsAfter, epochMsBefore + delay); + EXPECT_GE(timeAfter, timeBefore + delay); } TEST_F(BinderLibTest, BinderProxyCount) { diff --git a/libs/nativewindow/AHardwareBuffer.cpp b/libs/nativewindow/AHardwareBuffer.cpp index ca41346d46..3205c32f01 100644 --- a/libs/nativewindow/AHardwareBuffer.cpp +++ b/libs/nativewindow/AHardwareBuffer.cpp @@ -112,6 +112,10 @@ static_assert( static_cast<int>(aidl::android::hardware::graphics::common::PixelFormat::RGBA_10101010) == AHARDWAREBUFFER_FORMAT_R10G10B10A10_UNORM, "HAL and AHardwareBuffer pixel format don't match"); +static_assert( + static_cast<int>(aidl::android::hardware::graphics::common::PixelFormat::YCBCR_P210) == + AHARDWAREBUFFER_FORMAT_YCbCr_P210, + "HAL and AHardwareBuffer pixel format don't match"); static enum AHardwareBufferStatus filterStatus(status_t status) { switch (status) { @@ -300,8 +304,10 @@ int AHardwareBuffer_lockPlanes(AHardwareBuffer* buffer, uint64_t usage, if (result == 0) { outPlanes->planeCount = 3; outPlanes->planes[0].data = yuvData.y; - // P010 is word-aligned 10-bit semiplaner, and YCbCr_422_I is a single interleaved plane + // P010 & P210 are word-aligned 10-bit semiplaner, and YCbCr_422_I is a single interleaved + // plane if (format == AHARDWAREBUFFER_FORMAT_YCbCr_P010 || + format == AHARDWAREBUFFER_FORMAT_YCbCr_P210 || format == AHARDWAREBUFFER_FORMAT_YCbCr_422_I) { outPlanes->planes[0].pixelStride = 2; } else { @@ -724,6 +730,7 @@ bool AHardwareBuffer_formatIsYuv(uint32_t format) { case AHARDWAREBUFFER_FORMAT_YCrCb_420_SP: case AHARDWAREBUFFER_FORMAT_YCbCr_422_I: case AHARDWAREBUFFER_FORMAT_YCbCr_P010: + case AHARDWAREBUFFER_FORMAT_YCbCr_P210: return true; default: return false; diff --git a/libs/ui/include/ui/PublicFormat.h b/libs/ui/include/ui/PublicFormat.h index e87931efed..7c17763860 100644 --- a/libs/ui/include/ui/PublicFormat.h +++ b/libs/ui/include/ui/PublicFormat.h @@ -60,6 +60,7 @@ enum class PublicFormat { JPEG_R = 0x1005, HEIC = 0x48454946, HEIC_ULTRAHDR = 0x1006, + YCBCR_P210 = 0x3c, }; /* Convert from android.graphics.ImageFormat/PixelFormat enums to graphics.h HAL |