drm/i915/tgl: Enable DDI/Port G
authorKhaled Almahallawy <khaled.almahallawy@intel.com>
Tue, 8 Oct 2019 22:09:05 +0000 (15:09 -0700)
committerLucas De Marchi <lucas.demarchi@intel.com>
Wed, 16 Oct 2019 23:53:27 +0000 (16:53 -0700)
In TGL there we are missing the initialization of port G.
Do the same as for other ports.

Signed-off-by: Khaled Almahallawy <khaled.almahallawy@intel.com>
Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com>
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20191008220905.18278-1-khaled.almahallawy@intel.com
drivers/gpu/drm/i915/display/intel_bios.c
drivers/gpu/drm/i915/display/intel_display.c
drivers/gpu/drm/i915/display/intel_display.h
drivers/gpu/drm/i915/display/intel_dp.c
drivers/gpu/drm/i915/display/intel_vbt_defs.h

index f0307b04cc1308ecc0c97a4b6a603e49d355d2ee..63c1bd4c2954e5a169b4af1bb5efbffc52e30acb 100644 (file)
@@ -1399,6 +1399,7 @@ static enum port dvo_port_to_port(u8 dvo_port)
                [PORT_D] = { DVO_PORT_HDMID, DVO_PORT_DPD, -1},
                [PORT_E] = { DVO_PORT_CRT, DVO_PORT_HDMIE, DVO_PORT_DPE},
                [PORT_F] = { DVO_PORT_HDMIF, DVO_PORT_DPF, -1},
+               [PORT_G] = { DVO_PORT_HDMIG, DVO_PORT_DPG, -1},
        };
        enum port port;
        int i;
@@ -2258,6 +2259,9 @@ enum aux_ch intel_bios_port_aux_ch(struct drm_i915_private *dev_priv,
        case DP_AUX_F:
                aux_ch = AUX_CH_F;
                break;
+       case DP_AUX_G:
+               aux_ch = AUX_CH_G;
+               break;
        default:
                MISSING_CASE(info->alternate_aux_channel);
                aux_ch = AUX_CH_A;
index 2309b349f4b53fa281eab0e32787e92b8235c00c..164ded862148b83dda0e778b0ebdbd822ee632eb 100644 (file)
@@ -6689,6 +6689,8 @@ enum intel_display_power_domain intel_port_to_power_domain(enum port port)
                return POWER_DOMAIN_PORT_DDI_E_LANES;
        case PORT_F:
                return POWER_DOMAIN_PORT_DDI_F_LANES;
+       case PORT_G:
+               return POWER_DOMAIN_PORT_DDI_G_LANES;
        default:
                MISSING_CASE(port);
                return POWER_DOMAIN_PORT_OTHER;
@@ -6712,6 +6714,8 @@ intel_aux_power_domain(struct intel_digital_port *dig_port)
                        return POWER_DOMAIN_AUX_E_TBT;
                case AUX_CH_F:
                        return POWER_DOMAIN_AUX_F_TBT;
+               case AUX_CH_G:
+                       return POWER_DOMAIN_AUX_G_TBT;
                default:
                        MISSING_CASE(dig_port->aux_ch);
                        return POWER_DOMAIN_AUX_C_TBT;
@@ -6731,6 +6735,8 @@ intel_aux_power_domain(struct intel_digital_port *dig_port)
                return POWER_DOMAIN_AUX_E;
        case AUX_CH_F:
                return POWER_DOMAIN_AUX_F;
+       case AUX_CH_G:
+               return POWER_DOMAIN_AUX_G;
        default:
                MISSING_CASE(dig_port->aux_ch);
                return POWER_DOMAIN_AUX_A;
index bed203ec1df8da05cf98457c176ea0eb2b90b2d4..90807603987c4a6c6096a9322c33b86609e80d20 100644 (file)
@@ -271,6 +271,7 @@ enum aux_ch {
        AUX_CH_D,
        AUX_CH_E, /* ICL+ */
        AUX_CH_F,
+       AUX_CH_G,
 };
 
 #define aux_ch_name(a) ((a) + 'A')
index dd5dc1e38495d82963c8d154e350d1fe7abd264b..c4c081c79dd967ccddc411e60a13b2b9297ce8a9 100644 (file)
@@ -1644,6 +1644,7 @@ static i915_reg_t skl_aux_ctl_reg(struct intel_dp *intel_dp)
        case AUX_CH_D:
        case AUX_CH_E:
        case AUX_CH_F:
+       case AUX_CH_G:
                return DP_AUX_CH_CTL(aux_ch);
        default:
                MISSING_CASE(aux_ch);
@@ -1664,6 +1665,7 @@ static i915_reg_t skl_aux_data_reg(struct intel_dp *intel_dp, int index)
        case AUX_CH_D:
        case AUX_CH_E:
        case AUX_CH_F:
+       case AUX_CH_G:
                return DP_AUX_CH_DATA(aux_ch, index);
        default:
                MISSING_CASE(aux_ch);
index dfcd156b50949715731945da3d71ab554d85f70e..e3045ced4bfe9887ad6fb9932171cecf020f9e8e 100644 (file)
@@ -291,6 +291,8 @@ struct bdb_general_features {
 #define DVO_PORT_HDMIE         12                              /* 193 */
 #define DVO_PORT_DPF           13                              /* N/A */
 #define DVO_PORT_HDMIF         14                              /* N/A */
+#define DVO_PORT_DPG           15
+#define DVO_PORT_HDMIG         16
 #define DVO_PORT_MIPIA         21                              /* 171 */
 #define DVO_PORT_MIPIB         22                              /* 171 */
 #define DVO_PORT_MIPIC         23                              /* 171 */
@@ -325,6 +327,7 @@ enum vbt_gmbus_ddi {
 #define DP_AUX_D 0x30
 #define DP_AUX_E 0x50
 #define DP_AUX_F 0x60
+#define DP_AUX_G 0x70
 
 #define VBT_DP_MAX_LINK_RATE_HBR3      0
 #define VBT_DP_MAX_LINK_RATE_HBR2      1