Commit 974e0701 authored by Lespiau, Damien's avatar Lespiau, Damien Committed by Dave Airlie

video/hdmi: Derive the bar data valid bit from the bar data fields

Just like:

  Author: Damien Lespiau <damien.lespiau@intel.com>
  Date:   Mon Aug 12 11:53:24 2013 +0100

      video/hdmi: Don't let the user of this API create invalid infoframes

But this time for the horizontal/vertical bar data present bits.
Signed-off-by: default avatarDamien Lespiau <damien.lespiau@intel.com>
Reviewed-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: default avatarThierry Reding <treding@nvidia.com>
Signed-off-by: default avatarDave Airlie <airlied@gmail.com>
parent a5ad3dcf
...@@ -103,10 +103,11 @@ ssize_t hdmi_avi_infoframe_pack(struct hdmi_avi_infoframe *frame, void *buffer, ...@@ -103,10 +103,11 @@ ssize_t hdmi_avi_infoframe_pack(struct hdmi_avi_infoframe *frame, void *buffer,
if (frame->active_aspect & 0xf) if (frame->active_aspect & 0xf)
ptr[0] |= BIT(4); ptr[0] |= BIT(4);
if (frame->horizontal_bar_valid) /* Bit 3 and 2 indicate if we transmit horizontal/vertical bar data */
if (frame->top_bar || frame->bottom_bar)
ptr[0] |= BIT(3); ptr[0] |= BIT(3);
if (frame->vertical_bar_valid) if (frame->left_bar || frame->right_bar)
ptr[0] |= BIT(2); ptr[0] |= BIT(2);
ptr[1] = ((frame->colorimetry & 0x3) << 6) | ptr[1] = ((frame->colorimetry & 0x3) << 6) |
......
...@@ -109,8 +109,6 @@ struct hdmi_avi_infoframe { ...@@ -109,8 +109,6 @@ struct hdmi_avi_infoframe {
unsigned char version; unsigned char version;
unsigned char length; unsigned char length;
enum hdmi_colorspace colorspace; enum hdmi_colorspace colorspace;
bool horizontal_bar_valid;
bool vertical_bar_valid;
enum hdmi_scan_mode scan_mode; enum hdmi_scan_mode scan_mode;
enum hdmi_colorimetry colorimetry; enum hdmi_colorimetry colorimetry;
enum hdmi_picture_aspect picture_aspect; enum hdmi_picture_aspect picture_aspect;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment