[PATCH 1/2] drm/msm/dp: service only one irq_hpd if there are multiple irq_hpd pending

2021-04-16 Thread Kuogee Hsieh
Some dongle may generate more than one irq_hpd events in a short period of time. This patch will treat those irq_hpd events as single one and service only one irq_hpd event. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 9 + 1 file changed, 9 insertions(+) diff

[PATCH v3 3/3] drm/msm/dp: check main link status before start aux read

2021-04-16 Thread Kuogee Hsieh
tely if DP controller connection status is in unplugged state. Changes in V3: -- check core_initialized before handle irq_hpd Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_aux.c | 5 + drivers/gpu/drm/msm/dp/dp_display.c | 14 ++ drivers/gpu/drm/msm/dp/dp_link

[PATCH v3 2/3] drm/msm/dp: initialize audio_comp when audio starts

2021-04-16 Thread Kuogee Hsieh
() at dp_hpd_unplug_handle(). Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_audio.c | 1 + drivers/gpu/drm/msm/dp/dp_display.c | 11 +-- drivers/gpu/drm/msm/dp/dp_display.h | 1 + 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_audio.c b/drivers

[PATCH v3 3/3] drm/msm/dp: check main link status before start aux read

2021-04-15 Thread Kuogee Hsieh
tely if DP controller connection status is in unplugged state. Changes in V3: -- check core_initialized before handle irq_hpd Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_aux.c | 5 + drivers/gpu/drm/msm/dp/dp_display.c | 14 ++ drivers/gpu/drm/msm/dp/dp_link

[PATCH v3 2/3] drm/msm/dp: initialize audio_comp when audio starts

2021-04-15 Thread Kuogee Hsieh
() at dp_hpd_unplug_handle(). Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_audio.c | 1 + drivers/gpu/drm/msm/dp/dp_display.c | 11 +-- drivers/gpu/drm/msm/dp/dp_display.h | 1 + 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_audio.c b/drivers

[PATCH v2 1/3] drm/msm/dp: check sink_count before update is_connected status

2021-04-14 Thread Kuogee Hsieh
yd Tested-by: Stephen Boyd Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 15 --- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_display.c b/drivers/gpu/drm/msm/dp/dp_display.c index 5a39da6..0ba71c7 100644 --- a/drivers/gpu/

[PATCH v2 2/3] drm/msm/dp: initialize audio_comp when audio starts

2021-04-14 Thread Kuogee Hsieh
Initialize audio_comp when audio starts and wait for audio_comp at dp_display_disable(). This will take care of both dongle unplugged and display off (suspend) cases. Changes in v2: -- add dp_display_start_audio() Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_audio.c | 1

[PATCH v2 3/3] drm/msm/dp: check main link status before start aux read

2021-04-13 Thread Kuogee Hsieh
Make sure main link is in connection state before start aux read/write operation to avoid unnecessary long delay due to main link had been unplugged. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_aux.c | 5 + drivers/gpu/drm/msm/dp/dp_link.c | 20 +++- 2 files

[PATCH v2 2/3] drm/msm/dp: do not re initialize of audio_comp at display_disable()

2021-04-13 Thread Kuogee Hsieh
is triggered by dongle unplugged. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_display.c b/drivers/gpu/drm/msm/dp/dp_display.c index 0ba71c7..1d71c95 100644 --- a/drivers

[PATCH v2 1/3] drm/msm/dp: check sink_count before update is_connected status

2021-04-13 Thread Kuogee Hsieh
to 1 once an HDMI cable is plugged into the dongle so that display connected status will become true. This checking also apply at pm_resume. Fixes: 94e58e2d06e3 ("drm/msm/dp: reset dp controller only at boot up and pm_resume") Reported-by: Stephen Boyd Signed-off-by: Kuogee Hsieh --

[PATCH 2/2] drm/msm/dp: do not re initialize of audio_comp

2021-04-12 Thread Kuogee Hsieh
. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_aux.c | 18 ++ drivers/gpu/drm/msm/dp/dp_aux.h | 1 + drivers/gpu/drm/msm/dp/dp_display.c | 16 drivers/gpu/drm/msm/dp/dp_link.c| 20 +++- 4 files changed, 46 insertions(+), 9

