Loading cmds/dumpstate/dumpstate.cpp +2 −3 Original line number Diff line number Diff line Loading @@ -2291,12 +2291,11 @@ static void DumpstateBluetoothOnly() { printf("========================================================\n"); printf("------ DUMPSYS (/system/bin/dumpsys) ------\n"); const std::vector<std::string> services = {"android.hardware.bluetooth.IBluetoothHci/default", "bluetooth_manager", "package"}; const std::vector<std::string> services = {"bluetooth_manager", "package"}; for (const std::string& service : services) { printf("-------------------------------------------------------------------------------\n"); printf("DUMP OF SERVICE %s:\n", service.c_str()); RunDumpsys("DUMPSYS", {service}, CommandOptions::WithTimeout(90).Build(), SEC_TO_MSEC(10)); RunDumpsys("", {service}, CommandOptions::WithTimeout(90).Build(), SEC_TO_MSEC(10)); } printf("========================================================\n"); Loading libs/binder/Android.bp +12 −6 Original line number Diff line number Diff line Loading @@ -559,8 +559,7 @@ cc_defaults { name: "libbinder_defer_bc_request_freeze_notification_flag_default", cflags: select(release_flag("RELEASE_LIBBINDER_DEFER_BC_REQUEST_FREEZE_NOTIFICATION"), { true: ["-DLIBBINDER_DEFER_BC_REQUEST_FREEZE_NOTIFICATION"], false: ["-DNO_LIBBINDER_DEFER_BC_REQUEST_FREEZE_NOTIFICATION"], default: ["-DNO_LIBBINDER_DEFER_BC_REQUEST_FREEZE_NOTIFICATION"], default: [], }), } Loading @@ -568,8 +567,7 @@ cc_defaults { name: "libbinder_no_flush_on_last_ref_flag_default", cflags: select(release_flag("RELEASE_LIBBINDER_NO_FLUSH_ON_LAST_REF"), { true: ["-DLIBBINDER_NO_FLUSH_ON_LAST_REF"], false: ["-DNO_LIBBINDER_NO_FLUSH_ON_LAST_REF"], default: ["-DNO_LIBBINDER_NO_FLUSH_ON_LAST_REF"], default: [], }), } Loading @@ -577,8 +575,15 @@ cc_defaults { name: "libbinder_fix_double_derefs_flag_default", cflags: select(release_flag("RELEASE_LIBBINDER_FIX_RECURSIVE_DOUBLE_DEREFS"), { true: ["-DLIBBINDER_FIX_RECURSIVE_DOUBLE_DEREFS"], false: ["-DNO_LIBBINDER_FIX_RECURSIVE_DOUBLE_DEREFS"], default: ["-DNO_LIBBINDER_FIX_RECURSIVE_DOUBLE_DEREFS"], default: [], }), } cc_defaults { name: "libbinder_freeze_use_flush_if_needed_flag_default", cflags: select(release_flag("RELEASE_LIBBINDER_FREEZE_USE_FLUSH_IF_NEEDED"), { true: ["-DLIBBINDER_FREEZE_USE_FLUSH_IF_NEEDED"], default: [], }), } Loading @@ -590,6 +595,7 @@ cc_defaults { "libbinder_addservice_cache_flag", "libbinder_remove_cache_static_list_flag", "libbinder_fix_double_derefs_flag_default", "libbinder_freeze_use_flush_if_needed_flag_default", ], srcs: [ "BufferedTextOutput.cpp", Loading libs/binder/IPCThreadState.cpp +14 −2 Original line number Diff line number Diff line Loading @@ -84,6 +84,14 @@ namespace { return true; #else return false; #endif } bool freezeUseFlushIfNeeded() { #if defined(LIBBINDER_FREEZE_USE_FLUSH_IF_NEEDED) return true; #else return false; #endif } } Loading Loading @@ -1051,7 +1059,9 @@ status_t IPCThreadState::addFrozenStateChangeCallback(int32_t handle, BpBinder* mOut.writeInt32((int32_t)handle); mOut.writePointer((uintptr_t)proxy); if (status_t res = flushCommands(); res != OK) { if (freezeUseFlushIfNeeded()) { flushIfNeeded(); } else if (status_t res = flushCommands(); res != OK) { LOG_ALWAYS_FATAL("%s(%d): %s", __func__, handle, statusToString(res).c_str()); } Loading @@ -1069,7 +1079,9 @@ status_t IPCThreadState::removeFrozenStateChangeCallback(int32_t handle, BpBinde mOut.writeInt32((int32_t)handle); mOut.writePointer((uintptr_t)proxy); if (flush) { if (freezeUseFlushIfNeeded()) { flushIfNeeded(); } else if (flush) { if (status_t res = flushCommands(); res != OK) { LOG_ALWAYS_FATAL("%s(%d): %s", __func__, handle, statusToString(res).c_str()); } Loading libs/gui/Flags.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -98,7 +98,7 @@ sp<MediaSurfaceType> igbpToSurfaceType(const sp<IGraphicBufferProducer>& igbp) { return nullptr; } #if COM_ANDROID_GRAPHICS_LIBGUI_FLAGS(WB_MEDIA_MIGRATION) return new Surface(igbp); return sp<Surface>::make(igbp); #else return igbp; #endif Loading libs/gui/include/gui/BLASTBufferQueue.h +3 −2 Original line number Diff line number Diff line Loading @@ -252,9 +252,10 @@ private: // This is used to check if we should update the blast layer size immediately or wait until // we get the next buffer. This will support scenarios where the layer can change sizes // and the buffer will scale to fit the new size. uint32_t scalingMode = NATIVE_WINDOW_SCALING_MODE_SCALE_TO_WINDOW; uint32_t scalingMode = com::android::graphics::libgui::flags::default_scaling_mode_freeze() ? NATIVE_WINDOW_SCALING_MODE_FREEZE : NATIVE_WINDOW_SCALING_MODE_SCALE_TO_WINDOW; Rect crop; void update(bool hasBuffer, uint32_t width, uint32_t height, uint32_t transform, uint32_t scalingMode, const Rect& crop) { this->hasBuffer = hasBuffer; Loading Loading
cmds/dumpstate/dumpstate.cpp +2 −3 Original line number Diff line number Diff line Loading @@ -2291,12 +2291,11 @@ static void DumpstateBluetoothOnly() { printf("========================================================\n"); printf("------ DUMPSYS (/system/bin/dumpsys) ------\n"); const std::vector<std::string> services = {"android.hardware.bluetooth.IBluetoothHci/default", "bluetooth_manager", "package"}; const std::vector<std::string> services = {"bluetooth_manager", "package"}; for (const std::string& service : services) { printf("-------------------------------------------------------------------------------\n"); printf("DUMP OF SERVICE %s:\n", service.c_str()); RunDumpsys("DUMPSYS", {service}, CommandOptions::WithTimeout(90).Build(), SEC_TO_MSEC(10)); RunDumpsys("", {service}, CommandOptions::WithTimeout(90).Build(), SEC_TO_MSEC(10)); } printf("========================================================\n"); Loading
libs/binder/Android.bp +12 −6 Original line number Diff line number Diff line Loading @@ -559,8 +559,7 @@ cc_defaults { name: "libbinder_defer_bc_request_freeze_notification_flag_default", cflags: select(release_flag("RELEASE_LIBBINDER_DEFER_BC_REQUEST_FREEZE_NOTIFICATION"), { true: ["-DLIBBINDER_DEFER_BC_REQUEST_FREEZE_NOTIFICATION"], false: ["-DNO_LIBBINDER_DEFER_BC_REQUEST_FREEZE_NOTIFICATION"], default: ["-DNO_LIBBINDER_DEFER_BC_REQUEST_FREEZE_NOTIFICATION"], default: [], }), } Loading @@ -568,8 +567,7 @@ cc_defaults { name: "libbinder_no_flush_on_last_ref_flag_default", cflags: select(release_flag("RELEASE_LIBBINDER_NO_FLUSH_ON_LAST_REF"), { true: ["-DLIBBINDER_NO_FLUSH_ON_LAST_REF"], false: ["-DNO_LIBBINDER_NO_FLUSH_ON_LAST_REF"], default: ["-DNO_LIBBINDER_NO_FLUSH_ON_LAST_REF"], default: [], }), } Loading @@ -577,8 +575,15 @@ cc_defaults { name: "libbinder_fix_double_derefs_flag_default", cflags: select(release_flag("RELEASE_LIBBINDER_FIX_RECURSIVE_DOUBLE_DEREFS"), { true: ["-DLIBBINDER_FIX_RECURSIVE_DOUBLE_DEREFS"], false: ["-DNO_LIBBINDER_FIX_RECURSIVE_DOUBLE_DEREFS"], default: ["-DNO_LIBBINDER_FIX_RECURSIVE_DOUBLE_DEREFS"], default: [], }), } cc_defaults { name: "libbinder_freeze_use_flush_if_needed_flag_default", cflags: select(release_flag("RELEASE_LIBBINDER_FREEZE_USE_FLUSH_IF_NEEDED"), { true: ["-DLIBBINDER_FREEZE_USE_FLUSH_IF_NEEDED"], default: [], }), } Loading @@ -590,6 +595,7 @@ cc_defaults { "libbinder_addservice_cache_flag", "libbinder_remove_cache_static_list_flag", "libbinder_fix_double_derefs_flag_default", "libbinder_freeze_use_flush_if_needed_flag_default", ], srcs: [ "BufferedTextOutput.cpp", Loading
libs/binder/IPCThreadState.cpp +14 −2 Original line number Diff line number Diff line Loading @@ -84,6 +84,14 @@ namespace { return true; #else return false; #endif } bool freezeUseFlushIfNeeded() { #if defined(LIBBINDER_FREEZE_USE_FLUSH_IF_NEEDED) return true; #else return false; #endif } } Loading Loading @@ -1051,7 +1059,9 @@ status_t IPCThreadState::addFrozenStateChangeCallback(int32_t handle, BpBinder* mOut.writeInt32((int32_t)handle); mOut.writePointer((uintptr_t)proxy); if (status_t res = flushCommands(); res != OK) { if (freezeUseFlushIfNeeded()) { flushIfNeeded(); } else if (status_t res = flushCommands(); res != OK) { LOG_ALWAYS_FATAL("%s(%d): %s", __func__, handle, statusToString(res).c_str()); } Loading @@ -1069,7 +1079,9 @@ status_t IPCThreadState::removeFrozenStateChangeCallback(int32_t handle, BpBinde mOut.writeInt32((int32_t)handle); mOut.writePointer((uintptr_t)proxy); if (flush) { if (freezeUseFlushIfNeeded()) { flushIfNeeded(); } else if (flush) { if (status_t res = flushCommands(); res != OK) { LOG_ALWAYS_FATAL("%s(%d): %s", __func__, handle, statusToString(res).c_str()); } Loading
libs/gui/Flags.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -98,7 +98,7 @@ sp<MediaSurfaceType> igbpToSurfaceType(const sp<IGraphicBufferProducer>& igbp) { return nullptr; } #if COM_ANDROID_GRAPHICS_LIBGUI_FLAGS(WB_MEDIA_MIGRATION) return new Surface(igbp); return sp<Surface>::make(igbp); #else return igbp; #endif Loading
libs/gui/include/gui/BLASTBufferQueue.h +3 −2 Original line number Diff line number Diff line Loading @@ -252,9 +252,10 @@ private: // This is used to check if we should update the blast layer size immediately or wait until // we get the next buffer. This will support scenarios where the layer can change sizes // and the buffer will scale to fit the new size. uint32_t scalingMode = NATIVE_WINDOW_SCALING_MODE_SCALE_TO_WINDOW; uint32_t scalingMode = com::android::graphics::libgui::flags::default_scaling_mode_freeze() ? NATIVE_WINDOW_SCALING_MODE_FREEZE : NATIVE_WINDOW_SCALING_MODE_SCALE_TO_WINDOW; Rect crop; void update(bool hasBuffer, uint32_t width, uint32_t height, uint32_t transform, uint32_t scalingMode, const Rect& crop) { this->hasBuffer = hasBuffer; Loading