From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Shashank Sharma <shashank.sharma@intel.com>
Cc: intel-gfx@lists.freedesktop.org,
Jose Abreu <joabreu@synopsys.com>,
dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v2 04/11] drm: parse ycbcr 420 deep color information
Date: Tue, 30 May 2017 19:32:16 +0300 [thread overview]
Message-ID: <20170530163216.GF12629@intel.com> (raw)
In-Reply-To: <1496146430-11430-5-git-send-email-shashank.sharma@intel.com>
On Tue, May 30, 2017 at 05:43:43PM +0530, Shashank Sharma wrote:
> CEA-861-F spec adds ycbcr420 deep color support information
> in hf-vsdb block. This patch extends the existing hf-vsdb parsing
> function by adding parsing of ycbcr420 deep color support from the
> EDID and adding it into display information stored.
>
> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> Cc: Jose Abreu <joabreu@synopsys.com>
> Signed-off-by: Shashank Sharma <shashank.sharma@intel.com>
> ---
> drivers/gpu/drm/drm_edid.c | 15 +++++++++++++++
> include/drm/drm_connector.h | 3 +++
> include/drm/drm_edid.h | 5 +++++
> 3 files changed, 23 insertions(+)
>
> diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c
> index ce86528..50fa96e 100644
> --- a/drivers/gpu/drm/drm_edid.c
> +++ b/drivers/gpu/drm/drm_edid.c
> @@ -4142,6 +4142,19 @@ drm_default_rgb_quant_range(const struct drm_display_mode *mode)
> }
> EXPORT_SYMBOL(drm_default_rgb_quant_range);
>
> +static void drm_parse_ycbcr420_deep_color_info(struct drm_connector *connector,
> + const u8 *db)
> +{
> + struct drm_hdmi_info *info = &connector->display_info.hdmi;
> +
> + if (db[7] & DRM_EDID_YCBCR420_DC_48)
> + info->ycbcr420_dc_modes |= DRM_EDID_YCBCR420_DC_48;
> + if (db[7] & DRM_EDID_YCBCR420_DC_36)
> + info->ycbcr420_dc_modes |= DRM_EDID_YCBCR420_DC_36;
> + if (db[7] & DRM_EDID_YCBCR420_DC_30)
> + info->ycbcr420_dc_modes |= DRM_EDID_YCBCR420_DC_30;
> +}
> +
> static void drm_parse_hdmi_forum_vsdb(struct drm_connector *connector,
> const u8 *hf_vsdb)
> {
> @@ -4182,6 +4195,8 @@ static void drm_parse_hdmi_forum_vsdb(struct drm_connector *connector,
> scdc->scrambling.low_rates = true;
> }
> }
> +
> + drm_parse_ycbcr420_deep_color_info(connector, hf_vsdb);
> }
>
> static void drm_parse_hdmi_deep_color_info(struct drm_connector *connector,
> diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h
> index 07b10ab..49cc38c 100644
> --- a/include/drm/drm_connector.h
> +++ b/include/drm/drm_connector.h
> @@ -148,6 +148,9 @@ struct drm_hdmi_info {
>
> /** @ycbcr420_vcb_map: bitmap of SVD index, to extraxt vcb modes */
> u64 ycbcr420_vcb_map;
> +
> + /** @ycbcr420_dc_modes: bitmap of deep color support index */
> + u8 ycbcr420_dc_modes;
We seem to be wasting quite a few bits by reusing the EDID bit
definition directly. Maybe we should consider packing these better?
But I suppose we can look into that later.
> };
>
> /**
> diff --git a/include/drm/drm_edid.h b/include/drm/drm_edid.h
> index c07eb81..a4d174e7 100644
> --- a/include/drm/drm_edid.h
> +++ b/include/drm/drm_edid.h
> @@ -213,6 +213,11 @@ struct detailed_timing {
> #define DRM_EDID_HDMI_DC_30 (1 << 4)
> #define DRM_EDID_HDMI_DC_Y444 (1 << 3)
>
> +/* YCBCR 420 deep color modes */
> +#define DRM_EDID_YCBCR420_DC_48 (1 << 6)
> +#define DRM_EDID_YCBCR420_DC_36 (1 << 5)
> +#define DRM_EDID_YCBCR420_DC_30 (1 << 4)
> +
> /* ELD Header Block */
> #define DRM_ELD_HEADER_BLOCK_SIZE 4
>
> --
> 2.7.4
--
Ville Syrjälä
Intel OTC
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2017-05-30 16:32 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-30 12:13 [PATCH v2 00/11] HDMI YCBCR output handling in DRM layer Shashank Sharma
2017-05-30 12:13 ` [PATCH v2 01/11] drm: Add HDMI 2.0 VIC support for AVI info-frames Shashank Sharma
2017-05-30 16:13 ` Ville Syrjälä
2017-05-30 16:30 ` Sharma, Shashank
2017-05-31 12:41 ` Ville Syrjälä
2017-05-31 15:36 ` Sharma, Shashank
2017-06-01 19:29 ` Ville Syrjälä
2017-05-30 12:13 ` [PATCH v2 02/11] drm/edid: Complete CEA modedb(VIC 1-107) Shashank Sharma
2017-05-30 16:18 ` Ville Syrjälä
2017-05-30 16:26 ` Sharma, Shashank
2017-05-31 12:39 ` Ville Syrjälä
2017-05-31 15:31 ` Sharma, Shashank
2017-05-30 12:13 ` [PATCH v2 03/11] drm: parse ycbcr420 cmdb block Shashank Sharma
2017-05-30 16:27 ` Ville Syrjälä
2017-05-30 12:13 ` [PATCH v2 04/11] drm: parse ycbcr 420 deep color information Shashank Sharma
2017-05-30 16:32 ` Ville Syrjälä [this message]
2017-05-30 12:13 ` [PATCH v2 05/11] drm: create hdmi output property Shashank Sharma
2017-05-30 16:36 ` Ville Syrjälä
2017-05-30 16:48 ` Sharma, Shashank
2017-05-31 12:46 ` Ville Syrjälä
2017-05-31 13:04 ` Sharma, Shashank
2017-05-30 12:13 ` [PATCH v2 06/11] drm: set output colorspace in AVI infoframe Shashank Sharma
2017-05-30 12:13 ` [PATCH v2 07/11] drm: add ycbcr helper functions Shashank Sharma
2017-05-31 0:31 ` kbuild test robot
2017-05-30 12:13 ` [PATCH v2 08/11] drm/i915: handle ycbcr outputs Shashank Sharma
2017-05-30 22:36 ` kbuild test robot
2017-05-30 12:13 ` [PATCH v2 09/11] drm/i915: handle csc for ycbcr HDMI output Shashank Sharma
2017-05-30 12:13 ` [PATCH v2 10/11] drm/i915: prepare ycbcr420 modeset Shashank Sharma
2017-05-30 12:13 ` [PATCH v2 11/11] drm/i915: set colorspace for ycbcr outputs Shashank Sharma
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=20170530163216.GF12629@intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=joabreu@synopsys.com \
--cc=shashank.sharma@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).