[PATCH 1/2] drm/msm/dp: check sink_count before update is_connected status

2021-04-12 Thread Kuogee Hsieh
At pm_resume check link sisnk_count before update is_connected status base on HPD real time link status. Also print out error message only when either EV_CONNECT_PENDING_TIMEOUT or EV_DISCONNECT_PENDING_TIMEOUT happen. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 6

[PATCH v3] phy: qcom-qmp: add hbr3_hbr2 voltage and premphasis swing table

2021-03-16 Thread Kuogee Hsieh
Add hbr3_hbr2 voltage and premphasis swing table to support HBR3 link rate. Changes in V2: -- replaced upper case with lower case at hbr3_hbr2 table Changes in v3: -- replace space with tab at hbr3_hbr2 table Signed-off-by: Kuogee Hsieh Reviewed-by: Stephen Boyd --- drivers/phy/qualcomm/phy

[PATCH v2 2/2] drm/msm/dp: add supported max link rate specified from dtsi

2021-02-18 Thread Kuogee Hsieh
te = <54> for max link rate limited at 5.4G link-rate = <81> for max link rate limited at 8.1G Changes in V2: -- allow supported max link rate specified from dtsi Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 1 + drivers/gpu/drm/msm/dp/dp_panel.c | 7

[PATCH v2 1/2] phy/qualcomm: add hbr3_hbr2 voltage and premphasis swing table

2021-02-18 Thread Kuogee Hsieh
Add hbr3_hbr2 voltage and premphasis swing table to support HBR3 link rate. Changes in V2: -- replaced upper case with lower case at hbr3_hbr2 table Signed-off-by: Kuogee Hsieh --- drivers/phy/qualcomm/phy-qcom-qmp.c | 23 +-- 1 file changed, 21 insertions(+), 2 deletions

[PATCH 1/2] phy/qualcomm: add hbr3_hbr2 voltage and premphasis swing table

2021-02-17 Thread Kuogee Hsieh
Add hbr3_hbr2 voltage and premphasis swing table to support HBR3 link rate. Signed-off-by: Kuogee Hsieh --- drivers/phy/qualcomm/phy-qcom-qmp.c | 23 +-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/drivers/phy/qualcomm/phy-qcom-qmp.c b/drivers/phy

[PATCH 2/2] drm/msm/dp: Drop limit link rate at HBR2

2021-02-17 Thread Kuogee Hsieh
Drop limit link rate at HBR2 to support link rate upto HBR3. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_panel.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_panel.c b/drivers/gpu/drm/msm/dp/dp_panel.c index 9cc8166..63112fa 100644

[PATCH] drm/msm/dp: add support of HBR3 link rate

2021-02-17 Thread Kuogee Hsieh
Add hbr3_hbr2 voltage and pre-emphasis swing table to support HBR3 link rate Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_panel.c | 4 drivers/phy/qualcomm/phy-qcom-qmp.c | 24 ++-- 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/drivers

[PATCH] drm/msm/dp: reset dp controller only at boot up and pm_resume

2021-02-05 Thread Kuogee Hsieh
DP_SW_RESET at boot up and pm_resume. This patch also reinit video_comp before configure dp controller to avoid missing VIDEO_READY interrupt. Fixes: 9fc418430c65 ("drm/msm/dp: unplug interrupt missed after irq_hpd handler") Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_ctrl

[PATCH v2 0/2] fix missing unplug interrupt problem

2021-01-13 Thread Kuogee Hsieh
Both AUX_SW_RESET and DP_SW_RESET clear pending HPD interrupts. Therefore irq_hpd handler should not issues either aux or sw reset to avoid following unplug interrupt be cleared accidentally. Kuogee Hsieh (2): drm/msm/dp: return fail when both link lane and rate are 0 at dpcd read drm/msm

[PATCH v2 2/2] drm/msm/dp: unplug interrupt missed after irq_hpd handler

