All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@linux.intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: Manasi Navare <manasi.d.navare@intel.com>,
	Anusha Srivatsa <anusha.srivatsa@intel.com>,
	dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm: Add DPCD definitions for DP 1.4 FEC feature
Date: Wed, 14 Feb 2018 13:59:54 +0200	[thread overview]
Message-ID: <87bmgr6ath.fsf@intel.com> (raw)
In-Reply-To: <1518595150-815-1-git-send-email-anusha.srivatsa@intel.com>

On Tue, 13 Feb 2018, Anusha Srivatsa <anusha.srivatsa@intel.com> wrote:
> Forward Error Correction is supported on DP 1.4.
> This patch adds corresponding DPCD register definitions.
>
> v2: Add dri-devel mailing list to the CC list(Jani)
>
> v3: Change names, add missing masks (Manasi)
>
> v4: Add missing shifts to mask (Manasi)
>
> v5: Arrange the definitions in ascending order
> of the address (Jani)

Okay, my apologies, I noticed some further errors that I really should
have noticed earlier. Please see comments inline.

>
> Cc: dri-devel@lists.freedesktop.org
> Cc: Ville Syrjala <ville.syrjala@linux.intel.com>
> Cc: Jani Nikula <jani.nikula@linux.intel.com>
> Cc: Manasi Navare <manasi.d.navare@intel.com>
> Signed-off-by: Anusha Srivatsa <anusha.srivatsa@intel.com>
> ---
>  include/drm/drm_dp_helper.h | 30 ++++++++++++++++++++++++++++++
>  1 file changed, 30 insertions(+)
>
> diff --git a/include/drm/drm_dp_helper.h b/include/drm/drm_dp_helper.h
> index c239e6e..a19d6fb 100644
> --- a/include/drm/drm_dp_helper.h
> +++ b/include/drm/drm_dp_helper.h
> @@ -329,6 +329,13 @@
>  # define DP_DS_12BPC		            2
>  # define DP_DS_16BPC		            3
>  
> +/* DP Forward error Correction Registers */
> +#define DP_FEC_CAPABILITY		    (0x090)

Nitpick, the braces are unnecessary.

All the FEC dpcd offset definitions should have /* 1.4 */ at the end
(just the offset macros, not the contents).

> +# define DP_FEC_CAPABLE			    (1 << 0)
> +# define DP_FEC_UNCORR_BLK_ERROR_COUNT_CAP  (1 << 1)
> +# define DP_FEC_CORR_BLK_ERROR_COUNT_CAP    (1 << 2)
> +# define DP_FEC_BIT_ERROR_COUNT_CAP	    (1 << 3)
> +
>  /* link configuration */
>  #define	DP_LINK_BW_SET		            0x100
>  # define DP_LINK_RATE_TABLE		    0x00    /* eDP 1.4 */
> @@ -445,6 +452,18 @@
>  #define DP_UPSTREAM_DEVICE_DP_PWR_NEED	    0x118   /* 1.2 */
>  # define DP_PWR_NOT_NEEDED		    (1 << 0)
>  
> +#define DP_FEC_CONFIGURATION		    0x120
> +# define DP_FEC_READY			    (1 << 0)
> +# define DP_FEC_ERR_COUNT_DIS		    (0 << 1)
> +# define DP_FEC_UNCORR_BLK_ERROR_COUNT	    (1 << 1)
> +# define DP_FEC_CORR_BLK_ERROR_COUNT	    (2 << 1)
> +# define DP_FEC_BIT_ERROR_COUNT		    (3 << 1)
> +# define DP_FEC_ERR_COUNT_SEL_MASK	    (0xff << 4)

# define DP_FEC_ERROR_COUNT_SEL_MASK		(7 << 1)

Put that above the values for error count sel.

And then

#define DP_FEC_LANE_SELECT_MASK			(3 << 4)

> +# define DP_FEC_LANE_0_SELECT		    (0 << 4)
> +# define DP_FEC_LANE_1_SELECT		    (1 << 4)
> +# define DP_FEC_LANE_2_SELECT		    (2 << 4)
> +# define DP_FEC_LANE_3_SELECT		    (3 << 4)
> +
>  #define DP_AUX_FRAME_SYNC_VALUE		    0x15c   /* eDP 1.4 */
>  # define DP_AUX_FRAME_SYNC_VALID	    (1 << 0)
>  
> @@ -620,6 +639,17 @@
>  #define DP_TEST_SINK			    0x270
>  # define DP_TEST_SINK_START		    (1 << 0)
>  
> +#define DP_FEC_STATUS			    0x280
> +# define DP_FEC_DECODE_EN_DETECTED	    (1 << 0)
> +# define DP_FEC_DECODE_DIS_DETECTED	    (1 << 1)
> +
> +#define DP_FEC_ERROR_COUNT_LSB		    0x0281
> +
> +#define DP_FEC_ERROR_COUNT_MSB		    0x0282
> +# define DP_FEC_ERROR_COUNT_MASK	    0x7F
> +# define DP_FEC_ERR_COUNT_SHIFT		    8

Unnecessary.

> +# define DP_FEC_ERR_COUNT_VALID		    (1 << 7)
> +
>  #define DP_PAYLOAD_TABLE_UPDATE_STATUS      0x2c0   /* 1.2 MST */
>  # define DP_PAYLOAD_TABLE_UPDATED           (1 << 0)
>  # define DP_PAYLOAD_ACT_HANDLED             (1 << 1)

-- 
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

  parent reply	other threads:[~2018-02-14 11:59 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-14  7:59 [PATCH] drm: Add DPCD definitions for DP 1.4 FEC feature Anusha Srivatsa
2018-02-14  8:38 ` ✓ Fi.CI.BAT: success for drm: Add DPCD definitions for DP 1.4 FEC feature (rev4) Patchwork
2018-02-14  9:52 ` ✗ Fi.CI.IGT: warning " Patchwork
2018-02-14 11:59 ` Jani Nikula [this message]
2018-02-14 19:28 ` [PATCH] drm: Add DPCD definitions for DP 1.4 FEC feature Anusha Srivatsa
2018-02-15 13:53   ` Jani Nikula
2018-02-14 21:34 ` ✗ Fi.CI.CHECKPATCH: warning for drm: Add DPCD definitions for DP 1.4 FEC feature (rev5) Patchwork
2018-02-14 21:51 ` ✓ Fi.CI.BAT: success " Patchwork
2018-02-15  6:54 ` ✗ Fi.CI.IGT: failure " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2017-12-22 22:02 [PATCH] drm: Add DPCD definitions for DP 1.4 FEC feature Anusha Srivatsa
2017-12-22 23:39 ` Manasi Navare
2017-11-28  0:55 Anusha Srivatsa
2017-12-21 20:36 ` Manasi Navare
2017-12-21 20:51   ` Srivatsa, Anusha
2017-11-22 21:49 Anusha Srivatsa
2017-11-23  7:15 ` Jani Nikula
2017-11-28  0:59   ` Srivatsa, Anusha

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87bmgr6ath.fsf@intel.com \
    --to=jani.nikula@linux.intel.com \
    --cc=anusha.srivatsa@intel.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=manasi.d.navare@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.