• Du Xing's avatar
    USB: usb-skeleton.c: fix blocked forever in skel_read · c79041a4
    Du Xing authored
    In skel_read,the reader blocked in wait_for_completion before submit
    bulk in urb.
    Using processed_urb is for retaining the completion in the case that
    previous interruptible wait in skel_read was interrupted and complete
    before next skel_read.  Replacing completion with waitqueue can avoid
    working around the counting nature of completions
    and fix the bug.
    
    Signed-off-by: Du Xing duxing2007@gmail.com
    Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    c79041a4
usb-skeleton.c 15.9 KB