2021-01-13 Thread Kuogee Hsieh
accidentally. This patch also postpone handling of irq_hpd until connected state if it happened at connection pending state. Changes in V2: -- add postpone handling of irq_hpd until connected state -- check DP_TRAINING_1 instead of DP_TRAINING_NONE Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm

[PATCH v2 1/2] drm/msm/dp: return fail when both link lane and rate are 0 at dpcd read

2021-01-13 Thread Kuogee Hsieh
-- add Fixes tag Fixes: 78f94fbb6122 ("drm/msm/dp: fix connect/disconnect handled at irq_hpd") Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_panel.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_panel.c b/drive

[PATCH 1/2] drm/msm/dp: postpone irq_hpd event during connection pending state

2021-01-07 Thread Kuogee Hsieh
irq_hpd event can only be executed at connected state. Therefore irq_hpd event should be postponed if it happened at connection pending state. This patch also make sure both link rate and lane are valid before start link training. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp

[PATCH 2/2] drm/msm/dp: unplug interrupt missed after irq_hpd handler

2021-01-07 Thread Kuogee Hsieh
accidentally. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_aux.c | 7 --- drivers/gpu/drm/msm/dp/dp_catalog.c | 24 drivers/gpu/drm/msm/dp/dp_ctrl.c| 15 ++- 3 files changed, 34 insertions(+), 12 deletions(-) diff --git a/drivers/gpu

[PATCH 0/2] *** fix missing unplug interrupt problem ***

2021-01-07 Thread Kuogee Hsieh
Both AUX_SW_RESET and DP_SW_RESET clear pending HPD interrupts. Therefore irq_hpd handler should not issues either aux or sw reset to avoid following unplug interrupt be cleared accidentally. Kuogee Hsieh (2): drm/msm/dp: postpone irq_hpd event during connection pending state drm/msm/dp

[PATCH] drm/msm/dp: postpone irq_hpd event during connection pending state

2020-12-18 Thread Kuogee Hsieh
irq_hpd event can only be executed at connected state. Therefore irq_hpd event should be postponed if it happened at connection pending state. This patch also make sure both link rate and lane are valid before start link training. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp

[PATCH v3] drm/msm/dp: fix connect/disconnect handled at irq_hpd

2020-11-18 Thread Kuogee Hsieh
complaint Changes in V3: -- add encoder_mode_set into struct dp_display_private Reported-by: kernel test robot Fixes: 26b8d66a399e ("drm/msm/dp: promote irq_hpd handle to handle link training correctly") Tested-by: Stephen Boyd Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp

[PATCH v2] drm/msm/dp: fix connect/disconnect handled at irq_hpd

2020-11-17 Thread Kuogee Hsieh
complaint Reported-by: kernel test robot Fixes: 26b8d66a399e ("drm/msm/dp: promote irq_hpd handle to handle link training correctly") Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 91 ++--- 1 file changed, 54 insertions(+), 37 deletion

[PATCH] drm/msm/dp: fix connect/disconnect handled at ir_hdp

2020-11-13 Thread Kuogee Hsieh
Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 78 + 1 file changed, 45 insertions(+), 33 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_display.c b/drivers/gpu/drm/msm/dp/dp_display.c index 27e7e27b8b90..4e84f500b721 100644 --- a/drivers/gpu/

[PATCH v2 3/3] drm/msm/dp: promote irq_hpd handle to handle link training correctly

2020-11-13 Thread Kuogee Hsieh
ilure of link training") Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 25 + 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_display.c b/drivers/gpu/drm/msm/dp/dp_display.c index 0c0573ad34e6..27e7e27b8

[PATCH v2 1/3] drm/msm/dp: deinitialize mainlink if link training failed

2020-11-13 Thread Kuogee Hsieh
on state caused by failure of link training") Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_catalog.c | 2 +- drivers/gpu/drm/msm/dp/dp_catalog.h | 2 +- drivers/gpu/drm/msm/dp/dp_ctrl.c| 40 +++-- drivers/gpu/drm/msm/dp/dp_display.c | 15 ++- dr

