Add BXT A0/A1 WA for HPD swap in generic way
Subsystems (2)
cover Add BXT A0/A1 WA for HPD swap in generic way
This series adds BXT HPD pin swap WA for A0/A1 by setting right hpd_pin and irq_port for PORT_B.
Sonika Jindal (3):
drm/i915: Dont enable hpd for eDP drm/i915/bxt: Add HPD support for DDIA drm/i915/bxt: WA for swapped HPD pins in A stepping
drivers/gpu/drm/i915/i915_irq.c | 10 +++------- drivers/gpu/drm/i915/intel_ddi.c | 10 +++++++++- drivers/gpu/drm/i915/intel_dp.c | 4 +++- drivers/gpu/drm/i915/intel_hdmi.c | 9 ++++++++- 4 files changed, 23 insertions(+), 10 deletions(-)
Signature · 6 lines
1.7.10.4 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH 1/3 drm/i915: Dont enable hpd for eDP
With HPD support added for all ports including PORT_A, setting hpd_pin will result in enabling of hpd to edp as well. There is no need to enable HPD on PORT_A hence this patch removes hpd_pin update for PORT_A, where edp will be connected. it can be added back when required
--- drivers/gpu/drm/i915/intel_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/i915/intel_dp.c +1 -1
@@ -5784,7 +5784,7 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,/* Set up the hotplug pin. */ switch (port) {case PORT_A : - intel_encoder->hpd_pin =HPD_PORT_A ; +/* Not enabling edp interrupts */ break ;case PORT_B : intel_encoder->hpd_pin =HPD_PORT_B ;
Signature · 6 lines
1.7.10.4 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 1/3] drm/i915: Dont enable hpd for eDP
Quoted 23 lines · Sonika Jindal
With HPD support added for all ports including
PORT_A, settinghpd_pinwill result in enabling of hpd to edp as well. There is no need to enable HPD onPORT_Ahence this patch removeshpd_pinupdate forPORT_A, where edp will be connected. it can be added back when requiredSigned-off-by Sonika Jindal <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/gpu/drm/i915/intel_dp.c +1
-1@@ -5784,7 +5784,7 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,/* Set up the hotplug pin. */ switch (port) {case PORT_A : - intel_encoder->hpd_pin =HPD_PORT_A ; +/* Not enabling edp interrupts */ break ;case PORT_B : intel_encoder->hpd_pin =HPD_PORT_B ;
Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Jani Nikula
maintainerRe: [PATCH 1/3] drm/i915: Dont enable hpd for eDP
Quoted 7 lines · Sivakumar Thulasimani
Reviewed-by Sivakumar Thulasimani <[email protected]>Quoted 4 lines · Sonika Jindal
With HPD support added for all ports including
PORT_A, settinghpd_pinwill result in enabling of hpd to edp as well. There is no need to enable HPD onPORT_Ahence this patch removeshpd_pinupdate forPORT_A, where edp will be connected. it can be added back when required
What? You can't just go ahead and remove HPD from eDP sinks.
BR,
Jani.
Quoted 28 lines
Quoted 19 lines
Signed-off-by Sonika Jindal <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/gpu/drm/i915/intel_dp.c +1
-1@@ -5784,7 +5784,7 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,/* Set up the hotplug pin. */ switch (port) {case PORT_A : - intel_encoder->hpd_pin =HPD_PORT_A ; +/* Not enabling edp interrupts */ break ;case PORT_B : intel_encoder->hpd_pin =HPD_PORT_B ;Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Signature · 5 lines
Jani Nikula, Intel Open Source Technology Center _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 1/3] drm/i915: Dont enable hpd for eDP
Quoted 4 lines · Jani Nikula
Quoted 3 lines · Sivakumar Thulasimani
Reviewed-by Sivakumar Thulasimani <[email protected]>On 8/10/2015 10:35 AM, Sonika Jindal wrote:
Quoted 8 lines
Quoted 4 lines
Quoted 4 lines
With HPD support added for all ports including
PORT_A, settinghpd_pinwill result in enabling of hpd to edp as well. There is no need to enable HPD onPORT_Ahence this patch removeshpd_pinupdate forPORT_A, where edp will be connected. it can be added back when requiredWhat? You can't just go ahead and remove HPD from eDP sinks.
BR,
Jani.
Nope, we are not removing HPD for edp sinks, it was never there in the first place. It was enabled for CHV (even there by mistake since PORT B/C was both DP and eDP) but it was never there for any other plaforms nor is it used for any purpose (PSR must use it, but i dont see code for it as well).
Quoted 27 lines
Quoted 27 lines
Quoted 19 lines
Signed-off-by Sonika Jindal <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/gpu/drm/i915/intel_dp.c +1
-1@@ -5784,7 +5784,7 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,/* Set up the hotplug pin. */ switch (port) {case PORT_A : - intel_encoder->hpd_pin =HPD_PORT_A ; +/* Not enabling edp interrupts */ break ;case PORT_B : intel_encoder->hpd_pin =HPD_PORT_B ;Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Jani Nikula
maintainerRe: [PATCH 1/3] drm/i915: Dont enable hpd for eDP
Quoted 13 lines · Sivakumar Thulasimani
Quoted 4 lines · Jani Nikula
Quoted 3 lines · Sivakumar Thulasimani
Reviewed-by Sivakumar Thulasimani <[email protected]>On 8/10/2015 10:35 AM, Sonika Jindal wrote:
Quoted 8 lines
Quoted 4 lines
Quoted 4 lines
With HPD support added for all ports including
PORT_A, settinghpd_pinwill result in enabling of hpd to edp as well. There is no need to enable HPD onPORT_Ahence this patch removeshpd_pinupdate forPORT_A, where edp will be connected. it can be added back when requiredWhat? You can't just go ahead and remove HPD from eDP sinks.
BR,
Jani.
Quoted 7 lines
Nope, we are not removing HPD for edp sinks, it was never there in the first place. It was
enabled for CHV (even there by mistake since PORT B/C was both DP and eDP) but it was
never there for any other plaforms nor is it used for any purpose (PSR must use it, but i
dont see code for it as well).
Are you saying there's no HPD enabled in our *hardware* for eDP? Or driver?
My point is, is this patch making it harder to enable eDP hpd handling (e.g. for PSR or DP link re-training) in the future? We currently take it into account in a few places, and if we start removing that, it will be a loss of effort to first remove and then add it back.
BR,
Jani.
Quoted 32 lines
Quoted 27 lines
Quoted 27 lines
Quoted 19 lines
Signed-off-by Sonika Jindal <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/gpu/drm/i915/intel_dp.c +1
-1@@ -5784,7 +5784,7 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,/* Set up the hotplug pin. */ switch (port) {case PORT_A : - intel_encoder->hpd_pin =HPD_PORT_A ; +/* Not enabling edp interrupts */ break ;case PORT_B : intel_encoder->hpd_pin =HPD_PORT_B ;Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfxSignature · 2 lines
regards, Sivakumar
Signature · 5 lines
Jani Nikula, Intel Open Source Technology Center _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 1/3] drm/i915: Dont enable hpd for eDP
Quoted 22 lines · Jani Nikula
Quoted 13 lines · Sivakumar Thulasimani
Quoted 4 lines · Jani Nikula
Quoted 3 lines · Sivakumar Thulasimani
Reviewed-by Sivakumar Thulasimani <[email protected]>On 8/10/2015 10:35 AM, Sonika Jindal wrote:
Quoted 8 lines
Quoted 4 lines
Quoted 4 lines
With HPD support added for all ports including
PORT_A, settinghpd_pinwill result in enabling of hpd to edp as well. There is no need to enable HPD onPORT_Ahence this patch removeshpd_pinupdate forPORT_A, where edp will be connected. it can be added back when requiredWhat? You can't just go ahead and remove HPD from eDP sinks.
BR,
Jani.Quoted 7 lines
Nope, we are not removing HPD for edp sinks, it was never there in the first place. It was
enabled for CHV (even there by mistake since PORT B/C was both DP and eDP) but it was
never there for any other plaforms nor is it used for any purpose (PSR must use it, but i
dont see code for it as well).
Quoted 7 lines
Are you saying there's no HPD enabled in our *hardware* for eDP? Or driver?
My point is, is this patch making it harder to enable eDP hpd handling (e.g. for PSR or DP link re-training) in the future? We currently take it into account in a few places, and if we start removing that, it will be a loss of effort to first remove and then add it back.
I have a branch with (untested) port A/E HPD support (+ a bunch of SPT+ irq handler reorganization). I guess I should post that in case people are interested in this stuff.
Signature · 6 lines
Ville Syrjälä Intel OTC _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 1/3] drm/i915: Dont enable hpd for eDP
In reply to Jani NikulaQuoted 24 lines · Jani Nikula
Quoted 13 lines · Sivakumar Thulasimani
Quoted 4 lines · Jani Nikula
Quoted 3 lines · Sivakumar Thulasimani
Reviewed-by Sivakumar Thulasimani <[email protected]>On 8/10/2015 10:35 AM, Sonika Jindal wrote:
Quoted 8 lines
Quoted 4 lines
Quoted 4 lines
With HPD support added for all ports including
PORT_A, settinghpd_pinwill result in enabling of hpd to edp as well. There is no need to enable HPD onPORT_Ahence this patch removeshpd_pinupdate forPORT_A, where edp will be connected. it can be added back when requiredWhat? You can't just go ahead and remove HPD from eDP sinks.
BR,
Jani.Quoted 7 lines
Nope, we are not removing HPD for edp sinks, it was never there in the first place. It was
enabled for CHV (even there by mistake since PORT B/C was both DP and eDP) but it was
never there for any other plaforms nor is it used for any purpose (PSR must use it, but i
dont see code for it as well).Are you saying there's no HPD enabled in our *hardware* for eDP? Or driver?
Quoted 7 lines
My point is, is this patch making it harder to enable eDP hpd handling (e.g. for PSR or DP link re-training) in the future? We currently take it into account in a few places, and if we start removing that, it will be a loss of effort to first remove and then add it back.
BR,
Jani.
i was referring to our driver only.
Our VLV/CHV code already receives hpd for every pps on and off which is later ignored. if we dont disable HPD on eDPs this behavior will be extended for all platforms which i feel is too costly to keep enabled when there is no purpose for it right now.
if anyone later requires HPD , they might need it for PSR panels only and since that code is not available as of now, this can be added along with those changes so i feel this is the better tradeoff :)
Quoted 32 lines
Quoted 32 lines
Quoted 28 lines
Quoted 28 lines
Quoted 20 lines
Signed-off-by Sonika Jindal <[email protected]>--- drivers/gpu/drm/i915/intel_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/gpu/drm/i915/intel_dp.c +1
-1@@ -5784,7 +5784,7 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,/* Set up the hotplug pin. */ switch (port) {case PORT_A : - intel_encoder->hpd_pin =HPD_PORT_A ; +/* Not enabling edp interrupts */ break ;case PORT_B : intel_encoder->hpd_pin =HPD_PORT_B ;Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfxSignature · 2 lines
regards, Sivakumar
Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 1/3] drm/i915: Dont enable hpd for eDP
Quoted 34 lines · Sivakumar Thulasimani
Quoted 24 lines · Jani Nikula
Quoted 13 lines · Sivakumar Thulasimani
Quoted 4 lines · Jani Nikula
Quoted 3 lines · Sivakumar Thulasimani
Reviewed-by Sivakumar Thulasimani <[email protected]>On 8/10/2015 10:35 AM, Sonika Jindal wrote:
Quoted 8 lines
Quoted 4 lines
Quoted 4 lines
With HPD support added for all ports including
PORT_A, settinghpd_pinwill result in enabling of hpd to edp as well. There is no need to enable HPD onPORT_Ahence this patch removeshpd_pinupdate forPORT_A, where edp will be connected. it can be added back when requiredWhat? You can't just go ahead and remove HPD from eDP sinks.
BR,
Jani.Quoted 7 lines
Nope, we are not removing HPD for edp sinks, it was never there in the first place. It was
enabled for CHV (even there by mistake since PORT B/C was both DP and eDP) but it was
never there for any other plaforms nor is it used for any purpose (PSR must use it, but i
dont see code for it as well).Are you saying there's no HPD enabled in our *hardware* for eDP? Or driver?
Quoted 7 lines
My point is, is this patch making it harder to enable eDP hpd handling (e.g. for PSR or DP link re-training) in the future? We currently take it into account in a few places, and if we start removing that, it will be a loss of effort to first remove and then add it back.
BR,
Jani.
Quoted 7 lines
i was referring to our driver only.
Our VLV/CHV code already receives hpd for every pps on and off which is later ignored. if we dont disable HPD on eDPs this behavior will be extended for all platforms which i feel is too costly to keep enabled when there is no
purpose for it right now.
don't optimize code because you "feel it's costly", only do it when you have hard numbers. One interrupt per pps on or off transition won't be measurable at all.
-Daniel
Signature · 7 lines
Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 1/3] drm/i915: Dont enable hpd for eDP
Quoted 41 lines · Daniel Vetter
Quoted 33 lines · Sivakumar Thulasimani
Quoted 24 lines · Jani Nikula
Quoted 13 lines · Sivakumar Thulasimani
Quoted 4 lines · Jani Nikula
Quoted 3 lines · Sivakumar Thulasimani
Reviewed-by Sivakumar Thulasimani <[email protected]>On 8/10/2015 10:35 AM, Sonika Jindal wrote:
Quoted 8 lines
Quoted 4 lines
Quoted 4 lines
With HPD support added for all ports including
PORT_A, settinghpd_pinwill result in enabling of hpd to edp as well. There is no need to enable HPD onPORT_Ahence this patch removeshpd_pinupdate forPORT_A, where edp will be connected. it can be added back when requiredWhat? You can't just go ahead and remove HPD from eDP sinks.
BR,
Jani.Quoted 7 lines
Nope, we are not removing HPD for edp sinks, it was never there in the first place. It was
enabled for CHV (even there by mistake since PORT B/C was both DP and eDP) but it was
never there for any other plaforms nor is it used for any purpose (PSR must use it, but i
dont see code for it as well).Are you saying there's no HPD enabled in our *hardware* for eDP? Or driver?
Quoted 7 lines
My point is, is this patch making it harder to enable eDP hpd handling (e.g. for PSR or DP link re-training) in the future? We currently take it into account in a few places, and if we start removing that, it will be a loss of effort to first remove and then add it back.
BR,
Jani.Quoted 7 lines
i was referring to our driver only.
Our VLV/CHV code already receives hpd for every pps on and off which is later ignored. if we dont disable HPD on eDPs this behavior will be extended for all platforms which i feel is too costly to keep enabled when there is no
purpose for it right now.
Quoted 4 lines
don't optimize code because you "feel it's costly", only do it when you have hard numbers. One interrupt per pps on or off transition won't be measurable at all.
-Daniel
let me rephrase my concern then :)
a) HPD was never enabled before this patch for edp
b) this patch series will enable hpd for edp
so why should we allow hpd for edp when no one is using it and will cause problems unless ignored explicitly ?
Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 1/3] drm/i915: Dont enable hpd for eDP
Quoted 44 lines · Sivakumar Thulasimani
Quoted 41 lines · Daniel Vetter
Quoted 40 lines · Sivakumar Thulasimani
Quoted 24 lines · Jani Nikula
Quoted 13 lines · Sivakumar Thulasimani
Quoted 4 lines · Jani Nikula
Quoted 3 lines · Sivakumar Thulasimani
Reviewed-by Sivakumar Thulasimani <[email protected]>On 8/10/2015 10:35 AM, Sonika Jindal wrote:
Quoted 8 lines
Quoted 4 lines
Quoted 4 lines
With HPD support added for all ports including
PORT_A, settinghpd_pinwill result in enabling of hpd to edp as well. There is no need to enable HPD onPORT_Ahence this patch removeshpd_pinupdate forPORT_A, where edp will be connected. it can be added back when requiredWhat? You can't just go ahead and remove HPD from eDP sinks.
BR,
Jani.Quoted 7 lines
Nope, we are not removing HPD for edp sinks, it was never there in the first place. It was
enabled for CHV (even there by mistake since PORT B/C was both DP and eDP) but it was
never there for any other plaforms nor is it used for any purpose (PSR must use it, but i
dont see code for it as well).Are you saying there's no HPD enabled in our *hardware* for eDP? Or driver?
Quoted 7 lines
My point is, is this patch making it harder to enable eDP hpd handling (e.g. for PSR or DP link re-training) in the future? We currently take it into account in a few places, and if we start removing that, it will be a loss of effort to first remove and then add it back.
BR,
Jani.i was referring to our driver only.
Our VLV/CHV code already receives hpd for every pps on and off which is later ignored. if we dont disable HPD on eDPs this behavior will be extended for all platforms which i feel is too costly to keep enabled when there is no
purpose for it right now.
Quoted 6 lines
Quoted 4 lines
don't optimize code because you "feel it's costly", only do it when you have hard numbers. One interrupt per pps on or off transition won't be measurable at all.
-Daniellet me rephrase my concern then :)
a) HPD was never enabled before this patch for edp
It was for port!=A, which means all VLV/CHV + some other machines with eDP on port D.
Quoted 4 lines
b) this patch series will enable hpd for edp
so why should we allow hpd for edp when no one is using it and will cause problems
unless ignored explicitly ?
It's not clear it would cause problems. My ILK still seems happy now that I enabled port A HPD on it [1]. As are the VLV/CHV machines. On BSW we had problems but that turned out to be misconfigured pullups on the HPD pins. Before that got fixed there was a lot of noise on the line whenever the panel was off, and that spurred me to write the patch series to keep the HPD disabled while the port is disabled [2].
[1] http://lists.freedesktop.org/archives/intel-gfx/2015-August/073559.html
[2] http://lists.freedesktop.org/archives/intel-gfx/2015-January/058173.html
Signature · 6 lines
Ville Syrjälä Intel OTC _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH 2/3 drm/i915/bxt: Add HPD support for DDIA
In reply to Sonika JindalAlso remove redundant comments.
--- drivers/gpu/drm/i915/i915_irq.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-)
drivers/gpu/drm/i915/i915_irq.c +3 -7
@@ -90,6 +90,7 @@ static const u32 hpd_status_i915[HPD_NUM_PINS] = {/* BXT hpd list */ static const u32 hpd_bxt[HPD_NUM_PINS ] = { + [HPD_PORT_A ] =BXT_DE_PORT_HP_DDIA , [HPD_PORT_B ] =BXT_DE_PORT_HP_DDIB , [HPD_PORT_C ] =BXT_DE_PORT_HP_DDIC };
@@ -3018,30 +3019,25 @@ static void bxt_hpd_irq_setup(struct drm_device *dev)u32 hotplug_port =0 ;u32 hotplug_ctrl; -/* Now, enable HPD */ for_each_intel_encoder (dev, intel_encoder) {if (dev_priv->hotplug.stats[intel_encoder->hpd_pin].state ==HPD_ENABLED ) hotplug_port |= hpd_bxt[intel_encoder->hpd_pin]; } -/* Mask all HPD control bits */ hotplug_ctrl =I915_READ (BXT_HOTPLUG_CTL ) & ~BXT_HOTPLUG_CTL_MASK ; -/* Enable requested port in hotplug control */ -/* TODO: implement (short) HPD support on port A */ -WARN_ON_ONCE (hotplug_port &BXT_DE_PORT_HP_DDIA ); +if (hotplug_port &BXT_DE_PORT_HP_DDIA ) + hotplug_ctrl |=BXT_DDIA_HPD_ENABLE ;if (hotplug_port &BXT_DE_PORT_HP_DDIB ) hotplug_ctrl |=BXT_DDIB_HPD_ENABLE ;if (hotplug_port &BXT_DE_PORT_HP_DDIC ) hotplug_ctrl |=BXT_DDIC_HPD_ENABLE ;I915_WRITE (BXT_HOTPLUG_CTL , hotplug_ctrl); -/* Unmask DDI hotplug in IMR */ hotplug_ctrl =I915_READ (GEN8_DE_PORT_IMR ) & ~hotplug_port;I915_WRITE (GEN8_DE_PORT_IMR , hotplug_ctrl); -/* Enable DDI hotplug in IER */ hotplug_ctrl =I915_READ (GEN8_DE_PORT_IER ) | hotplug_port;I915_WRITE (GEN8_DE_PORT_IER , hotplug_ctrl);POSTING_READ (GEN8_DE_PORT_IER );
Signature · 6 lines
1.7.10.4 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 2/3] drm/i915/bxt: Add HPD support for DDIA
Quoted 52 lines · Sonika Jindal
Also remove redundant comments.
Signed-off-by Sonika Jindal <[email protected]>--- drivers/gpu/drm/i915/i915_irq.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-)drivers/gpu/drm/i915/i915_irq.c +3
-7@@ -90,6 +90,7 @@ static const u32 hpd_status_i915[HPD_NUM_PINS] = {/* BXT hpd list */ static const u32 hpd_bxt[HPD_NUM_PINS ] = { + [HPD_PORT_A ] =BXT_DE_PORT_HP_DDIA , [HPD_PORT_B ] =BXT_DE_PORT_HP_DDIB , [HPD_PORT_C ] =BXT_DE_PORT_HP_DDIC };@@ -3018,30 +3019,25 @@ static void bxt_hpd_irq_setup(struct drm_device *dev)u32 hotplug_port =0 ;u32 hotplug_ctrl; -/* Now, enable HPD */ for_each_intel_encoder (dev, intel_encoder) {if (dev_priv->hotplug.stats[intel_encoder->hpd_pin].state ==HPD_ENABLED ) hotplug_port |= hpd_bxt[intel_encoder->hpd_pin]; } -/* Mask all HPD control bits */ hotplug_ctrl =I915_READ (BXT_HOTPLUG_CTL ) & ~BXT_HOTPLUG_CTL_MASK ; -/* Enable requested port in hotplug control */ -/* TODO: implement (short) HPD support on port A */ -WARN_ON_ONCE (hotplug_port &BXT_DE_PORT_HP_DDIA ); +if (hotplug_port &BXT_DE_PORT_HP_DDIA ) + hotplug_ctrl |=BXT_DDIA_HPD_ENABLE ;if (hotplug_port &BXT_DE_PORT_HP_DDIB ) hotplug_ctrl |=BXT_DDIB_HPD_ENABLE ;if (hotplug_port &BXT_DE_PORT_HP_DDIC ) hotplug_ctrl |=BXT_DDIC_HPD_ENABLE ;I915_WRITE (BXT_HOTPLUG_CTL , hotplug_ctrl); -/* Unmask DDI hotplug in IMR */ hotplug_ctrl =I915_READ (GEN8_DE_PORT_IMR ) & ~hotplug_port;I915_WRITE (GEN8_DE_PORT_IMR , hotplug_ctrl); -/* Enable DDI hotplug in IER */ hotplug_ctrl =I915_READ (GEN8_DE_PORT_IER ) | hotplug_port;I915_WRITE (GEN8_DE_PORT_IER , hotplug_ctrl);POSTING_READ (GEN8_DE_PORT_IER );
Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH 3/3 drm/i915/bxt: WA for swapped HPD pins in A stepping
In reply to Sonika JindalWA for BXT A0/A1, where DDIB's HPD pin is swapped to DDIA, so enabling DDIA HPD pin in place of DDIB.
v2: For DP, irq_port is used to determine the encoder instead of hpd_pin and removing the edp HPD logic because port A HPD is not present(Imre)
v3: Rebased on top of Imre's patchset for enabling HPD on PORT A. Added hpd_pin swapping for intel_dp_init_connector, setting encoder for PORT_A as per the WA in irq_port (Imre)
v4: Dont enable interrupt for edp, also reframe the description (Siva)
v5: Don’t check for PORT_A in intel_ddi_init to update dig_port, instead avoid setting hpd_pin itself (Imre)
--- drivers/gpu/drm/i915/intel_ddi.c | 10 +++++++++- drivers/gpu/drm/i915/intel_dp.c | 2 ++ drivers/gpu/drm/i915/intel_hdmi.c | 9 ++++++++- 3 files changed, 19 insertions(+), 2 deletions(-)
drivers/gpu/drm/i915/intel_ddi.c +9 -1
@@ -3225,7 +3225,15 @@ void intel_ddi_init(struct drm_device *dev, enum port port) goto err; intel_dig_port->hpd_pulse = intel_dp_hpd_pulse; - dev_priv->hotplug.irq_port[port] = intel_dig_port; +/* +* On BXT A0/A1, sw needs to activate DDIA HPD logic and +* interrupts to check the external panel connection. +*/ +if (IS_BROXTON (dev_priv) && (INTEL_REVID (dev) <BXT_REVID_B0 ) + && port ==PORT_B ) + dev_priv->hotplug.irq_port[PORT_A ] = intel_dig_port; +else + dev_priv->hotplug.irq_port[port] = intel_dig_port; }/* In theory we don't need the encoder->type check, but leave it just in
drivers/gpu/drm/i915/intel_dp.c +2 -0
@@ -5788,6 +5788,8 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,break ;case PORT_B : intel_encoder->hpd_pin =HPD_PORT_B ; +if (IS_BROXTON (dev_priv) && (INTEL_REVID (dev) <BXT_REVID_B0 )) + intel_encoder->hpd_pin =HPD_PORT_A ;break ;case PORT_C : intel_encoder->hpd_pin =HPD_PORT_C ;
drivers/gpu/drm/i915/intel_hdmi.c +8 -1
@@ -1973,7 +1973,14 @@ void intel_hdmi_init_connector(struct intel_digital_port *intel_dig_port, intel_hdmi->ddc_bus =GMBUS_PIN_1_BXT ; else intel_hdmi->ddc_bus = GMBUS_PIN_DPB; - intel_encoder->hpd_pin =HPD_PORT_B ; +/* +* On BXT A0/A1, sw needs to activate DDIA HPD logic and +* interrupts to check the external panel connection. +*/ +if (IS_BROXTON (dev_priv) && (INTEL_REVID (dev) <BXT_REVID_B0 )) + intel_encoder->hpd_pin =HPD_PORT_A ; +else + intel_encoder->hpd_pin =HPD_PORT_B ;break ;case PORT_C :if (IS_BROXTON (dev_priv))
Signature · 6 lines
1.7.10.4 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 3/3] drm/i915/bxt: WA for swapped HPD pins in A stepping
Quoted 74 lines · Sonika Jindal
WA for BXT A0/A1, where DDIB's HPD pin is swapped to DDIA, so enabling DDIA HPD pin in place of DDIB.
v2: For DP,
irq_portis used to determine the encoder instead ofhpd_pinand removing the edp HPD logic because port A HPD is not present(Imre)
v3: Rebased on top of Imre's patchset for enabling HPD on PORT A. Addedhpd_pinswapping forintel_dp_init_connector, setting encoder forPORT_Aas per the WA inirq_port(Imre)
v4: Dont enable interrupt for edp, also reframe the description (Siva)
v5: Don’t check forPORT_Ainintel_ddi_initto updatedig_port, instead avoid settinghpd_pinitself (Imre)Signed-off-by Sonika Jindal <[email protected]>--- drivers/gpu/drm/i915/intel_ddi.c | 10 +++++++++- drivers/gpu/drm/i915/intel_dp.c | 2 ++ drivers/gpu/drm/i915/intel_hdmi.c | 9 ++++++++- 3 files changed, 19 insertions(+), 2 deletions(-)drivers/gpu/drm/i915/intel_ddi.c +9
-1@@ -3225,7 +3225,15 @@ void intel_ddi_init(struct drm_device *dev, enum port port) goto err; intel_dig_port->hpd_pulse = intel_dp_hpd_pulse; - dev_priv->hotplug.irq_port[port] = intel_dig_port; +/* +* On BXT A0/A1, sw needs to activate DDIA HPD logic and +* interrupts to check the external panel connection. +*/ +if (IS_BROXTON (dev_priv) && (INTEL_REVID (dev) <BXT_REVID_B0 ) + && port ==PORT_B ) + dev_priv->hotplug.irq_port[PORT_A ] = intel_dig_port; +else + dev_priv->hotplug.irq_port[port] = intel_dig_port; }/* In theory we don't need the encoder->type check, but leave it just in drivers/gpu/drm/i915/intel_dp.c +2
-0@@ -5788,6 +5788,8 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,break ;case PORT_B : intel_encoder->hpd_pin =HPD_PORT_B ; +if (IS_BROXTON (dev_priv) && (INTEL_REVID (dev) <BXT_REVID_B0 )) + intel_encoder->hpd_pin =HPD_PORT_A ;break ;case PORT_C : intel_encoder->hpd_pin =HPD_PORT_C ;drivers/gpu/drm/i915/intel_hdmi.c +8
-1@@ -1973,7 +1973,14 @@ void intel_hdmi_init_connector(struct intel_digital_port *intel_dig_port, intel_hdmi->ddc_bus =GMBUS_PIN_1_BXT ; else intel_hdmi->ddc_bus = GMBUS_PIN_DPB; - intel_encoder->hpd_pin =HPD_PORT_B ; +/* +* On BXT A0/A1, sw needs to activate DDIA HPD logic and +* interrupts to check the external panel connection. +*/ +if (IS_BROXTON (dev_priv) && (INTEL_REVID (dev) <BXT_REVID_B0 )) + intel_encoder->hpd_pin =HPD_PORT_A ; +else + intel_encoder->hpd_pin =HPD_PORT_B ;break ;case PORT_C :if (IS_BROXTON (dev_priv))
Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 3/3] drm/i915/bxt: WA for swapped HPD pins in A stepping
Quoted 17 lines · Sivakumar Thulasimani
Reviewed-by Sivakumar Thulasimani <[email protected]>Quoted 14 lines · Sonika Jindal
WA for BXT A0/A1, where DDIB's HPD pin is swapped to DDIA, so enabling DDIA HPD pin in place of DDIB.
v2: For DP,
irq_portis used to determine the encoder instead ofhpd_pinand removing the edp HPD logic because port A HPD is not present(Imre)
v3: Rebased on top of Imre's patchset for enabling HPD on PORT A. Addedhpd_pinswapping forintel_dp_init_connector, setting encoder forPORT_Aas per the WA inirq_port(Imre)
v4: Dont enable interrupt for edp, also reframe the description (Siva)
v5: Don’t check forPORT_Ainintel_ddi_initto updatedig_port, instead avoid settinghpd_pinitself (Imre)Signed-off-by Sonika Jindal <[email protected]>
Merged patches 2&3 from this series, thanks.
-Daniel
Quoted 67 lines
Quoted 58 lines
--- drivers/gpu/drm/i915/intel_ddi.c | 10 +++++++++- drivers/gpu/drm/i915/intel_dp.c | 2 ++ drivers/gpu/drm/i915/intel_hdmi.c | 9 ++++++++- 3 files changed, 19 insertions(+), 2 deletions(-)drivers/gpu/drm/i915/intel_ddi.c +9
-1@@ -3225,7 +3225,15 @@ void intel_ddi_init(struct drm_device *dev, enum port port) goto err; intel_dig_port->hpd_pulse = intel_dp_hpd_pulse; - dev_priv->hotplug.irq_port[port] = intel_dig_port; +/* +* On BXT A0/A1, sw needs to activate DDIA HPD logic and +* interrupts to check the external panel connection. +*/ +if (IS_BROXTON (dev_priv) && (INTEL_REVID (dev) <BXT_REVID_B0 ) + && port ==PORT_B ) + dev_priv->hotplug.irq_port[PORT_A ] = intel_dig_port; +else + dev_priv->hotplug.irq_port[port] = intel_dig_port; }/* In theory we don't need the encoder->type check, but leave it just in drivers/gpu/drm/i915/intel_dp.c +2
-0@@ -5788,6 +5788,8 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,break ;case PORT_B : intel_encoder->hpd_pin =HPD_PORT_B ; +if (IS_BROXTON (dev_priv) && (INTEL_REVID (dev) <BXT_REVID_B0 )) + intel_encoder->hpd_pin =HPD_PORT_A ;break ;case PORT_C : intel_encoder->hpd_pin =HPD_PORT_C ;drivers/gpu/drm/i915/intel_hdmi.c +8
-1@@ -1973,7 +1973,14 @@ void intel_hdmi_init_connector(struct intel_digital_port *intel_dig_port, intel_hdmi->ddc_bus =GMBUS_PIN_1_BXT ; else intel_hdmi->ddc_bus = GMBUS_PIN_DPB; - intel_encoder->hpd_pin =HPD_PORT_B ; +/* +* On BXT A0/A1, sw needs to activate DDIA HPD logic and +* interrupts to check the external panel connection. +*/ +if (IS_BROXTON (dev_priv) && (INTEL_REVID (dev) <BXT_REVID_B0 )) + intel_encoder->hpd_pin =HPD_PORT_A ; +else + intel_encoder->hpd_pin =HPD_PORT_B ;break ;case PORT_C :if (IS_BROXTON (dev_priv))Signature · 7 lines
regards, Sivakumar _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Signature · 7 lines
Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: [PATCH 3/3] drm/i915/bxt: WA for swapped HPD pins in A stepping
In reply to Sonika JindalTask id: 7125 -------------------------------------Summary-------------------------------------
Platform Delta drm-intel-nightly Series Applied
ILK -1 302/302 301/302
SNB 315/315 315/315 IVB 336/336 336/336 BYT 283/283 283/283 HSW 378/378 378/378
-------------------------------------Detailed-------------------------------------
Platform Test drm-intel-nightly Series Applied
*ILK igt@kms_flip@flip-vs-dpms-interruptible PASS(1) DMESG_WARN(1)
Note: You need to pay more attention to line start with '*'
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx