Revert "sdm: add one action to set panel brightness and refresh screen"
This reverts commit c31d7f8d94.
Conflicts:
sdm/include/private/color_params.h
sdm/libs/core/fb/hw_device.cpp
sdm/libs/hwc/hwc_display.cpp
sdm/libs/hwc/hwc_display.h
sdm/libs/hwc/hwc_session.cpp
Change-Id: I76729ee9ae83a611fca632e18315d478bcf13fa4
This commit is contained in:
committed by
Gerrit - the friendly Code Review server
parent
8ae77fc36e
commit
c4db309c3e
@@ -491,14 +491,6 @@ class DisplayInterface {
|
||||
*/
|
||||
virtual DisplayError SetPanelBrightness(int level) = 0;
|
||||
|
||||
/*! @brief Method to cache brightness of the primary display.
|
||||
|
||||
@param[in] level the new backlight level.
|
||||
|
||||
@return \link DisplayError \endlink
|
||||
*/
|
||||
virtual DisplayError CachePanelBrightness(int level) = 0;
|
||||
|
||||
/*! @brief Method to notify display about change in min HDCP encryption level.
|
||||
|
||||
@param[in] min_enc_level minimum encryption level value.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2015-2017, The Linux Foundataion. All rights reserved.
|
||||
/* Copyright (c) 2015-2018, The Linux Foundataion. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are
|
||||
@@ -54,7 +54,6 @@ enum PendingAction {
|
||||
kEnableFrameCapture = BITMAP(6),
|
||||
kDisableFrameCapture = BITMAP(7),
|
||||
kConfigureDetailedEnhancer = BITMAP(8),
|
||||
kInvalidatingAndkSetPanelBrightness = BITMAP(9),
|
||||
kModeSet = BITMAP(10),
|
||||
kGetDetailedEnhancerData = BITMAP(21),
|
||||
kNoAction = BITMAP(31),
|
||||
|
||||
@@ -83,9 +83,6 @@ class DisplayBase : public DisplayInterface {
|
||||
virtual DisplayError SetPanelBrightness(int level) {
|
||||
return kErrorNotSupported;
|
||||
}
|
||||
virtual DisplayError CachePanelBrightness(int level) {
|
||||
return kErrorNotSupported;
|
||||
}
|
||||
virtual DisplayError OnMinHdcpEncryptionLevelChange(uint32_t min_enc_level) {
|
||||
return kErrorNotSupported;
|
||||
}
|
||||
|
||||
@@ -240,11 +240,6 @@ DisplayError DisplayPrimary::SetPanelBrightness(int level) {
|
||||
return hw_intf_->SetPanelBrightness(level);
|
||||
}
|
||||
|
||||
DisplayError DisplayPrimary::CachePanelBrightness(int level) {
|
||||
lock_guard<recursive_mutex> obj(recursive_mutex_);
|
||||
return hw_intf_->CachePanelBrightness(level);
|
||||
}
|
||||
|
||||
DisplayError DisplayPrimary::GetRefreshRateRange(uint32_t *min_refresh_rate,
|
||||
uint32_t *max_refresh_rate) {
|
||||
lock_guard<recursive_mutex> obj(recursive_mutex_);
|
||||
|
||||
@@ -51,7 +51,6 @@ class DisplayPrimary : public DisplayBase, HWEventHandler {
|
||||
virtual DisplayError SetRefreshRate(uint32_t refresh_rate, bool final_rate);
|
||||
virtual DisplayError SetPanelBrightness(int level);
|
||||
virtual DisplayError GetPanelBrightness(int *level);
|
||||
virtual DisplayError CachePanelBrightness(int level);
|
||||
|
||||
// Implement the HWEventHandlers
|
||||
virtual DisplayError VSync(int64_t timestamp);
|
||||
|
||||
@@ -1390,10 +1390,6 @@ DisplayError HWDeviceDRM::GetPanelBrightness(int *level) {
|
||||
return err;
|
||||
}
|
||||
|
||||
DisplayError HWDeviceDRM::CachePanelBrightness(int level) {
|
||||
return kErrorNotSupported;
|
||||
}
|
||||
|
||||
DisplayError HWDeviceDRM::GetHWScanInfo(HWScanInfo *scan_info) {
|
||||
return kErrorNotSupported;
|
||||
}
|
||||
|
||||
@@ -83,7 +83,6 @@ class HWDeviceDRM : public HWInterface {
|
||||
virtual DisplayError SetDisplayMode(const HWDisplayMode hw_display_mode);
|
||||
virtual DisplayError SetRefreshRate(uint32_t refresh_rate);
|
||||
virtual DisplayError SetPanelBrightness(int level);
|
||||
virtual DisplayError CachePanelBrightness(int level);
|
||||
virtual DisplayError GetHWScanInfo(HWScanInfo *scan_info);
|
||||
virtual DisplayError GetVideoFormat(uint32_t config_index, uint32_t *video_format);
|
||||
virtual DisplayError GetMaxCEAFormat(uint32_t *max_cea_format);
|
||||
|
||||
@@ -496,12 +496,6 @@ DisplayError HWDevice::Commit(HWLayers *hw_layers) {
|
||||
if (synchronous_commit_) {
|
||||
mdp_commit.flags |= MDP_COMMIT_WAIT_FOR_FINISH;
|
||||
}
|
||||
if (bl_update_commit && bl_level_update_commit >= 0) {
|
||||
#ifdef MDP_COMMIT_UPDATE_BRIGHTNESS
|
||||
mdp_commit.bl_level = (uint32_t)bl_level_update_commit;
|
||||
mdp_commit.flags |= MDP_COMMIT_UPDATE_BRIGHTNESS;
|
||||
#endif
|
||||
}
|
||||
if (Sys::ioctl_(device_fd_, INT(MSMFB_ATOMIC_COMMIT), &mdp_disp_commit_) < 0) {
|
||||
if (errno == ESHUTDOWN) {
|
||||
DLOGI_IF(kTagDriverConfig, "Driver is processing shutdown sequence");
|
||||
@@ -556,9 +550,6 @@ DisplayError HWDevice::Commit(HWLayers *hw_layers) {
|
||||
synchronous_commit_ = false;
|
||||
}
|
||||
|
||||
if (bl_update_commit)
|
||||
bl_update_commit = false;
|
||||
|
||||
return kErrorNone;
|
||||
}
|
||||
|
||||
@@ -1202,10 +1193,6 @@ DisplayError HWDevice::SetPanelBrightness(int level) {
|
||||
return kErrorNotSupported;
|
||||
}
|
||||
|
||||
DisplayError HWDevice::CachePanelBrightness(int level) {
|
||||
return kErrorNotSupported;
|
||||
}
|
||||
|
||||
DisplayError HWDevice::GetHWScanInfo(HWScanInfo *scan_info) {
|
||||
return kErrorNotSupported;
|
||||
}
|
||||
|
||||
@@ -85,7 +85,6 @@ class HWDevice : public HWInterface {
|
||||
virtual DisplayError SetDisplayMode(const HWDisplayMode hw_display_mode);
|
||||
virtual DisplayError SetRefreshRate(uint32_t refresh_rate);
|
||||
virtual DisplayError SetPanelBrightness(int level);
|
||||
virtual DisplayError CachePanelBrightness(int level);
|
||||
virtual DisplayError GetHWScanInfo(HWScanInfo *scan_info);
|
||||
virtual DisplayError GetVideoFormat(uint32_t config_index, uint32_t *video_format);
|
||||
virtual DisplayError GetMaxCEAFormat(uint32_t *max_cea_format);
|
||||
@@ -158,8 +157,6 @@ class HWDevice : public HWInterface {
|
||||
HWDisplayAttributes display_attributes_ = {};
|
||||
HWMixerAttributes mixer_attributes_ = {};
|
||||
std::vector<mdp_destination_scaler_data> mdp_dest_scalar_data_;
|
||||
int bl_level_update_commit = -1;
|
||||
bool bl_update_commit = false;
|
||||
};
|
||||
|
||||
} // namespace sdm
|
||||
|
||||
@@ -570,12 +570,6 @@ DisplayError HWPrimary::GetPanelBrightness(int *level) {
|
||||
return kErrorNone;
|
||||
}
|
||||
|
||||
DisplayError HWPrimary::CachePanelBrightness(int level) {
|
||||
bl_level_update_commit = level;
|
||||
bl_update_commit = true;
|
||||
return kErrorNone;
|
||||
}
|
||||
|
||||
DisplayError HWPrimary::SetAutoRefresh(bool enable) {
|
||||
const int kWriteLength = 2;
|
||||
char buffer[kWriteLength] = {'\0'};
|
||||
|
||||
@@ -55,7 +55,6 @@ class HWPrimary : public HWDevice {
|
||||
virtual DisplayError SetDisplayMode(const HWDisplayMode hw_display_mode);
|
||||
virtual DisplayError SetRefreshRate(uint32_t refresh_rate);
|
||||
virtual DisplayError SetPanelBrightness(int level);
|
||||
virtual DisplayError CachePanelBrightness(int level);
|
||||
virtual DisplayError GetPPFeaturesVersion(PPFeatureVersion *vers);
|
||||
virtual DisplayError SetPPFeatures(PPFeaturesConfig *feature_list);
|
||||
virtual DisplayError GetPanelBrightness(int *level);
|
||||
|
||||
@@ -100,7 +100,6 @@ class HWInterface {
|
||||
virtual DisplayError SetDisplayMode(const HWDisplayMode hw_display_mode) = 0;
|
||||
virtual DisplayError SetRefreshRate(uint32_t refresh_rate) = 0;
|
||||
virtual DisplayError SetPanelBrightness(int level) = 0;
|
||||
virtual DisplayError CachePanelBrightness(int level) = 0;
|
||||
virtual DisplayError GetHWScanInfo(HWScanInfo *scan_info) = 0;
|
||||
virtual DisplayError GetVideoFormat(uint32_t config_index, uint32_t *video_format) = 0;
|
||||
virtual DisplayError GetMaxCEAFormat(uint32_t *max_cea_format) = 0;
|
||||
|
||||
Reference in New Issue
Block a user