[PATCH v2 2/3] drm/msm/dp: skip checking LINK_STATUS_UPDATED bit

2020-11-13 Thread Kuogee Hsieh
t PHY compliance tests fixup") Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_ctrl.c | 20 ++-- drivers/gpu/drm/msm/dp/dp_link.c | 29 ++--- 2 files changed, 20 insertions(+), 29 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_ctrl.c b/d

[PATCH v2 0/3] fix dp link training failed at irq_hpd request

2020-11-13 Thread Kuogee Hsieh
Some dongle require link training be done at irq_hpd request. This serial patches address the issues so that DP/HDMI display can be lit up properlly. This serial Patch also fixes clock stuck at "off" state error caused by previous link training failed. Kuogee Hsieh (3): drm/msm/dp: de

[PATCH v2 0/2] cherry-pick miised DP related patches

2020-11-03 Thread Kuogee Hsieh
Cherry-pick two missed drm/msm/dp related patches to msm-next-staging Kuogee Hsieh (2): drm/msm/dp: return correct connection status after suspend drm/msm/dp: fixes wrong connection state caused by failure of link train drivers/gpu/drm/msm/dp/dp_catalog.c | 13 +++ drivers/gpu/drm/msm

[PATCH v2 2/2] drm/msm/dp: fixes wrong connection state caused by failure of link train

2020-11-03 Thread Kuogee Hsieh
: -- Add more information to commit message. Changes in V3: -- change base Changes in V4: -- add Fixes tag Fixes: 22688d4067f6 (drm/msm/dp: return correct connection status after suspend) Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 42

[PATCH v2 1/2] drm/msm/dp: return correct connection status after suspend

2020-11-03 Thread Kuogee Hsieh
gon Chipsets) Tested-by: Stephen Boyd Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_catalog.c | 13 +++ drivers/gpu/drm/msm/dp/dp_catalog.h | 1 + drivers/gpu/drm/msm/dp/dp_ctrl.c| 5 + drivers/gpu/drm/msm/dp/dp_display.c | 144 +++- drivers/gpu/drm/msm

[PATCH 3/3] FROMLIST: drm/msm/dp: fixes wrong connection state caused by failure of link train

