mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 13:49:24 -04:00
disp: msm: add display frequency change notification
Added notifier to inform registered consumers about display changing frequency. Change-Id: Ibc2de44c680e5499282c9b0c96d3a03e4f019f8a Signed-off-by: Konstantin Makariev <hcv867@motorola.com> Reviewed-on: https://gerrit.mot.com/1697620 SLTApproved: Slta Waiver SME-Granted: SME Approvals Granted Tested-by: Jira Key Reviewed-by: Guobin Zhang <zhanggb@motorola.com> Submit-Approved: Jira Key
This commit is contained in:
parent
6ff2674c42
commit
1d87f2a40c
1 changed files with 7 additions and 0 deletions
|
|
@ -20,6 +20,9 @@
|
|||
#include "sde_vdc_helper.h"
|
||||
#include "dsi_display.h"
|
||||
|
||||
static struct blocking_notifier_head dsi_freq_head =
|
||||
BLOCKING_NOTIFIER_INIT(dsi_freq_head);
|
||||
EXPORT_SYMBOL_GPL(dsi_freq_head);
|
||||
|
||||
/**
|
||||
* topology is currently defined by a set of following 3 values:
|
||||
|
|
@ -5251,6 +5254,10 @@ int dsi_panel_switch(struct dsi_panel *panel)
|
|||
panel->name, rc);
|
||||
|
||||
mutex_unlock(&panel->panel_lock);
|
||||
/* notify consumers only if refresh rate has been updated */
|
||||
if (!rc)
|
||||
blocking_notifier_call_chain(&dsi_freq_head,
|
||||
(unsigned long)panel->cur_mode->timing.refresh_rate, NULL);
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue