• Ming Qian's avatar
    avcodec/v4l2_m2m: handle v4l2 end of stream event · 8ac8e905
    Ming Qian authored
    When flushing the capture buffers, the driver may send a V4L2_EVENT_EOS
    to notify that draining is completed. Currently, v4l2_m2m does not
    subscribe to this event, which can cause some devices (i.e. imx8qm) to
    hang at the end of encoding/decoding. Support for handling the event is
    added in this commit.
    
    Some devices may not signal V4L2_EVENT_EOS. This is logged as a warning
    message during initialization and not treated as a fatal error.
    Signed-off-by: 's avatarMing Qian <ming.qian@nxp.com>
    Signed-off-by: 's avatarAndriy Gelman <andriy.gelman@gmail.com>
    8ac8e905
v4l2_m2m_enc.c 12.9 KB