Correct the DSC 1.1 Rate control for Max QP values for each ratio type
in dsi_dsc_ratio_type
Change-Id: I75092e1a40213be80c74292e8c20cd332d582910
Signed-off-by: daiss1 <daiss1@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1720143
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Add a new property to specify the default brightness level that would
set for usecases where no explicit brightness level is configured.
Mot-CRs-fixed: (CR)
Change-Id: Iecc6f4e0b5b9fbda5d8bf97efa7d4de4dbbd5570
Signed-off-by: houdz1 <houdz1@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1697641
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
For LCD panel, set brightness at maximum while entering HBM and keep it
same afterwards whatever user space brightness. Previous user space
brightness is restored while exiting HBM. This change ensures LCD and
OLED HBM behavior consistent.
Change-Id: I9c3c319b6288239914092af9c0b9bfd59412fa07
Signed-off-by: houdz1 <houdz1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697640
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Touch have a feature named "single tap".
1. When the feature enbled, we can not power down panel,
and keep rest signal high.
2. When the feature disabled, the retrun value is s 0,
Instead, the retrun value is 1.
Change-Id: Ib4530ebcd3132d60588dbe92ab23d0737983b6b4
Signed-off-by: houdz1 <houdz1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1499390
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Reviewed-by: Shanshan Dai <daiss1@motorola.com>
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1697638
1.Different projects have different features.
For example: there are not "ACL" feature for lcd panel.
So some feature cmd parse is failed.
We only release the struct dsi_panel_cmd_set when parse failed.
2.Must get "panel_hbm_fod" first, then parse param property.
Change-Id: I82d5a96b715683168ae0a609664624128cdb170e
Signed-off-by: houdz1 <houdz1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697637
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
- Mot's panel param feature is working with sending single MIPI DSI
command, but it doesn't work correct with sending more than one MIPI
DSI commands
- Enable ACL support to enable or disable ACL feature with the MotUtil
tool. This tool is designed to validate the MOT display DRM Framework.
Change-Id: I211818d9c2b2c8a736f4dfc1768c78357383c531
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697631
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Since ALS sensor's Firmware needs to keep track the PWM duty cycle of
each panels' version, therefore the panels' register 0xDA will be used
to identify the PWM duty cycle programmed in each panels' version.
The new /sys/class/drm/card0-DSI1/panelRegDA sysfs will be created,
and it will show the panel's 0XDA reg information.
Change-Id: I997fb15040102b784eeb0a7318239bda4f59ac4b
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697630
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Support the panel's ESD "te_chk_reg_rd" detection and recovery which
will run every 8s to check the TE signal and power_mode for ESD
detection. If ESD detection doesn't see the TE signal or receive an
expected power_mode value, then the display driver will trigger ESD
recovery. If the ESD detection and recovery run 5 consecutive times
but can not retrieve the TE signal or/and expected power_mode, then
the display driver will call BUG() to reboot the phone.
Change-Id: Id9a161cad624746823fcbe144b050d1dbdde18cf
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697626
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Pushing display notifications when it is turning on and off, so
registered listener can become aware of it state.
Change-Id: I5ae139d5a9099a86d94f54f7495ddf12659c98ba
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697625
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
The backlight and HBM are using the same command 0x51. The backlight
ranger will be from 0x000 to 0x640 while HBM on will be at 0xfff and
HBM off will be at 0x640. This is why the display driver should
restore the last backlight setting after exiting the HBM mode.
Change-Id: Icd29cd25e5eb4936369dfefb513e62076f994482
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697623
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Add qcom,mdss-dsi-panel-hbm-is-51cmd to panel's dts to indicate
that the HBM command is using the same backlight command 0x51 command.
Therefore when the HBM is on, then the backlight level will be saved
and backlight command will be ignored. When the HBM is off then stored
backlight level will be set
Port from 9bafa67
Change-Id: I58082c5555a4afbebebd2c1d9e8568c787143d2d
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Signed-off-by: daiss1 <daiss1@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1697612
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
During the panel is enable, we reset the value of the panel register
with default setting.
Change-Id: Idf30593736e66386581b729ae28023035cded122
Signed-off-by: houdz1 <houdz1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697597
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
FOD: Fingerprint of display.
For tianma panel, there are two hbm mode.
1. hbm
2. hbm for FOD(hbm_fod);
But for SMD panel ,there is only one HBM mode.
Port from 9701d728f
Change-Id: Icc09d39502a9549bfba7cd47efca2993a2716110
Signed-off-by: houdz1 <houdz1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697595
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Change the checking returned value of dsi_ctrl_cmd_transfer(), because
if this is a read command then it will return the number byte of
reading when reading succeed. If this is a write command, then it
will return "none-zero" for failure.
Change-Id: I088af5da728dc758470377253b8d4e16d1222c1b
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697593
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Since implementing the factory_kill feature, then the msm_drv needs
to register for reboot_notifier to shut down the display accordingly.
Port from 7445d2d.
Change-Id: I8b6d48205ba819f0d36ad7218852241baa33f014
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697588
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Support ACL when setting panel param, so user-mode can control
the enable/disable of ACL property.
Port form 9f9c112
Change-Id: I6db8673f88fb9fbc85e98f15af654b03706e586f
Signed-off-by: shuoyan <shuoyan@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697583
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Enable "val" to update HBM property, so user-mode can control
the enable/disable of HBM property through connector property.
Port form 4ec72b4
Change-Id: Ieed101ff0bab707ebf2dabc7e533564bf60cbc90
Signed-off-by: shuoyan <shuoyan@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697582
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Add the DSI_CTRL index to indicate which DSI_CTRL is enable.
Port from: 9a63078
Change-Id: I8af0de72ccc0a4152d53db9efd29255ddfa129e8
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697575
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Add the ACL panel param feature which will be controlled
from the user-space
Port from: 6db5516a8
Change-Id: Ib286fbcbb7e1517bd6390d1338d157f371ce680f
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697573
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
BL (bootloader/EUFI) will read the panel information such as panel's
ID and it will pass this information and panel's name in the devtree.
The display driver will populate these information and store in the
sysFS
Port from: 8908f4c
Change-Id: I3e212b48ceb02b52bbb2026d4c37ea8542d9622e
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697472
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Set the panel's enable_status when the panel's cont_splash_enable
feature is set.
This dsi_display_enable_status() API will provide the panels
information such as the panel_name, probe information
and panels's enable/disable information to the touch driver.
Port from: fbc31d9a7
Change-Id: Idba46c92b950965351de9d951e6067d241090b77
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697469
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Adding a name to DSI panel enable status API
Port from: f41f8deae
Change-Id: Ibde9b1582454275c7491422b0101c78ba507c7b4
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697410
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Panel API need to report probe status in order for consumer to
determine panel's presence
Port from : 75d097728
Change-Id: I8252c0e0865780e0b0dbe5252dc663981fc16ba3
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697408
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
This dsi_display_is_panel_enable(int panel_index) API will take in
panel_index equal 0 for Primary and 1 for Seconday display. It will
return TRUE if the panel is ON or FALSE when it's OFF
Port from: b5f053287
Change-Id: I06ec806c9878a9eaa2b1c08b84968102e258bda3
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1412835
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1697406
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Adding the KMS property (HBM/ACL) testing functionality to
motUtil tool so these KMS property can be tested and verified as
standalone without supporting of the Android FW apk.
Port from 2401ffc.
Change-Id: I548224cf21d266f4f4bb2373f8a9fbf041cf84d7
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1412834
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1697401
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Add the Display Utility(DispUtil) support to the motUtil Debugfs Framework.
This dispUtil tool will send a command from the motUtil debugfs to the panel
or it can read any information from panel back.
The 1st byte (set to 0) will indicate for the displUtil tool.
DispUtil Format:
1st 2nd 3rd 4th 5th 6th
0=DispUtil 0=Pri Disp 0=write 0=HS 0=DCS number byte to read
1=Sec Disp 1=read 1=LP 1=Generic
7th 8th 9th....
payldLen_u payldLen_l payload
Port from: 890aa1c9
Change-Id: I4ebba9f87dadcc3e9c22ddb58b4412c7124d7895
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697321
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Adding the motUtil debugfs in /d/dri/0/debug to provide a tool for
developer/tester to interface with the Display driver framework
Port from: 890aa1c9
Change-Id: I5ca8fbd5f8aa17233683d82a66fe6ed45e722305
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697292
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
After the ESD detection and recovery keep trying to recover panel, but
after 5 times, unsuccessfully recovery the panel, then cal BUG to reboot
the phone.
Port from: c3d7c03
Change-Id: I595027afdbb7934b63d2f41c151277a9c48b5e21
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697290
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Shuo Yan <shuoyan@motorola.com>
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Check display turns on during the display resume. If it doesn't, then
trigger the ESD to restart the panel, instead waiting until the ESD
thread starts, detects, and perform ESD recovery.
Port from: 17e936d
Change-Id: I040b35c7ff27d35db15eedcbf94df80e6185da19
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697288
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Shuo Yan <shuoyan@motorola.com>
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Check the panel's power_mode after it turns on, to see if the panel can turn
on correctly. If it doesn't not, then trigger the ESD recovery to fix it.
Port from: 767ee61
Change-Id: Iaf7f5da55a839037b0fa1e25ac84faf5df480ae5
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697279
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
After the Boot Loader (BL) detects the panel information, or reading
the ESD UTAG setting, the BL will write these information to the DTS.
The display driver from kernel and parse and save these setting.
Port from: 2701eb2
Change-Id: Ibd1c9429854655ea7c80222ce64c3b86c6df2eda
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697267
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Shuo Yan <shuoyan@motorola.com>
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Add a new display's backlight type "bl_ctrl_dummy". With this
backlight type, the panel backlight driver will ignore any backlight
requests. This new backlight type will be used with a bare_board or
no-display configuration and the display driver doesn't need to have
any communication with panel.
Port from: (CR).
Change-Id: I1b0c2759deaa4b0808fd4f0503943a191842235e
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697250
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Shuo Yan <shuoyan@motorola.com>
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Add some pr_info to indicate the DSI and panel are turning off
and on for ESD or black screen investigation.
Port from: 8c661f3540990aa1c37f1ef9b5b361114eec86ce
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Change-Id: I7c05aa6b0cf8f0128c8421d58d5a22647fd1b164
Reviewed-on: https://gerrit.mot.com/1697229
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Shuo Yan <shuoyan@motorola.com>
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Normal, there is a brightness level from 0-255 (1 byte), but some
panels are support 2 bytes for brightness, (0-1023).
Change-Id: I861aaa3d26e4dbe13183df92f408fdefa709fe61
Reviewed-on: https://gerrit.mot.com/1697222
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Shuo Yan <shuoyan@motorola.com>
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
Drop refcount on pm_suspend commit state if atomic
commit is skipped due to failure. It will avoid frame
trigger during pm_resume call.
Change-Id: Iecd98b106454c82c81a1ef9faaf1af4be2bf19e6
Signed-off-by: Dhaval Patel <pdhaval@codeaurora.org>
Signed-off-by: Jayaprakash Madisetty <quic_jmadiset@quicinc.com>