From mboxrd@z Thu Jan 1 00:00:00 1970 From: Simon Farnsworth Subject: Re: [PATCH 11/12] drm: Add a helper to forge HDMI vendor infoframes Date: Wed, 14 Aug 2013 10:42:18 +0100 Message-ID: <4815916.keqQaQK69m@f17simon> References: <1376435848-14584-1-git-send-email-damien.lespiau@intel.com> <1376435848-14584-12-git-send-email-damien.lespiau@intel.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0133543107==" Return-path: In-Reply-To: <1376435848-14584-12-git-send-email-damien.lespiau@intel.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org To: dri-devel@lists.freedesktop.org Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org --===============0133543107== Content-Type: multipart/signed; boundary="nextPart3219132.jsNZGA4aCd"; micalg="pgp-sha1"; protocol="application/pgp-signature" --nextPart3219132.jsNZGA4aCd Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" More typo fallout: On Wednesday 14 August 2013 00:17:27 Damien Lespiau wrote: > This can then be used by DRM drivers to setup their vendor infoframes. > > Signed-off-by: Damien Lespiau > --- > drivers/gpu/drm/drm_edid.c | 36 ++++++++++++++++++++++++++++++++++++ > include/drm/drm_edid.h | 4 ++++ > 2 files changed, 40 insertions(+) > > diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c > index 9a07a33..83e1202 100644 > --- a/drivers/gpu/drm/drm_edid.c > +++ b/drivers/gpu/drm/drm_edid.c > @@ -3262,3 +3262,39 @@ drm_hdmi_avi_infoframe_from_display_mode(struct hdmi_avi_infoframe *frame, > return 0; > } > EXPORT_SYMBOL(drm_hdmi_avi_infoframe_from_display_mode); > + > +/** > + * drm_hdmi_vendor_infoframe_from_display_mode() - fill an HDMI infoframe with > + * data from a DRM display mode > + * @frame: HDMI vendor infoframe > + * @mode: DRM display mode > + * > + * Note that there's is a need to send HDMI vendor infoframes only when using a > + * 4k or stereoscopic 3D mode. So when giving any other mode as input this > + * function will return -EINVAL, error that can be safely ignored. > + * > + * Returns 0 on success or a negative error code on failure. > + */ > +int > +drm_hdmi_vendor_infoframe_from_display_mode(struct hdmi_hdmi_infoframe *frame, > + const struct drm_display_mode *mode) > +{ > + int err; > + u8 vic; > + > + if (!frame || !mode) > + return -EINVAL; > + > + vic = drm_match_hmdi_mode(mode); ^^^^ Should be hdmi again. > + if (!vic) > + return -EINVAL; > + > + err = hdmi_hdmi_infoframe_init(frame); > + if (err < 0) > + return err; > + > + frame->vic = vic; > + > + return 0; > +} > +EXPORT_SYMBOL(drm_hdmi_vendor_infoframe_from_display_mode); -- Simon Farnsworth Software Engineer ONELAN Ltd http://www.onelan.com --nextPart3219132.jsNZGA4aCd Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. Content-Transfer-Encoding: 7Bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (GNU/Linux) iQEcBAABAgAGBQJSC1D6AAoJELb1E1yQPsc0RgYH/3p5fUB87/oXkgKzFvfhTjGz W1Oq6jrV9rElXl6ocywYh8YdaosjKtfLvQl7ySZ5HjFkdTKVpq2oUAzso37pEC6K lMbZjdhL/2tx5dwHfi2yNf1YW9VnzoP9MlhmBf0duPWCKnrw9YTIeqHGh4QoUNIb dK+YLgfCxkvMUlM3f/AIPf/elJhZJbDb3v1i2NxxAWklNz1DjygcPjR8Tw3Oeh59 ItgckWh/FNHWCUbaJj/KMnJyLy4Xk3huYAlkUCVo4srnRRbtaORlczA5X+Dge0Hl Md1Rpr2xwemWK694HgCH1AmKIPw1q4/utfVmtCchWvtK13plqW8ZdPVLi8HeP+Y= =0sT4 -----END PGP SIGNATURE----- --nextPart3219132.jsNZGA4aCd-- --===============0133543107== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/intel-gfx --===============0133543107==--