Loading services/surfaceflinger/DisplayHardware/HWC2.cpp +6 −0 Original line number Diff line number Diff line Loading @@ -717,6 +717,12 @@ Error Display::presentOrValidate(uint32_t* outNumTypes, uint32_t* outNumRequests } return error; } void Display::discardCommands() { mDevice.mComposer->resetCommands(); } // For use by Device int32_t Display::getAttribute(hwc2_config_t configId, Attribute attribute) Loading services/surfaceflinger/DisplayHardware/HWC2.h +6 −0 Original line number Diff line number Diff line Loading @@ -259,6 +259,12 @@ public: uint32_t* outNumRequests, android::sp<android::Fence>* outPresentFence, uint32_t* state); // Most methods in this class write a command to a command buffer. The // command buffer is implicitly submitted in validate, present, and // presentOrValidate. This method provides a way to discard the commands, // which can be used to discard stale commands. void discardCommands(); // Other Display methods Device& getDevice() const { return mDevice; } Loading services/surfaceflinger/DisplayHardware/HWComposer.cpp +1 −0 Original line number Diff line number Diff line Loading @@ -621,6 +621,7 @@ status_t HWComposer::presentAndGetReleaseFences(int32_t displayId) { auto& hwcDisplay = displayData.hwcDisplay; if (displayData.validateWasSkipped) { hwcDisplay->discardCommands(); auto error = displayData.presentError; if (error != HWC2::Error::None) { ALOGE("skipValidate: failed for display %d: %s (%d)", Loading Loading
services/surfaceflinger/DisplayHardware/HWC2.cpp +6 −0 Original line number Diff line number Diff line Loading @@ -717,6 +717,12 @@ Error Display::presentOrValidate(uint32_t* outNumTypes, uint32_t* outNumRequests } return error; } void Display::discardCommands() { mDevice.mComposer->resetCommands(); } // For use by Device int32_t Display::getAttribute(hwc2_config_t configId, Attribute attribute) Loading
services/surfaceflinger/DisplayHardware/HWC2.h +6 −0 Original line number Diff line number Diff line Loading @@ -259,6 +259,12 @@ public: uint32_t* outNumRequests, android::sp<android::Fence>* outPresentFence, uint32_t* state); // Most methods in this class write a command to a command buffer. The // command buffer is implicitly submitted in validate, present, and // presentOrValidate. This method provides a way to discard the commands, // which can be used to discard stale commands. void discardCommands(); // Other Display methods Device& getDevice() const { return mDevice; } Loading
services/surfaceflinger/DisplayHardware/HWComposer.cpp +1 −0 Original line number Diff line number Diff line Loading @@ -621,6 +621,7 @@ status_t HWComposer::presentAndGetReleaseFences(int32_t displayId) { auto& hwcDisplay = displayData.hwcDisplay; if (displayData.validateWasSkipped) { hwcDisplay->discardCommands(); auto error = displayData.presentError; if (error != HWC2::Error::None) { ALOGE("skipValidate: failed for display %d: %s (%d)", Loading