diff --git a/sys/external/bsd/drm2/include/linux/hdmi.h b/sys/external/bsd/drm2/include/linux/hdmi.h index 122afd12bcce..c4b003ce1972 100644 --- a/sys/external/bsd/drm2/include/linux/hdmi.h +++ b/sys/external/bsd/drm2/include/linux/hdmi.h @@ -1,4 +1,4 @@ -/* $NetBSD: hdmi.h,v 1.3 2014/11/23 16:07:10 riastradh Exp $ */ +/* $NetBSD: hdmi.h,v 1.4 2014/11/23 16:16:29 riastradh Exp $ */ /*- * Copyright (c) 2014 The NetBSD Foundation, Inc. @@ -203,7 +203,7 @@ hdmi_infoframe_header_pack(const struct hdmi_infoframe_header *header, p[0] = header->type; p[1] = header->version; - p[2] = length; + p[2] = (length - HDMI_INFOFRAME_HEADER_SIZE); p[3] = 0; /* checksum */ return HDMI_INFOFRAME_HEADER_SIZE; @@ -260,8 +260,7 @@ hdmi_audio_infoframe_pack(const struct hdmi_audio_infoframe *frame, void *buf, KASSERT(frame->header.length == HDMI_AUDIO_INFOFRAME_SIZE); - ret = hdmi_infoframe_header_pack(&frame->header, frame->header.length, - p, size); + ret = hdmi_infoframe_header_pack(&frame->header, length, p, size); if (ret < 0) return ret; KASSERT(ret == HDMI_INFOFRAME_HEADER_SIZE); @@ -337,8 +336,7 @@ hdmi_avi_infoframe_pack(const struct hdmi_avi_infoframe *frame, void *buf, KASSERT(frame->header.length == HDMI_AVI_INFOFRAME_SIZE); - ret = hdmi_infoframe_header_pack(&frame->header, frame->header.length, - p, size); + ret = hdmi_infoframe_header_pack(&frame->header, length, p, size); if (ret < 0) return ret; KASSERT(ret == HDMI_INFOFRAME_HEADER_SIZE); @@ -428,8 +426,7 @@ hdmi_spd_infoframe_pack(struct hdmi_spd_infoframe *frame, void *buf, KASSERT(frame->header.length == HDMI_SPD_INFOFRAME_SIZE); - ret = hdmi_infoframe_header_pack(&frame->header, frame->header.length, - p, size); + ret = hdmi_infoframe_header_pack(&frame->header, length, p, size); if (ret < 0) return ret; KASSERT(ret == HDMI_INFOFRAME_HEADER_SIZE); @@ -496,8 +493,7 @@ hdmi_vendor_infoframe_pack(const struct hdmi_vendor_infoframe *frame, if (frame->s3d_struct >= HDMI_3D_STRUCTURE_SIDE_BY_SIDE_HALF) length += 1; - ret = hdmi_infoframe_header_pack(&frame->header, frame->header.length, - p, size); + ret = hdmi_infoframe_header_pack(&frame->header, length, p, size); if (ret < 0) return ret; KASSERT(ret == HDMI_INFOFRAME_HEADER_SIZE);