2020-11-03 Thread Kuogee Hsieh
: -- Add more information to commit message. Changes in V3: -- change base Signed-off-by: Kuogee Hsieh (am from https://lore.kernel.org/patchwork/patch/1320896/) (also found at https://lore.kernel.org/r/20201013233544.5324-1-khs...@codeaurora.org) BUG=b:166844571, b:148864048, b:170279524 TEST

[PATCH 2/3] FIXUP: FROMLIST: drm/msm/dp: return correct connection status after suspend

2020-11-03 Thread Kuogee Hsieh
atomic_t with u32 Changes in v4 -- call dp_display_host_deinit() at dp_pm_suspend() -- call dp_display_host_init() at msm_dp_display_enable() -- fix phy->init_count unbalance which causes link training failed Signed-off-by: Kuogee Hsieh (am from https://lore.kernel.org/patchwork/patch/1320

[PATCH 1/3] FROMLIST: drm/msm/dp: return correct connection status after suspend

2020-11-03 Thread Kuogee Hsieh
at both dp_pm_suspend and dp_pm_resume. Signed-off-by: Kuogee Hsieh (am from https://lore.kernel.org/patchwork/patch/1312265/) (also found at https://lore.kernel.org/r/20200926203454.13643-1-khs...@codeaurora.org) BUG=b:166844571, b:148864048 TEST=On lazor, suspend with DP connected, disconnect cable

[PATCH 0/3] cherry-pick missed patches to msm-next-staging

2020-11-03 Thread Kuogee Hsieh
cherry-pick 3 patches at chromeos-5.4 to msm-next-staging Kuogee Hsieh (2): FROMLIST: drm/msm/dp: return correct connection status after suspend FROMLIST: drm/msm/dp: fixes wrong connection state caused by failure of link train Stephen Boyd (1): FIXUP: FROMLIST: drm/msm/dp: return

[PATCH 0/3] fix dp link training failed at irq_hpd request

2020-11-03 Thread Kuogee Hsieh
Some dongle require link training be done at irq_hpd request. This serial patches address the issues so that DP/HDMI display can be lit up properlly. This serial Patch also fixes clock stuck at "off" state error caused by previous link training failed. Kuogee Hsieh (3): drm/msm/dp: de

[PATCH 3/3] drm/msm/dp: promote irq_hpd handle to handle link training correctly

2020-11-03 Thread Kuogee Hsieh
Some dongles require link training done at irq_hpd request instead of plugin request. This patch promote irq_hpd handler to handle link training and setup hpd_state correctly. Fixes: fdaf9a5e3c15 (drm/msm/dp: fixes wrong connection state caused by failure of link training) Signed-off-by: Kuogee

[PATCH 1/3] drm/msm/dp: deinitialize mainlink if link training failed

2020-11-03 Thread Kuogee Hsieh
Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_catalog.c | 2 +- drivers/gpu/drm/msm/dp/dp_catalog.h | 2 +- drivers/gpu/drm/msm/dp/dp_ctrl.c| 40 +++-- drivers/gpu/drm/msm/dp/dp_display.c | 15 ++- drivers/gpu/drm/msm/dp/dp_panel.c | 2 +- 5 fil

[PATCH 2/3] drm/msm/dp: skip checking LINK_STATUS_UPDATED bit

2020-11-03 Thread Kuogee Hsieh
-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_ctrl.c | 20 ++-- drivers/gpu/drm/msm/dp/dp_link.c | 29 ++--- 2 files changed, 20 insertions(+), 29 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_ctrl.c b/drivers/gpu/drm/msm/dp/dp_ctrl.c index c7af040ce252

[PATCH] drm/msm/dp: promote irq_hpd handle to handle link trainign correctly

2020-10-30 Thread Kuogee Hsieh
Some dongles, such as Apple, required link training done at irq_hpd request instead of plugin request. This patch promote irq_hpd hanlder to handle link training and setup hpd_state correctly. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 20 ++-- 1 file

[PATCH] drm/msm/dp: deinitialize mainlink if link training failedo

2020-10-30 Thread Kuogee Hsieh
Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_ctrl.c| 34 +++-- drivers/gpu/drm/msm/dp/dp_display.c | 13 +++ 2 files changed, 45 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_ctrl.c b/drivers/gpu/drm/msm/dp/dp_ctrl.c index ce

[PATCH v2] drm/msm/dp: skip checking LINK_STATUS_UPDATED bit

2020-10-30 Thread Kuogee Hsieh
. For example 0x0A is equivalent to 2.7Gb. This patch also convert link rate correctly to fix phy compliance test link rate error. Chanegs in V2: -- revise commit text Fixes: fd4a29bed29b (drm/msm/dp: DisplayPort PHY compliance tests fixup) Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp

[PATCH v3] drm/msm/dp: add opp_table corner voting support base on dp_ink_clk rate

2020-10-20 Thread Kuogee Hsieh
Set link rate by using OPP set rate api so that CX level will be set accordingly based on the link rate. Changes in v2: -- remove dev from dp_ctrl_put() parameters -- Add more information to commit message Changes in v3: -- return when dev_pm_opp_set_clkname() failed Signed-off-by: Kuogee Hsieh

[PATCH] drm/msm/dp: skip checking LINK_STATUS_UPDATED bit

2020-10-20 Thread Kuogee Hsieh
No need to check LINK_STATuS_UPDATED bit before return 6 bytes of link status during link training. This patch also fix phy compliance test link rate conversion error. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_ctrl.c | 20 ++-- drivers/gpu/drm/msm/dp/dp_link.c

[PATCH v4] drm/msm/dp: fixes wrong connection state caused by failure of link train

2020-10-14 Thread Kuogee Hsieh
: -- Add more information to commit message. Changes in V3: -- change base Changes in V4: -- add Fixes tag Fixes: 22688d4067f6 (drm/msm/dp: return correct connection status after suspend) Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 42

[PATCH v5] drm/msm/dp: return correct connection status after suspend

2020-10-14 Thread Kuogee Hsieh
gon Chipsets) Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_catalog.c | 13 +++ drivers/gpu/drm/msm/dp/dp_catalog.h | 1 + drivers/gpu/drm/msm/dp/dp_ctrl.c| 5 + drivers/gpu/drm/msm/dp/dp_display.c | 144 +++- drivers/gpu/drm/msm/dp/dp_reg.h | 2 + 5 fi

[PATCH v4] drm/msm/dp: return correct connection status after suspend

2020-10-13 Thread Kuogee Hsieh
Changes in v4 -- call dp_display_host_deinit() at dp_pm_suspend() -- call dp_display_host_init() at msm_dp_display_enable() -- fix phy->init_count unbalance which causes link training failed Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_catalog.c | 13 +++ drivers/gpu/drm/msm

[PATCH v3] drm/msm/dp: fixes wrong connection state caused by failure of link train

2020-10-13 Thread Kuogee Hsieh
: -- Add more information to commit message. Changes in V3: -- change base Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 40 ++--- drivers/gpu/drm/msm/dp/dp_panel.c | 5 2 files changed, 24 insertions(+), 21 deletions(-) diff --git a/drivers

[PATCH v2] drm/msm/dp: fixes wrong connection state caused by failure of link train

2020-10-10 Thread Kuogee Hsieh
: -- Add more information to commit message. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 43 +++-- drivers/gpu/drm/msm/dp/dp_panel.c | 5 2 files changed, 27 insertions(+), 21 deletions(-) diff --git a/drivers/gpu/drm/msm/dp/dp_display.c b

[PATCH v2] drm/msm/dp: add opp_table corner voting support base on dp_ink_clk rate

2020-10-10 Thread Kuogee Hsieh
Set link rate by using OPP set rate api so that CX level will be set accordingly based on the link rate. Changes in v2: -- remove dev from dp_ctrl_put() parameters -- Add more information to commit message Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_ctrl.c| 27

[PATCH v3] drm/msm/dp: return correct connection status after suspend

2020-10-10 Thread Kuogee Hsieh
more information to commit message. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_catalog.c | 13 drivers/gpu/drm/msm/dp/dp_catalog.h | 1 + drivers/gpu/drm/msm/dp/dp_display.c | 117 +--- drivers/gpu/drm/msm/dp/dp_reg.h | 2 + 4 files changed

[PATCH v2] drm/msm/dp: add opp_table corner voting support base on dp_ink_clk rate

2020-10-03 Thread Kuogee Hsieh
Set link rate by using OPP set rate api so that CX level will be set accordingly based on the link rate. Changes in v2: -- remove dev from dp_ctrl_put() parameters -- address review comments Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_ctrl.c| 26 + drivers/gpu

[PATCH] drm/msm/dp: fixes wrong connection state caused by failure of link train

2020-10-02 Thread Kuogee Hsieh
Connection state is set incorrectly happen at either failure of link train or cable plugged in while suspended. This patch fixes these problems. This patch also replace ST_SUSPEND_PENDING with ST_DISPLAY_OFF. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_display.c | 52

[PATCH] drm/msm/dp: add voltage corners voting support base on dp link rate

2020-09-29 Thread Kuogee Hsieh
Set link rate by using OPP set rate api so that CX level will be set accordingly base on the link rate. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_ctrl.c| 33 ++- drivers/gpu/drm/msm/dp/dp_ctrl.h| 2 +- drivers/gpu/drm/msm/dp/dp_display.c | 8

[PATCH v2] drm/msm/dp: return correct connection status after suspend

2020-09-26 Thread Kuogee Hsieh
at both dp_pm_suspend and dp_pm_resume. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_catalog.c | 13 ++ drivers/gpu/drm/msm/dp/dp_catalog.h | 1 + drivers/gpu/drm/msm/dp/dp_display.c | 67 - drivers/gpu/drm/msm/dp/dp_reg.h | 2 + 4 files changed, 43

[PATCH] drm/msm/dp: return correct connection status after suspend/resume

2020-09-24 Thread Kuogee Hsieh
return connection status base on hpd realtime state status Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/dp/dp_catalog.c | 13 +++ drivers/gpu/drm/msm/dp/dp_catalog.h | 1 + drivers/gpu/drm/msm/dp/dp_display.c | 58 - drivers/gpu/drm/msm/dp/dp_reg.h

[PATCH v6] drm/msm/dp: Add DP compliance tests on Snapdragon Chipsets

2020-09-11 Thread Kuogee Hsieh
: -- at msm_dp_display_enable() do not return until resume_done to avoid kms commit timeout Signed-off-by: Kuogee Hsieh This patch depends-on following series: https://lore.kernel.org/dri-devel/20200827211658.27479-1-tan...@codeaurora.org/ --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 6

[PATCH v5] drm/msm/dp: Add DP compliance tests on Snapdragon Chipsets

2020-09-09 Thread Kuogee Hsieh
in v4: - add ST_SUSPEND_PENDING to handles suspend/modeset test operations - clear dp phy aux interrupt status when ERR_DPPHY_AUX error - send segment addr during edid read - clear bpp depth before MISC register write Changes in v5: - add ST_SUSPENDED to fix crash at resume Signed-off-by: Kuogee Hsieh

[PATCH v5] drm/msm/dp: Add DP compliance tests on Snapdragon Chipsets

2020-09-04 Thread Kuogee Hsieh
in v4: - add ST_SUSPEND_PENDING to handles suspend/modeset test operations - clear dp phy aux interrupt status when ERR_DPPHY_AUX error - send segment addr during edid read - clear bpp depth before MISC register write Changes in v5: - add ST_SUSPENDED to fix crash at resume Signed-off-by: Kuogee Hsieh

[PATCH v4] drm/msm/dp: Add DP compliance tests on Snapdragon Chipsets

2020-08-27 Thread Kuogee Hsieh
in v4: - fix crash while device in suspend mode - also fix modeset test This patch depends-on: https://lkml.kernel.org/lkml/20200827211658.27479-1-tan...@codeaurora.org/ Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 6 + drivers/gpu/drm/msm/dp/dp_aux.c

[PATCH v3] drm/msm/dp: Add DP compliance tests on Snapdragon Chipsets

2020-08-18 Thread Kuogee Hsieh
-by: Kuogee Hsieh This patch depends-on following series: https://patchwork.kernel.org/project/dri-devel/list/?series=334239 This patch depends-on following series: https://patchwork.kernel.org/project/dri-devel/list/?series=334239 --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 6 + drivers

[PATCH v3] drm/msm/dp: Add DP compliance tests on Snapdragon Chipsets

2020-08-18 Thread Kuogee Hsieh
depends-on following series: https://lkml.kernel.org/lkml/20200812044223.19279-1-tan...@codeaurora.org/t.atom Signed-off-by: Kuogee Hsieh Signed-off-by: Guenter Roeck Signed-off-by: Tanmay Shah --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 6 + drivers/gpu/drm/msm/dp/dp_aux.c

[PATCH v2] drm/msm/dp: Add DP compliance tests on Snapdragon Chipsets

2020-08-10 Thread Kuogee Hsieh
- Check and enable link clock during modeset - Drop unused code and fix function prototypes. - set sink power to normal operation state (D0) before CDPD read Signed-off-by: Kuogee Hsieh Signed-off-by: Guenter Roeck Signed-off-by: Tanmay Shah --- drivers/gpu/drm/msm/dp/dp_aux.c | 3

[PATCH] drm/msm/dp: Add DP compliance tests on Snapdragon Chipsets

2020-07-07 Thread Kuogee Hsieh
-devel/20200630184507.15589-1-tan...@codeaurora.org/ Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 12 +- drivers/gpu/drm/msm/dp/dp_aux.c | 4 + drivers/gpu/drm/msm/dp/dp_aux.h | 1 + drivers/gpu/drm/msm/dp/dp_catalog.c | 78