Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 52c5bf8d authored by Jim Blackler's avatar Jim Blackler Committed by Android (Google) Code Review
Browse files

Merge "Game Loading Time improvement by boosting CPU via ADPF"

parents dcc14283 559361b6
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -201,10 +201,8 @@ private:
    std::array<std::atomic<HalSupport>,
               static_cast<int32_t>(hardware::power::Boost::DISPLAY_UPDATE_IMMINENT) + 1>
            mBoostSupportedArray GUARDED_BY(mBoostMutex) = {HalSupport::UNKNOWN};
    // Android framework only sends mode upto DISPLAY_INACTIVE.
    // Need to increase the array if more mode supported.
    std::array<std::atomic<HalSupport>,
               static_cast<int32_t>(hardware::power::Mode::DISPLAY_INACTIVE) + 1>
               static_cast<int32_t>(*(android::enum_range<hardware::power::Mode>().end() - 1)) + 1>
            mModeSupportedArray GUARDED_BY(mModeMutex) = {HalSupport::UNKNOWN};
};

+7 −7
Original line number Diff line number Diff line
@@ -28,7 +28,7 @@ cc_library_shared {
        include_dirs: [
            "frameworks/base/core/java/android/os",
        ],
       export_aidl_headers: true
        export_aidl_headers: true,
    },

    shared_libs: [
@@ -38,7 +38,7 @@ cc_library_shared {
        "libutils",
        "android.hardware.power@1.0",
        "android.hardware.power@1.1",
        "android.hardware.power-V2-cpp",
        "android.hardware.power-V3-cpp",
    ],

    cflags: [
+1 −1
Original line number Diff line number Diff line
@@ -38,7 +38,7 @@ cc_benchmark {
        "libutils",
        "android.hardware.power@1.0",
        "android.hardware.power@1.1",
        "android.hardware.power-V2-cpp",
        "android.hardware.power-V3-cpp",
    ],
    static_libs: [
        "libtestUtil",
+1 −1
Original line number Diff line number Diff line
@@ -46,7 +46,7 @@ cc_test {
        "libutils",
        "android.hardware.power@1.0",
        "android.hardware.power@1.1",
        "android.hardware.power-V2-cpp",
        "android.hardware.power-V3-cpp",
    ],
    static_libs: [
        "libgmock",
+4 −0
Original line number Diff line number Diff line
@@ -183,6 +183,10 @@ TEST_F(PowerHalWrapperAidlTest, TestSetModeUnsupported) {

    auto result = mWrapper->setMode(Mode::LAUNCH, true);
    ASSERT_TRUE(result.isUnsupported());

    EXPECT_CALL(*mMockHal.get(), isModeSupported(Eq(Mode::CAMERA_STREAMING_HIGH), _))
            .Times(Exactly(1))
            .WillRepeatedly(DoAll(SetArgPointee<1>(false), Return(Status())));
    result = mWrapper->setMode(Mode::CAMERA_STREAMING_HIGH, true);
    ASSERT_TRUE(result.isUnsupported());
}