Responding to my own e-mail here, but I just realized one little thing. >Pawel Osciak <p.osciak@xxxxxxxxxxx> wrote: [snip] >+void videobuf_buf_finish(struct videobuf_queue *q, struct videobuf_buffer *vb) >+{ >+ unsigned long flags; >+ >+ spin_lock_irqsave(&q->vb_done_lock, flags); >+ list_add_tail(&vb->done_list, &q->vb_done_list); >+ spin_unlock_irqrestore(&q->vb_done_lock, flags); >+ >+ spin_lock_irqsave(q->irqlock, flags); >+ wake_up(&vb->done); >+ wake_up_interruptible(&q->vb_done_wait); >+ spin_unlock_irqrestore(q->irqlock, flags); >+} >+EXPORT_SYMBOL_GPL(videobuf_buf_finish); There is a slight problem here if this function is not called from an interrupt context (which is the case usually though). irqlock is not held for a period of time and vb could potentially become NULL. So a recheck against vb == NULL is required; alternatively the function could be called by driver while holding the irqlock the whole time. So not really a problem, just a thing to point out. Best regards -- Pawel Osciak Linux Platform Group Samsung Poland R&D Center -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html