]> Git Repo - J-linux.git/commitdiff
Merge drm/drm-next into drm-intel-next
authorRodrigo Vivi <[email protected]>
Mon, 17 May 2021 21:48:02 +0000 (17:48 -0400)
committerRodrigo Vivi <[email protected]>
Mon, 17 May 2021 21:48:02 +0000 (17:48 -0400)
Time to get back in sync...

Signed-off-by: Rodrigo Vivi <[email protected]>
1  2 
drivers/gpu/drm/i915/display/intel_dp.c
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/intel_pm.c
include/drm/drm_dp_helper.h

index 5694bc716ade9163fb91170f5c7c7379a3ae4460,6a2dee8cef1f16d530f9d6b3809385df91deda65..5c9222283044a89c37e949b6a90aca151dfe718e
  #include "intel_audio.h"
  #include "intel_connector.h"
  #include "intel_ddi.h"
 +#include "intel_de.h"
  #include "intel_display_types.h"
  #include "intel_dp.h"
  #include "intel_dp_aux.h"
 +#include "intel_dp_hdcp.h"
  #include "intel_dp_link_training.h"
  #include "intel_dp_mst.h"
 -#include "intel_dpll.h"
  #include "intel_dpio_phy.h"
 +#include "intel_dpll.h"
  #include "intel_fifo_underrun.h"
  #include "intel_hdcp.h"
  #include "intel_hdmi.h"
@@@ -109,7 -107,6 +109,7 @@@ bool intel_dp_is_edp(struct intel_dp *i
  }
  
  static void intel_dp_unset_edid(struct intel_dp *intel_dp);
 +static int intel_dp_dsc_compute_bpp(struct intel_dp *intel_dp, u8 dsc_max_bpc);
  
  /* update sink rates from dpcd */
  static void intel_dp_set_sink_rates(struct intel_dp *intel_dp)
