Skip to content

Commit 56c9389

Browse files
ndufresnegregkh
authored andcommitted
media: synopsys: hdmirx: Count dropped frames
[ Upstream commit 57c8d79 ] The sequence number communicate the lost frames to userspace. For this reason, it must be incremented even when a frame is skipped. This allows userspace such as GStreamer to report the loss. Fixes: 7b59b13 ("media: platform: synopsys: Add support for HDMI input driver") Signed-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com> Reviewed-by: Dmitry Osipenko <dmitry.osipenko@collabora.com> Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent faed83b commit 56c9389

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

drivers/media/platform/synopsys/hdmirx/snps_hdmirx.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1956,10 +1956,6 @@ static void dma_idle_int_handler(struct snps_hdmirx_dev *hdmirx_dev,
19561956
vb_done->field = V4L2_FIELD_NONE;
19571957

19581958
hdmirx_vb_done(stream, vb_done);
1959-
stream->sequence++;
1960-
if (stream->sequence == 30)
1961-
v4l2_dbg(1, debug, v4l2_dev,
1962-
"rcv frames\n");
19631959
}
19641960

19651961
stream->curr_buf = NULL;
@@ -1971,6 +1967,10 @@ static void dma_idle_int_handler(struct snps_hdmirx_dev *hdmirx_dev,
19711967
v4l2_dbg(3, debug, v4l2_dev,
19721968
"%s: next_buf NULL, skip vb_done\n", __func__);
19731969
}
1970+
1971+
stream->sequence++;
1972+
if (stream->sequence == 30)
1973+
v4l2_dbg(1, debug, v4l2_dev, "rcv frames\n");
19741974
}
19751975

19761976
DMA_IDLE_OUT:

0 commit comments

Comments
 (0)