diff mbox

drm/i915: (VLV2) Fix the hotplug detection bits

Message ID 1390322330-6486-1-git-send-email-tprevite@gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Todd Previte Jan. 21, 2014, 4:38 p.m. UTC
These bits are in reverse order in the header from those defined in
the specification. Change the bit positions for ports B and D to
correctly match the spec.
---
 drivers/gpu/drm/i915/i915_reg.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Jani Nikula Jan. 21, 2014, 5:14 p.m. UTC | #1
On Tue, 21 Jan 2014, Todd Previte <tprevite@gmail.com> wrote:
> These bits are in reverse order in the header from those defined in
> the specification. Change the bit positions for ports B and D to
> correctly match the spec.

Your signed-off-by is missing. The git commit -s option will add it for
you.

> ---
>  drivers/gpu/drm/i915/i915_reg.h | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
> index 10ecf90..2d77b51 100644
> --- a/drivers/gpu/drm/i915/i915_reg.h
> +++ b/drivers/gpu/drm/i915/i915_reg.h
> @@ -2083,9 +2083,9 @@
>   * Please check the detailed lore in the commit message for for experimental
>   * evidence.
>   */

Please read the comment above, and check out

commit 0ce99f749b3834edeb500e17d6ad17e86b60ff83
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Fri Jul 26 11:27:49 2013 +0200

    drm/i915: fix gen4 digital port hotplug definitions

Since the definitions are used for both pre-PCH and VLV in
g4x_dp_detect() we should try to figure out whether the bits are really
different between them or not. Or if the VLV specs are confused too.

Meanwhile, I'll go pat myself on the back for seeing this patch coming,
and asking for Daniel to add that comment...

BR,
Jani.


> -#define   PORTD_HOTPLUG_LIVE_STATUS               (1 << 29)
> +#define   PORTD_HOTPLUG_LIVE_STATUS               (1 << 27)
>  #define   PORTC_HOTPLUG_LIVE_STATUS               (1 << 28)
> -#define   PORTB_HOTPLUG_LIVE_STATUS               (1 << 27)
> +#define   PORTB_HOTPLUG_LIVE_STATUS               (1 << 29)
>  #define   PORTD_HOTPLUG_INT_STATUS		(3 << 21)
>  #define   PORTC_HOTPLUG_INT_STATUS		(3 << 19)
>  #define   PORTB_HOTPLUG_INT_STATUS		(3 << 17)
> -- 
> 1.8.3.2
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Todd Previte Jan. 23, 2014, 4:22 a.m. UTC | #2
Addresses the comments and feedback herein. VLV2 and gen4 have separate bit
definitions now. The correct bits are selected in gen4x_dp_detect() based on
the detected platform.
Todd Previte Jan. 23, 2014, 7:13 a.m. UTC | #3
Fixed the trailing brace for the switch() statement in gen4x_dp_detect()
diff mbox

Patch

diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
index 10ecf90..2d77b51 100644
--- a/drivers/gpu/drm/i915/i915_reg.h
+++ b/drivers/gpu/drm/i915/i915_reg.h
@@ -2083,9 +2083,9 @@ 
  * Please check the detailed lore in the commit message for for experimental
  * evidence.
  */
-#define   PORTD_HOTPLUG_LIVE_STATUS               (1 << 29)
+#define   PORTD_HOTPLUG_LIVE_STATUS               (1 << 27)
 #define   PORTC_HOTPLUG_LIVE_STATUS               (1 << 28)
-#define   PORTB_HOTPLUG_LIVE_STATUS               (1 << 27)
+#define   PORTB_HOTPLUG_LIVE_STATUS               (1 << 29)
 #define   PORTD_HOTPLUG_INT_STATUS		(3 << 21)
 #define   PORTC_HOTPLUG_INT_STATUS		(3 << 19)
 #define   PORTB_HOTPLUG_INT_STATUS		(3 << 17)