@@@ -218,7 -215,7 +218,7 @@@ bool intel_dp_can_bigjoiner(struct inte
        struct drm_i915_private *dev_priv = to_i915(encoder->base.dev);
  
        return DISPLAY_VER(dev_priv) >= 12 ||
 -              (IS_DISPLAY_VER(dev_priv, 11) &&
 +              (DISPLAY_VER(dev_priv) == 11 &&
                 encoder->port != PORT_A);
  }
  
@@@ -298,16 -295,16 +298,16 @@@ intel_dp_set_source_rates(struct intel_
        if (DISPLAY_VER(dev_priv) >= 11 || IS_CANNONLAKE(dev_priv)) {
                source_rates = cnl_rates;
                size = ARRAY_SIZE(cnl_rates);
 -              if (IS_DISPLAY_VER(dev_priv, 10))
 +              if (DISPLAY_VER(dev_priv) == 10)
                        max_rate = cnl_max_source_rate(intel_dp);
                else if (IS_JSL_EHL(dev_priv))
                        max_rate = ehl_max_source_rate(intel_dp);
                else
                        max_rate = icl_max_source_rate(intel_dp);
 -      } else if (IS_GEN9_LP(dev_priv)) {
 +      } else if (IS_GEMINILAKE(dev_priv) || IS_BROXTON(dev_priv)) {
                source_rates = bxt_rates;
                size = ARRAY_SIZE(bxt_rates);
 -      } else if (IS_GEN9_BC(dev_priv)) {
 +      } else if (DISPLAY_VER(dev_priv) == 9) {
                source_rates = skl_rates;
                size = ARRAY_SIZE(skl_rates);
        } else if ((IS_HASWELL(dev_priv) && !IS_HSW_ULX(dev_priv)) ||
@@@ -495,8 -492,7 +495,8 @@@ small_joiner_ram_size_bits(struct drm_i
  static u16 intel_dp_dsc_get_output_bpp(struct drm_i915_private *i915,
                                       u32 link_clock, u32 lane_count,
                                       u32 mode_clock, u32 mode_hdisplay,
 -                                     bool bigjoiner)
 +                                     bool bigjoiner,
 +                                     u32 pipe_bpp)
  {
        u32 bits_per_pixel, max_bpp_small_joiner_ram;
        int i;
                return 0;
        }
  
 -      /* Find the nearest match in the array of known BPPs from VESA */
 -      for (i = 0; i < ARRAY_SIZE(valid_dsc_bpp) - 1; i++) {
 -              if (bits_per_pixel < valid_dsc_bpp[i + 1])
 -                      break;
 +      /* From XE_LPD onwards we support from bpc upto uncompressed bpp-1 BPPs */
 +      if (DISPLAY_VER(i915) >= 13) {
 +              bits_per_pixel = min(bits_per_pixel, pipe_bpp - 1);
 +      } else {
 +              /* Find the nearest match in the array of known BPPs from VESA */
 +              for (i = 0; i < ARRAY_SIZE(valid_dsc_bpp) - 1; i++) {
 +                      if (bits_per_pixel < valid_dsc_bpp[i + 1])
 +                              break;
 +              }
 +              bits_per_pixel = valid_dsc_bpp[i];
        }
 -      bits_per_pixel = valid_dsc_bpp[i];
  
        /*
         * Compressed BPP in U6.4 format so multiply by 16, for Gen 11,
@@@ -787,12 -778,6 +787,12 @@@ intel_dp_mode_valid(struct drm_connecto
         */
        if (DISPLAY_VER(dev_priv) >= 10 &&
            drm_dp_sink_supports_dsc(intel_dp->dsc_dpcd)) {
 +              /*
 +               * TBD pass the connector BPC,
 +               * for now U8_MAX so that max BPC on that platform would be picked
 +               */
 +              int pipe_bpp = intel_dp_dsc_compute_bpp(intel_dp, U8_MAX);
 +
                if (intel_dp_is_edp(intel_dp)) {
                        dsc_max_output_bpp =
                                drm_edp_dsc_sink_output_bpp(intel_dp->dsc_dpcd) >> 4;
                                                            max_lanes,
                                                            target_clock,
                                                            mode->hdisplay,
 -                                                          bigjoiner) >> 4;
 +                                                          bigjoiner,
 +                                                          pipe_bpp) >> 4;
                        dsc_slice_count =
                                intel_dp_dsc_get_slice_count(intel_dp,
                                                             target_clock,
                dsc = dsc_max_output_bpp && dsc_slice_count;
        }
  
 -      /* big joiner configuration needs DSC */
 -      if (bigjoiner && !dsc)
 +      /*
 +       * Big joiner configuration needs DSC for TGL which is not true for
 +       * XE_LPD where uncompressed joiner is supported.
 +       */
 +      if (DISPLAY_VER(dev_priv) < 13 && bigjoiner && !dsc)
                return MODE_CLOCK_HIGH;
  
        if (mode_rate > max_rate && !dsc)
@@@ -935,7 -916,7 +935,7 @@@ static bool intel_dp_source_supports_fe
        if (DISPLAY_VER(dev_priv) >= 12)
                return true;
  
 -      if (IS_DISPLAY_VER(dev_priv, 11) && pipe_config->cpu_transcoder != TRANSCODER_A)
 +      if (DISPLAY_VER(dev_priv) == 11 && pipe_config->cpu_transcoder != TRANSCODER_A)
                return true;
  
        return false;
@@@ -1114,18 -1095,48 +1114,18 @@@ intel_dp_compute_link_config_wide(struc
        return -EINVAL;
  }
  
 -/* Optimize link config in order: max bpp, min lanes, min clock */
 -static int
 -intel_dp_compute_link_config_fast(struct intel_dp *intel_dp,
 -                                struct intel_crtc_state *pipe_config,
 -                                const struct link_config_limits *limits)
 -{
 -      const struct drm_display_mode *adjusted_mode = &pipe_config->hw.adjusted_mode;
 -      int bpp, clock, lane_count;
 -      int mode_rate, link_clock, link_avail;
 -
 -      for (bpp = limits->max_bpp; bpp >= limits->min_bpp; bpp -= 2 * 3) {
 -              int output_bpp = intel_dp_output_bpp(pipe_config->output_format, bpp);
 -
 -              mode_rate = intel_dp_link_required(adjusted_mode->crtc_clock,
 -                                                 output_bpp);
 -
 -              for (lane_count = limits->min_lane_count;
 -                   lane_count <= limits->max_lane_count;
 -                   lane_count <<= 1) {
 -                      for (clock = limits->min_clock; clock <= limits->max_clock; clock++) {
 -                              link_clock = intel_dp->common_rates[clock];
 -                              link_avail = intel_dp_max_data_rate(link_clock,
 -                                                                  lane_count);
 -
 -                              if (mode_rate <= link_avail) {
 -                                      pipe_config->lane_count = lane_count;
 -                                      pipe_config->pipe_bpp = bpp;
 -                                      pipe_config->port_clock = link_clock;
 -
 -                                      return 0;
 -                              }
 -                      }
 -              }
 -      }
 -
 -      return -EINVAL;
 -}
 -
 -static int intel_dp_dsc_compute_bpp(struct intel_dp *intel_dp, u8 dsc_max_bpc)
 +static int intel_dp_dsc_compute_bpp(struct intel_dp *intel_dp, u8 max_req_bpc)
  {
 +      struct drm_i915_private *i915 = dp_to_i915(intel_dp);
        int i, num_bpc;
        u8 dsc_bpc[3] = {0};
 +      u8 dsc_max_bpc;
 +
 +      /* Max DSC Input BPC for ICL is 10 and for TGL+ is 12 */
 +      if (DISPLAY_VER(i915) >= 12)
 +              dsc_max_bpc = min_t(u8, 12, max_req_bpc);
 +      else
 +              dsc_max_bpc = min_t(u8, 10, max_req_bpc);
  
        num_bpc = drm_dp_dsc_sink_supported_input_bpcs(intel_dp->dsc_dpcd,
                                                       dsc_bpc);
@@@ -1156,6 -1167,10 +1156,6 @@@ static int intel_dp_dsc_compute_params(
         */
        vdsc_cfg->rc_model_size = DSC_RC_MODEL_SIZE_CONST;
  
 -      ret = intel_dsc_compute_params(encoder, crtc_state);
 -      if (ret)
 -              return ret;
 -
        /*
         * Slice Height of 8 works for all currently available panels. So start
         * with that if pic_height is an integral multiple of 8. Eventually add
        else
                vdsc_cfg->slice_height = 2;
  
 +      ret = intel_dsc_compute_params(encoder, crtc_state);
 +      if (ret)
 +              return ret;
 +
        vdsc_cfg->dsc_version_major =
                (intel_dp->dsc_dpcd[DP_DSC_REV - DP_DSC_SUPPORT] &
                 DP_DSC_MAJOR_MASK) >> DP_DSC_MAJOR_SHIFT;
@@@ -1213,6 -1224,7 +1213,6 @@@ static int intel_dp_dsc_compute_config(
        struct drm_i915_private *dev_priv = to_i915(dig_port->base.base.dev);
        const struct drm_display_mode *adjusted_mode =
                &pipe_config->hw.adjusted_mode;
 -      u8 dsc_max_bpc;
        int pipe_bpp;
        int ret;
  
        if (!intel_dp_supports_dsc(intel_dp, pipe_config))
                return -EINVAL;
  
 -      /* Max DSC Input BPC for ICL is 10 and for TGL+ is 12 */
 -      if (DISPLAY_VER(dev_priv) >= 12)
 -              dsc_max_bpc = min_t(u8, 12, conn_state->max_requested_bpc);
 -      else
 -              dsc_max_bpc = min_t(u8, 10,
 -                                  conn_state->max_requested_bpc);
 -
 -      pipe_bpp = intel_dp_dsc_compute_bpp(intel_dp, dsc_max_bpc);
 +      pipe_bpp = intel_dp_dsc_compute_bpp(intel_dp, conn_state->max_requested_bpc);
  
        /* Min Input BPC for ICL+ is 8 */
        if (pipe_bpp < 8 * 3) {
                                                    pipe_config->lane_count,
                                                    adjusted_mode->crtc_clock,
                                                    adjusted_mode->crtc_hdisplay,
 -                                                  pipe_config->bigjoiner);
 +                                                  pipe_config->bigjoiner,
 +                                                  pipe_bpp);
                dsc_dp_slice_count =
                        intel_dp_dsc_get_slice_count(intel_dp,
                                                     adjusted_mode->crtc_clock,
@@@ -1364,19 -1382,26 +1364,19 @@@ intel_dp_compute_link_config(struct int
            intel_dp_can_bigjoiner(intel_dp))
                pipe_config->bigjoiner = true;
  
 -      if (intel_dp_is_edp(intel_dp))
 -              /*
 -               * Optimize for fast and narrow. eDP 1.3 section 3.3 and eDP 1.4
 -               * section A.1: "It is recommended that the minimum number of
 -               * lanes be used, using the minimum link rate allowed for that
 -               * lane configuration."
 -               *
 -               * Note that we fall back to the max clock and lane count for eDP
 -               * panels that fail with the fast optimal settings (see
 -               * intel_dp->use_max_params), in which case the fast vs. wide
 -               * choice doesn't matter.
 -               */
 -              ret = intel_dp_compute_link_config_fast(intel_dp, pipe_config, &limits);
 -      else
 -              /* Optimize for slow and wide. */
 -              ret = intel_dp_compute_link_config_wide(intel_dp, pipe_config, &limits);
 +      /*
 +       * Optimize for slow and wide for everything, because there are some
 +       * eDP 1.3 and 1.4 panels don't work well with fast and narrow.
 +       */
 +      ret = intel_dp_compute_link_config_wide(intel_dp, pipe_config, &limits);
  
 -      /* enable compression if the mode doesn't fit available BW */
 +      /*
 +       * Pipe joiner needs compression upto display12 due to BW limitation. DG2
 +       * onwards pipe joiner can be enabled without compression.
 +       */
        drm_dbg_kms(&i915->drm, "Force DSC en = %d\n", intel_dp->force_dsc_en);
 -      if (ret || intel_dp->force_dsc_en || pipe_config->bigjoiner) {
 +      if (ret || intel_dp->force_dsc_en || (DISPLAY_VER(i915) < 13 &&
 +                                            pipe_config->bigjoiner)) {
                ret = intel_dp_dsc_compute_config(intel_dp, pipe_config,
                                                  conn_state, &limits);
                if (ret < 0)
@@@ -1836,7 -1861,7 +1836,7 @@@ void intel_dp_sink_set_decompression_st
        if (ret < 0)
                drm_dbg_kms(&i915->drm,
                            "Failed to %s sink decompression state\n",
 -                          enable ? "enable" : "disable");
 +                          enabledisable(enable));
  }
  
  static void
@@@ -2135,7 -2160,7 +2135,7 @@@ void intel_dp_check_frl_training(struc
         * -PCON supports SRC_CTL_MODE (VESA DP2.0-HDMI2.1 PCON Spec Draft-1 Sec-7)
         * -sink is HDMI2.1
         */
 -      if (!(intel_dp->dpcd[2] & DP_PCON_SOURCE_CTL_MODE) ||
 +      if (!(intel_dp->downstream_ports[2] & DP_PCON_SOURCE_CTL_MODE) ||
            !intel_dp_is_hdmi_2_1_sink(intel_dp) ||
            intel_dp->frl.is_trained)
                return;
@@@ -2268,8 -2293,8 +2268,8 @@@ void intel_dp_configure_protocol_conver
  
        if (drm_dp_dpcd_writeb(&intel_dp->aux,
                               DP_PROTOCOL_CONVERTER_CONTROL_0, tmp) != 1)
 -              drm_dbg_kms(&i915->drm, "Failed to set protocol converter HDMI mode to %s\n",
 -                          enableddisabled(intel_dp->has_hdmi_sink));
 +              drm_dbg_kms(&i915->drm, "Failed to %s protocol converter HDMI mode\n",
 +                          enabledisable(intel_dp->has_hdmi_sink));
  
        tmp = crtc_state->output_format == INTEL_OUTPUT_FORMAT_YCBCR444 &&
                intel_dp->dfp.ycbcr_444_to_420 ? DP_CONVERSION_TO_YCBCR420_ENABLE : 0;
        if (drm_dp_dpcd_writeb(&intel_dp->aux,
                               DP_PROTOCOL_CONVERTER_CONTROL_1, tmp) != 1)
                drm_dbg_kms(&i915->drm,
 -                          "Failed to set protocol converter YCbCr 4:2:0 conversion mode to %s\n",
 -                          enableddisabled(intel_dp->dfp.ycbcr_444_to_420));
 +                          "Failed to %s protocol converter YCbCr 4:2:0 conversion mode\n",
 +                          enabledisable(intel_dp->dfp.ycbcr_444_to_420));
  
        tmp = 0;
        if (intel_dp->dfp.rgb_to_ycbcr) {
  
        if (drm_dp_pcon_convert_rgb_to_ycbcr(&intel_dp->aux, tmp) < 0)
                drm_dbg_kms(&i915->drm,
 -                         "Failed to set protocol converter RGB->YCbCr conversion mode to %s\n",
 -                         enableddisabled(tmp ? true : false));
 +                         "Failed to %s protocol converter RGB->YCbCr conversion mode\n",
 +                         enabledisable(tmp));
  }
  
  
@@@ -2836,25 -2861,31 +2836,25 @@@ void intel_dp_set_infoframes(struct int
                             const struct drm_connector_state *conn_state)
  {
        struct drm_i915_private *dev_priv = to_i915(encoder->base.dev);
 -      struct intel_dp *intel_dp = enc_to_intel_dp(encoder);
        i915_reg_t reg = HSW_TVIDEO_DIP_CTL(crtc_state->cpu_transcoder);
        u32 dip_enable = VIDEO_DIP_ENABLE_AVI_HSW | VIDEO_DIP_ENABLE_GCP_HSW |
                         VIDEO_DIP_ENABLE_VS_HSW | VIDEO_DIP_ENABLE_GMP_HSW |
                         VIDEO_DIP_ENABLE_SPD_HSW | VIDEO_DIP_ENABLE_DRM_GLK;
 -      u32 val = intel_de_read(dev_priv, reg);
 +      u32 val = intel_de_read(dev_priv, reg) & ~dip_enable;
  
        /* TODO: Add DSC case (DIP_ENABLE_PPS) */
        /* When PSR is enabled, this routine doesn't disable VSC DIP */
 -      if (intel_psr_enabled(intel_dp))
 -              val &= ~dip_enable;
 -      else
 -              val &= ~(dip_enable | VIDEO_DIP_ENABLE_VSC_HSW);
 -
 -      if (!enable) {
 -              intel_de_write(dev_priv, reg, val);
 -              intel_de_posting_read(dev_priv, reg);
 -              return;
 -      }
 +      if (!crtc_state->has_psr)
 +              val &= ~VIDEO_DIP_ENABLE_VSC_HSW;
  
        intel_de_write(dev_priv, reg, val);
        intel_de_posting_read(dev_priv, reg);
  
 +      if (!enable)
 +              return;
 +
        /* When PSR is enabled, VSC SDP is handled by PSR routine */
 -      if (!intel_psr_enabled(intel_dp))
 +      if (!crtc_state->has_psr)
                intel_write_dp_sdp(encoder, crtc_state, DP_SDP_VSC);
  
        intel_write_dp_sdp(encoder, crtc_state, HDMI_PACKET_TYPE_GAMUT_METADATA);
@@@ -2981,13 -3012,14 +2981,13 @@@ static void intel_read_dp_vsc_sdp(struc
                                  struct drm_dp_vsc_sdp *vsc)
  {
        struct intel_digital_port *dig_port = enc_to_dig_port(encoder);
 -      struct intel_dp *intel_dp = enc_to_intel_dp(encoder);
        struct drm_i915_private *dev_priv = to_i915(encoder->base.dev);
        unsigned int type = DP_SDP_VSC;
        struct dp_sdp sdp = {};
        int ret;
  
        /* When PSR is enabled, VSC SDP is handled by PSR routine */
 -      if (intel_psr_enabled(intel_dp))
 +      if (crtc_state->has_psr)
                return;
  
        if ((crtc_state->infoframes.enable &
@@@ -3442,7 -3474,18 +3442,18 @@@ intel_dp_check_mst_status(struct intel_
        drm_WARN_ON_ONCE(&i915->drm, intel_dp->active_mst_links < 0);
  
        for (;;) {
-               u8 esi[DP_DPRX_ESI_LEN] = {};
+               /*
+                * The +2 is because DP_DPRX_ESI_LEN is 14, but we then
+                * pass in "esi+10" to drm_dp_channel_eq_ok(), which
+                * takes a 6-byte array. So we actually need 16 bytes
+                * here.
+                *
+                * Somebody who knows what the limits actually are
+                * should check this, but for now this is at least
+                * harmless and avoids a valid compiler warning about
+                * using more of the array than we have allocated.
+                */
+               u8 esi[DP_DPRX_ESI_LEN+2] = {};
                bool handled;
                int retry;
  
@@@ -5365,7 -5408,7 +5376,7 @@@ intel_dp_init_connector(struct intel_di
        intel_dp_add_properties(intel_dp, connector);
  
        if (is_hdcp_supported(dev_priv, port) && !intel_dp_is_edp(intel_dp)) {
 -              int ret = intel_dp_init_hdcp(dig_port, intel_connector);
 +              int ret = intel_dp_hdcp_init(dig_port, intel_connector);
                if (ret)
                        drm_dbg_kms(&dev_priv->drm,
                                    "HDCP init failed, skipping.\n");
@@@ -5398,9 -5441,6 +5409,9 @@@ void intel_dp_mst_suspend(struct drm_i9
  {
        struct intel_encoder *encoder;
  
 +      if (!HAS_DISPLAY(dev_priv))
 +              return;
 +
        for_each_intel_encoder(&dev_priv->drm, encoder) {
                struct intel_dp *intel_dp;
  
@@@ -5421,9 -5461,6 +5432,9 @@@ void intel_dp_mst_resume(struct drm_i91
  {
        struct intel_encoder *encoder;
  
 +      if (!HAS_DISPLAY(dev_priv))
 +              return;
 +
        for_each_intel_encoder(&dev_priv->drm, encoder) {
                struct intel_dp *intel_dp;
                int ret;
index bca76184508adee1fd80012d21d266117d893f57,9ec9277539ec14e8e5cd5629b3e5909be600e8a7..374372773b48be78bf5d01e5e14b50683bf3ddf9
@@@ -1234,37 -1234,29 +1234,37 @@@ static inline struct drm_i915_private *
  #define RUNTIME_INFO(dev_priv)        (&(dev_priv)->__runtime)
  #define DRIVER_CAPS(dev_priv) (&(dev_priv)->caps)
  
 -#define INTEL_GEN(dev_priv)   (INTEL_INFO(dev_priv)->gen)
  #define INTEL_DEVID(dev_priv) (RUNTIME_INFO(dev_priv)->device_id)
  
 -#define DISPLAY_VER(i915)     (INTEL_INFO(i915)->display.version)
 -#define IS_DISPLAY_RANGE(i915, from, until) \
 -      (DISPLAY_VER(i915) >= (from) && DISPLAY_VER(i915) <= (until))
 -#define IS_DISPLAY_VER(i915, v) (DISPLAY_VER(i915) == (v))
 +/*
 + * Deprecated: this will be replaced by individual IP checks:
 + * GRAPHICS_VER(), MEDIA_VER() and DISPLAY_VER()
 + */
 +#define INTEL_GEN(dev_priv)           GRAPHICS_VER(dev_priv)
 +/*
 + * Deprecated: use IS_GRAPHICS_VER(), IS_MEDIA_VER() and IS_DISPLAY_VER() as
 + * appropriate.
 + */
 +#define IS_GEN_RANGE(dev_priv, s, e)  IS_GRAPHICS_VER(dev_priv, (s), (e))
 +/*
 + * Deprecated: use GRAPHICS_VER(), MEDIA_VER() and DISPLAY_VER() as appropriate.
 + */
 +#define IS_GEN(dev_priv, n)           (GRAPHICS_VER(dev_priv) == (n))
  
 -#define REVID_FOREVER         0xff
 -#define INTEL_REVID(dev_priv) (to_pci_dev((dev_priv)->drm.dev)->revision)
 +#define GRAPHICS_VER(i915)            (INTEL_INFO(i915)->graphics_ver)
 +#define IS_GRAPHICS_VER(i915, from, until) \
 +      (GRAPHICS_VER(i915) >= (from) && GRAPHICS_VER(i915) <= (until))
  
 -#define INTEL_GEN_MASK(s, e) ( \
 -      BUILD_BUG_ON_ZERO(!__builtin_constant_p(s)) + \
 -      BUILD_BUG_ON_ZERO(!__builtin_constant_p(e)) + \
 -      GENMASK((e) - 1, (s) - 1))
 +#define MEDIA_VER(i915)                       (INTEL_INFO(i915)->media_ver)
 +#define IS_MEDIA_VER(i915, from, until) \
 +      (MEDIA_VER(i915) >= (from) && MEDIA_VER(i915) <= (until))
  
 -/* Returns true if Gen is in inclusive range [Start, End] */
 -#define IS_GEN_RANGE(dev_priv, s, e) \
 -      (!!(INTEL_INFO(dev_priv)->gen_mask & INTEL_GEN_MASK((s), (e))))
 +#define DISPLAY_VER(i915)     (INTEL_INFO(i915)->display.ver)
 +#define IS_DISPLAY_VER(i915, from, until) \
 +      (DISPLAY_VER(i915) >= (from) && DISPLAY_VER(i915) <= (until))
  
 -#define IS_GEN(dev_priv, n) \
 -      (BUILD_BUG_ON_ZERO(!__builtin_constant_p(n)) + \
 -       INTEL_INFO(dev_priv)->gen == (n))
 +#define REVID_FOREVER         0xff
 +#define INTEL_REVID(dev_priv) (to_pci_dev((dev_priv)->drm.dev)->revision)
  
  #define HAS_DSB(dev_priv)     (INTEL_INFO(dev_priv)->display.has_dsb)
  
@@@ -1392,7 -1384,6 +1392,7 @@@ IS_SUBPLATFORM(const struct drm_i915_pr
  #define IS_ROCKETLAKE(dev_priv)       IS_PLATFORM(dev_priv, INTEL_ROCKETLAKE)
  #define IS_DG1(dev_priv)        IS_PLATFORM(dev_priv, INTEL_DG1)
  #define IS_ALDERLAKE_S(dev_priv) IS_PLATFORM(dev_priv, INTEL_ALDERLAKE_S)
 +#define IS_ALDERLAKE_P(dev_priv) IS_PLATFORM(dev_priv, INTEL_ALDERLAKE_P)
  #define IS_HSW_EARLY_SDV(dev_priv) (IS_HASWELL(dev_priv) && \
                                    (INTEL_DEVID(dev_priv) & 0xFF00) == 0x0C00)
  #define IS_BDW_ULT(dev_priv) \
        (IS_ALDERLAKE_S(__i915) && \
         IS_GT_STEP(__i915, since, until))
  
 +#define IS_ADLP_DISPLAY_STEP(__i915, since, until) \
 +      (IS_ALDERLAKE_P(__i915) && \
 +       IS_DISPLAY_STEP(__i915, since, until))
 +
 +#define IS_ADLP_GT_STEP(__i915, since, until) \
 +      (IS_ALDERLAKE_P(__i915) && \
 +       IS_GT_STEP(__i915, since, until))
 +
  #define IS_LP(dev_priv)       (INTEL_INFO(dev_priv)->is_lp)
  #define IS_GEN9_LP(dev_priv)  (IS_GEN(dev_priv, 9) && IS_LP(dev_priv))
  #define IS_GEN9_BC(dev_priv)  (IS_GEN(dev_priv, 9) && !IS_LP(dev_priv))
@@@ -1922,9 -1905,6 +1922,6 @@@ int i915_reg_read_ioctl(struct drm_devi
                        struct drm_file *file);
  
  /* i915_mm.c */
- int remap_io_mapping(struct vm_area_struct *vma,
-                    unsigned long addr, unsigned long pfn, unsigned long size,
-                    struct io_mapping *iomap);
  int remap_io_sg(struct vm_area_struct *vma,
                unsigned long addr, unsigned long size,
                struct scatterlist *sgl, resource_size_t iobase);
index 32f7806ea12ca97a707c6b46c464b6e4af7d3475,0e2501b7fc2775d124ca4b7d5dc02c16ecbf33bc..15d9a64e7b4c47fccd6cf0cdc82ba7aa263de756
@@@ -35,7 -35,6 +35,7 @@@
  #include "display/intel_atomic.h"
  #include "display/intel_atomic_plane.h"
  #include "display/intel_bw.h"
 +#include "display/intel_de.h"
  #include "display/intel_display_types.h"
  #include "display/intel_fbc.h"
  #include "display/intel_sprite.h"
@@@ -2340,7 -2339,7 +2340,7 @@@ static void i9xx_update_wm(struct intel
  
        if (IS_I945GM(dev_priv))
                wm_info = &i945_wm_info;
 -      else if (!IS_DISPLAY_VER(dev_priv, 2))
 +      else if (DISPLAY_VER(dev_priv) != 2)
                wm_info = &i915_wm_info;
        else
                wm_info = &i830_a_wm_info;
                        crtc->base.primary->state->fb;
                int cpp;
  
 -              if (IS_DISPLAY_VER(dev_priv, 2))
 +              if (DISPLAY_VER(dev_priv) == 2)
                        cpp = 4;
                else
                        cpp = fb->format->cpp[0];
                        planea_wm = wm_info->max_wm;
        }
  
 -      if (IS_DISPLAY_VER(dev_priv, 2))
 +      if (DISPLAY_VER(dev_priv) == 2)
                wm_info = &i830_bc_wm_info;
  
        fifo_size = dev_priv->display.get_fifo_size(dev_priv, PLANE_B);
                        crtc->base.primary->state->fb;
                int cpp;
  
 -              if (IS_DISPLAY_VER(dev_priv, 2))
 +              if (DISPLAY_VER(dev_priv) == 2)
                        cpp = 4;
                else
                        cpp = fb->format->cpp[0];
@@@ -2968,7 -2967,7 +2968,7 @@@ static void intel_fixup_spr_wm_latency(
                                       u16 wm[5])
  {
        /* ILK sprite LP0 latency is 1300 ns */
 -      if (IS_DISPLAY_VER(dev_priv, 5))
 +      if (DISPLAY_VER(dev_priv) == 5)
                wm[0] = 13;
  }
  
@@@ -2976,7 -2975,7 +2976,7 @@@ static void intel_fixup_cur_wm_latency(
                                       u16 wm[5])
  {
        /* ILK cursor LP0 latency is 1300 ns */
 -      if (IS_DISPLAY_VER(dev_priv, 5))
 +      if (DISPLAY_VER(dev_priv) == 5)
                wm[0] = 13;
  }
  
@@@ -2995,7 -2994,7 +2995,7 @@@ int ilk_wm_max_level(const struct drm_i
  
  static void intel_print_wm_latency(struct drm_i915_private *dev_priv,
                                   const char *name,
-                                  const u16 *wm)
+                                  const u16 wm[])
  {
        int level, max_level = ilk_wm_max_level(dev_priv);
  
@@@ -3106,7 -3105,7 +3106,7 @@@ static void ilk_setup_wm_latency(struc
        intel_print_wm_latency(dev_priv, "Sprite", dev_priv->wm.spr_latency);
        intel_print_wm_latency(dev_priv, "Cursor", dev_priv->wm.cur_latency);
  
 -      if (IS_DISPLAY_VER(dev_priv, 6)) {
 +      if (DISPLAY_VER(dev_priv) == 6) {
                snb_wm_latency_quirk(dev_priv);
                snb_wm_lp3_irq_quirk(dev_priv);
        }
@@@ -3355,7 -3354,7 +3355,7 @@@ static void ilk_wm_merge(struct drm_i91
         * What we should check here is whether FBC can be
         * enabled sometime later.
         */
 -      if (IS_DISPLAY_VER(dev_priv, 5) && !merged->fbc_wm_enabled &&
 +      if (DISPLAY_VER(dev_priv) == 5 && !merged->fbc_wm_enabled &&
            intel_fbc_is_active(dev_priv)) {
                for (level = 2; level <= max_level; level++) {
                        struct intel_wm_level *wm = &merged->wm[level];
@@@ -3637,16 -3636,16 +3637,16 @@@ bool ilk_disable_lp_wm(struct drm_i915_
  
  u8 intel_enabled_dbuf_slices_mask(struct drm_i915_private *dev_priv)
  {
 -      int i;
 -      int max_slices = INTEL_INFO(dev_priv)->num_supported_dbuf_slices;
 -      u8 enabled_slices_mask = 0;
 +      u8 enabled_slices = 0;
 +      enum dbuf_slice slice;
  
 -      for (i = 0; i < max_slices; i++) {
 -              if (intel_uncore_read(&dev_priv->uncore, DBUF_CTL_S(i)) & DBUF_POWER_STATE)
 -                      enabled_slices_mask |= BIT(i);
 +      for_each_dbuf_slice(dev_priv, slice) {
 +              if (intel_uncore_read(&dev_priv->uncore,
 +                                    DBUF_CTL_S(slice)) & DBUF_POWER_STATE)
 +                      enabled_slices |= BIT(slice);
        }
  
 -      return enabled_slices_mask;
 +      return enabled_slices;
  }
  
  /*
   */
  static bool skl_needs_memory_bw_wa(struct drm_i915_private *dev_priv)
  {
 -      return IS_GEN9_BC(dev_priv) || IS_BROXTON(dev_priv);
 +      return DISPLAY_VER(dev_priv) == 9;
  }
  
  static bool
  intel_has_sagv(struct drm_i915_private *dev_priv)
  {
 -      return (IS_GEN9_BC(dev_priv) || DISPLAY_VER(dev_priv) >= 11 || IS_CANNONLAKE(dev_priv)) &&
 +      return DISPLAY_VER(dev_priv) >= 9 && !IS_LP(dev_priv) &&
                dev_priv->sagv_status != I915_SAGV_NOT_CONTROLLED;
  }
  
@@@ -3681,13 -3680,13 +3681,13 @@@ skl_setup_sagv_block_time(struct drm_i9
                }
  
                drm_dbg(&dev_priv->drm, "Couldn't read SAGV block time!\n");
 -      } else if (IS_DISPLAY_VER(dev_priv, 11)) {
 +      } else if (DISPLAY_VER(dev_priv) == 11) {
                dev_priv->sagv_block_time_us = 10;
                return;
 -      } else if (IS_DISPLAY_VER(dev_priv, 10)) {
 +      } else if (DISPLAY_VER(dev_priv) == 10) {
                dev_priv->sagv_block_time_us = 20;
                return;
 -      } else if (IS_DISPLAY_VER(dev_priv, 9)) {
 +      } else if (DISPLAY_VER(dev_priv) == 9) {
                dev_priv->sagv_block_time_us = 30;
                return;
        } else {
@@@ -4029,10 -4028,22 +4029,10 @@@ static int intel_compute_sagv_mask(stru
        return 0;
  }
  
 -static int intel_dbuf_size(struct drm_i915_private *dev_priv)
 -{
 -      int ddb_size = INTEL_INFO(dev_priv)->ddb_size;
 -
 -      drm_WARN_ON(&dev_priv->drm, ddb_size == 0);
 -
 -      if (DISPLAY_VER(dev_priv) < 11)
 -              return ddb_size - 4; /* 4 blocks for bypass path allocation */
 -
 -      return ddb_size;
 -}
 -
  static int intel_dbuf_slice_size(struct drm_i915_private *dev_priv)
  {
 -      return intel_dbuf_size(dev_priv) /
 -              INTEL_INFO(dev_priv)->num_supported_dbuf_slices;
 +      return INTEL_INFO(dev_priv)->dbuf.size /
 +              hweight8(INTEL_INFO(dev_priv)->dbuf.slice_mask);
  }
  
  static void
@@@ -4051,15 -4062,18 +4051,15 @@@ skl_ddb_entry_for_slices(struct drm_i91
        ddb->end = fls(slice_mask) * slice_size;
  
        WARN_ON(ddb->start >= ddb->end);
 -      WARN_ON(ddb->end > intel_dbuf_size(dev_priv));
 +      WARN_ON(ddb->end > INTEL_INFO(dev_priv)->dbuf.size);
  }
  
  u32 skl_ddb_dbuf_slice_mask(struct drm_i915_private *dev_priv,
                            const struct skl_ddb_entry *entry)
  {
 -      u32 slice_mask = 0;
 -      u16 ddb_size = intel_dbuf_size(dev_priv);
 -      u16 num_supported_slices = INTEL_INFO(dev_priv)->num_supported_dbuf_slices;
 -      u16 slice_size = ddb_size / num_supported_slices;
 -      u16 start_slice;
 -      u16 end_slice;
 +      int slice_size = intel_dbuf_slice_size(dev_priv);
 +      enum dbuf_slice start_slice, end_slice;
 +      u8 slice_mask = 0;
  
        if (!skl_ddb_entry_size(entry))
                return 0;
@@@ -4599,9 -4613,9 +4599,9 @@@ static u8 skl_compute_dbuf_slices(struc
        struct drm_i915_private *dev_priv = to_i915(crtc->base.dev);
        enum pipe pipe = crtc->pipe;
  
 -      if (IS_DISPLAY_VER(dev_priv, 12))
 +      if (DISPLAY_VER(dev_priv) == 12)
                return tgl_compute_dbuf_slices(pipe, active_pipes);
 -      else if (IS_DISPLAY_VER(dev_priv, 11))
 +      else if (DISPLAY_VER(dev_priv) == 11)
                return icl_compute_dbuf_slices(pipe, active_pipes);
        /*
         * For anything else just return one slice yet.
@@@ -4972,7 -4986,7 +4972,7 @@@ skl_allocate_plane_ddb(struct intel_ato
                         * Wa_1408961008:icl, ehl
                         * Underruns with WM1+ disabled
                         */
 -                      if (IS_DISPLAY_VER(dev_priv, 11) &&
 +                      if (DISPLAY_VER(dev_priv) == 11 &&
                            level == 1 && wm->wm[0].enable) {
                                wm->wm[level].blocks = wm->wm[0].blocks;
                                wm->wm[level].lines = wm->wm[0].lines;
@@@ -5185,14 -5199,6 +5185,14 @@@ static bool skl_wm_has_lines(struct drm
        return level > 0;
  }
  
 +static int skl_wm_max_lines(struct drm_i915_private *dev_priv)
 +{
 +      if (DISPLAY_VER(dev_priv) >= 13)
 +              return 255;
 +      else
 +              return 31;
 +}
 +
  static void skl_compute_plane_wm(const struct intel_crtc_state *crtc_state,
                                 int level,
                                 unsigned int latency,
                     (wp->plane_bytes_per_line / wp->dbuf_block_size < 1)) {
                        selected_result = method2;
                } else if (latency >= wp->linetime_us) {
 -                      if (IS_DISPLAY_VER(dev_priv, 9))
 +                      if (DISPLAY_VER(dev_priv) == 9)
                                selected_result = min_fixed16(method1, method2);
                        else
                                selected_result = method2;
        lines = div_round_up_fixed16(selected_result,
                                     wp->plane_blocks_per_line);
  
 -      if (IS_GEN9_BC(dev_priv) || IS_BROXTON(dev_priv)) {
 +      if (DISPLAY_VER(dev_priv) == 9) {
                /* Display WA #1125: skl,bxt,kbl */
                if (level == 0 && wp->rc_surface)
                        blocks += fixed16_to_u32_round_up(wp->y_tile_minimum);
        if (!skl_wm_has_lines(dev_priv, level))
                lines = 0;
  
 -      if (lines > 31) {
 +      if (lines > skl_wm_max_lines(dev_priv)) {
                /* reject it */
                result->min_ddb_alloc = U16_MAX;
                return;
@@@ -5369,7 -5375,7 +5369,7 @@@ static void skl_compute_transition_wm(s
         * WaDisableTWM:skl,kbl,cfl,bxt
         * Transition WM are not recommended by HW team for GEN9
         */
 -      if (IS_GEN9_BC(dev_priv) || IS_BROXTON(dev_priv))
 +      if (DISPLAY_VER(dev_priv) == 9)
                return;
  
        if (DISPLAY_VER(dev_priv) >= 11)
                trans_min = 14;
  
        /* Display WA #1140: glk,cnl */
 -      if (IS_DISPLAY_VER(dev_priv, 10))
 +      if (DISPLAY_VER(dev_priv) == 10)
                trans_amount = 0;
        else
                trans_amount = 10; /* This is configurable amount */
@@@ -5593,7 -5599,7 +5593,7 @@@ static void skl_write_wm_level(struct d
        if (level->ignore_lines)
                val |= PLANE_WM_IGNORE_LINES;
        val |= level->blocks;
 -      val |= level->lines << PLANE_WM_LINES_SHIFT;
 +      val |= REG_FIELD_PREP(PLANE_WM_LINES_MASK, level->lines);
  
        intel_de_write_fw(dev_priv, reg, val);
  }
@@@ -5819,10 -5825,10 +5819,10 @@@ skl_compute_ddb(struct intel_atomic_sta
                        return ret;
  
                drm_dbg_kms(&dev_priv->drm,
 -                          "Enabled dbuf slices 0x%x -> 0x%x (out of %d dbuf slices)\n",
 +                          "Enabled dbuf slices 0x%x -> 0x%x (total dbuf slices 0x%x)\n",
                            old_dbuf_state->enabled_slices,
                            new_dbuf_state->enabled_slices,
 -                          INTEL_INFO(dev_priv)->num_supported_dbuf_slices);
 +                          INTEL_INFO(dev_priv)->dbuf.slice_mask);
        }
  
        for_each_new_intel_crtc_in_state(state, crtc, new_crtc_state, i) {
@@@ -6201,7 -6207,8 +6201,7 @@@ static void skl_wm_level_from_reg_val(u
        level->enable = val & PLANE_WM_EN;
        level->ignore_lines = val & PLANE_WM_IGNORE_LINES;
        level->blocks = val & PLANE_WM_BLOCKS_MASK;
 -      level->lines = (val >> PLANE_WM_LINES_SHIFT) &
 -              PLANE_WM_LINES_MASK;
 +      level->lines = REG_FIELD_GET(PLANE_WM_LINES_MASK, val);
  }
  
  void skl_pipe_wm_get_hw_state(struct intel_crtc *crtc,
@@@ -7134,19 -7141,6 +7134,19 @@@ static void gen12lp_init_clock_gating(s
        /* Wa_14011059788:tgl,rkl,adl_s,dg1 */
        intel_uncore_rmw(&dev_priv->uncore, GEN10_DFR_RATIO_EN_AND_CHICKEN,
                         0, DFR_DISABLE);
 +
 +      /* Wa_14013723622:tgl,rkl,dg1,adl-s */
 +      if (DISPLAY_VER(dev_priv) == 12)
 +              intel_uncore_rmw(&dev_priv->uncore, CLKREQ_POLICY,
 +                               CLKREQ_POLICY_MEM_UP_OVRD, 0);
 +}
 +
 +static void adlp_init_clock_gating(struct drm_i915_private *dev_priv)
 +{
 +      gen12lp_init_clock_gating(dev_priv);
 +
 +      /* Wa_22011091694:adlp */
 +      intel_de_rmw(dev_priv, GEN9_CLKGATE_DIS_5, 0, DPCE_GATING_DIS);
  }
  
  static void dg1_init_clock_gating(struct drm_i915_private *dev_priv)
@@@ -7626,9 -7620,7 +7626,9 @@@ static void nop_init_clock_gating(struc
   */
  void intel_init_clock_gating_hooks(struct drm_i915_private *dev_priv)
  {
 -      if (IS_DG1(dev_priv))
 +      if (IS_ALDERLAKE_P(dev_priv))
 +              dev_priv->display.init_clock_gating = adlp_init_clock_gating;
 +      else if (IS_DG1(dev_priv))
                dev_priv->display.init_clock_gating = dg1_init_clock_gating;
        else if (IS_GEN(dev_priv, 12))
                dev_priv->display.init_clock_gating = gen12lp_init_clock_gating;
@@@ -7697,9 -7689,9 +7697,9 @@@ void intel_init_pm(struct drm_i915_priv
        } else if (HAS_PCH_SPLIT(dev_priv)) {
                ilk_setup_wm_latency(dev_priv);
  
 -              if ((IS_DISPLAY_VER(dev_priv, 5) && dev_priv->wm.pri_latency[1] &&
 +              if ((DISPLAY_VER(dev_priv) == 5 && dev_priv->wm.pri_latency[1] &&
                     dev_priv->wm.spr_latency[1] && dev_priv->wm.cur_latency[1]) ||
 -                  (!IS_DISPLAY_VER(dev_priv, 5) && dev_priv->wm.pri_latency[0] &&
 +                  (DISPLAY_VER(dev_priv) != 5 && dev_priv->wm.pri_latency[0] &&
                     dev_priv->wm.spr_latency[0] && dev_priv->wm.cur_latency[0])) {
                        dev_priv->display.compute_pipe_wm = ilk_compute_pipe_wm;
                        dev_priv->display.compute_intermediate_wm =
                        dev_priv->display.update_wm = NULL;
                } else
                        dev_priv->display.update_wm = pnv_update_wm;
 -      } else if (IS_DISPLAY_VER(dev_priv, 4)) {
 +      } else if (DISPLAY_VER(dev_priv) == 4) {
                dev_priv->display.update_wm = i965_update_wm;
 -      } else if (IS_DISPLAY_VER(dev_priv, 3)) {
 +      } else if (DISPLAY_VER(dev_priv) == 3) {
                dev_priv->display.update_wm = i9xx_update_wm;
                dev_priv->display.get_fifo_size = i9xx_get_fifo_size;
 -      } else if (IS_DISPLAY_VER(dev_priv, 2)) {
 +      } else if (DISPLAY_VER(dev_priv) == 2) {
                if (INTEL_NUM_PIPES(dev_priv) == 1) {
                        dev_priv->display.update_wm = i845_update_wm;
                        dev_priv->display.get_fifo_size = i845_get_fifo_size;
index e3c4130dab070efcc01d1f5b50c18186c7442ead,1e85c2021f2f86514469572bb22118851c34e754..d6f6a084a190d85ba9ffa54b170c2895b0d0d9e9
@@@ -687,14 -687,14 +687,14 @@@ struct drm_device
  #define DP_DSC_ENABLE                       0x160   /* DP 1.4 */
  # define DP_DECOMPRESSION_EN                (1 << 0)
  
 -#define DP_PSR_EN_CFG                     0x170   /* XXX 1.2? */
 -# define DP_PSR_ENABLE                            (1 << 0)
 -# define DP_PSR_MAIN_LINK_ACTIVE          (1 << 1)
 -# define DP_PSR_CRC_VERIFICATION          (1 << 2)
 -# define DP_PSR_FRAME_CAPTURE             (1 << 3)
 -# define DP_PSR_SELECTIVE_UPDATE          (1 << 4)
 -# define DP_PSR_IRQ_HPD_WITH_CRC_ERRORS     (1 << 5)
 -# define DP_PSR_ENABLE_PSR2               (1 << 6) /* eDP 1.4a */
 +#define DP_PSR_EN_CFG                         0x170   /* XXX 1.2? */
 +# define DP_PSR_ENABLE                                BIT(0)
 +# define DP_PSR_MAIN_LINK_ACTIVE              BIT(1)
 +# define DP_PSR_CRC_VERIFICATION              BIT(2)
 +# define DP_PSR_FRAME_CAPTURE                 BIT(3)
 +# define DP_PSR_SU_REGION_SCANLINE_CAPTURE    BIT(4) /* eDP 1.4a */
 +# define DP_PSR_IRQ_HPD_WITH_CRC_ERRORS               BIT(5) /* eDP 1.4a */
 +# define DP_PSR_ENABLE_PSR2                   BIT(6) /* eDP 1.4a */
  
  #define DP_ADAPTER_CTRL                           0x1a0
  # define DP_ADAPTER_CTRL_FORCE_LOAD_SENSE   (1 << 0)
@@@ -1846,34 -1846,34 +1846,34 @@@ struct drm_dp_aux_cec 
   * @crc_count: counter of captured frame CRCs
   * @transfer: transfers a message representing a single AUX transaction
   *
-  * The .dev field should be set to a pointer to the device that implements
-  * the AUX channel.
+  * The @dev field should be set to a pointer to the device that implements the
+  * AUX channel.
   *
-  * The .name field may be used to specify the name of the I2C adapter. If set to
-  * NULL, dev_name() of .dev will be used.
+  * The @name field may be used to specify the name of the I2C adapter. If set to
+  * %NULL, dev_name() of @dev will be used.
   *
-  * Drivers provide a hardware-specific implementation of how transactions
-  * are executed via the .transfer() function. A pointer to a drm_dp_aux_msg
+  * Drivers provide a hardware-specific implementation of how transactions are
+  * executed via the @transfer() function. A pointer to a &drm_dp_aux_msg
   * structure describing the transaction is passed into this function. Upon
-  * success, the implementation should return the number of payload bytes
-  * that were transferred, or a negative error-code on failure. Helpers
-  * propagate errors from the .transfer() function, with the exception of
-  * the -EBUSY error, which causes a transaction to be retried. On a short,
-  * helpers will return -EPROTO to make it simpler to check for failure.
+  * success, the implementation should return the number of payload bytes that
+  * were transferred, or a negative error-code on failure. Helpers propagate
+  * errors from the @transfer() function, with the exception of the %-EBUSY
+  * error, which causes a transaction to be retried. On a short, helpers will
+  * return %-EPROTO to make it simpler to check for failure.
   *
   * An AUX channel can also be used to transport I2C messages to a sink. A
-  * typical application of that is to access an EDID that's present in the
-  * sink device. The .transfer() function can also be used to execute such
-  * transactions. The drm_dp_aux_register() function registers an I2C
-  * adapter that can be passed to drm_probe_ddc(). Upon removal, drivers
-  * should call drm_dp_aux_unregister() to remove the I2C adapter.
-  * The I2C adapter uses long transfers by default; if a partial response is
-  * received, the adapter will drop down to the size given by the partial
-  * response for this transaction only.
+  * typical application of that is to access an EDID that's present in the sink
+  * device. The @transfer() function can also be used to execute such
+  * transactions. The drm_dp_aux_register() function registers an I2C adapter
+  * that can be passed to drm_probe_ddc(). Upon removal, drivers should call
+  * drm_dp_aux_unregister() to remove the I2C adapter. The I2C adapter uses long
+  * transfers by default; if a partial response is received, the adapter will
+  * drop down to the size given by the partial response for this transaction
+  * only.
   *
-  * Note that the aux helper code assumes that the .transfer() function
-  * only modifies the reply field of the drm_dp_aux_msg structure.  The
-  * retry logic and i2c helpers assume this is the case.
+  * Note that the aux helper code assumes that the @transfer() function only
+  * modifies the reply field of the &drm_dp_aux_msg structure. The retry logic
+  * and i2c helpers assume this is the case.
   */
  struct drm_dp_aux {
        const char *name;
This page took 0.415396 seconds and 4 git commands to generate.