• Frank Schaefer's avatar
    [media] em28xx: refactor VBI data processing code in em28xx_urb_data_copy() · a4837015
    Frank Schaefer authored
    When a new frame header is detected in em28xx_urb_data_copy() and the data
    packet contains both, VBI data and video data, the prevoius VBI buffer doesn't
    get finished and is overwritten with the new VBI data.
    This bug is not triggered with isochronous USB transfers, because the data
    packetes are much smaller than the VBI data size.
    But when using USB bulk transfers, the whole data of an URB is treated as
    single packet, which is usually much larger then the VBI data size.
    Refactor the VBI data processing code to fix this bug, but also to simplify the
    code and make it similar to the video data processing code part (which allows
    further code abstraction/unification in the future).
    The changes have been tested with device "Hauppauge HVR-900".
    Signed-off-by: default avatarFrank Schäfer <fschaefer.oss@googlemail.com>
    Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
    a4837015
em28xx-video.c 59.7 KB