Am 14.01.2014 17:44, schrieb Mauro Carvalho Chehab:
> As a pending action might be still there at the work
> thread, flush it.
>
> Signed-off-by: Mauro Carvalho Chehab <m.che...@samsung.com>
> ---
>  drivers/media/usb/em28xx/em28xx-audio.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/drivers/media/usb/em28xx/em28xx-audio.c 
> b/drivers/media/usb/em28xx/em28xx-audio.c
> index 74575e0ed41b..1563f71a5ea2 100644
> --- a/drivers/media/usb/em28xx/em28xx-audio.c
> +++ b/drivers/media/usb/em28xx/em28xx-audio.c
> @@ -967,6 +967,8 @@ static int em28xx_audio_fini(struct em28xx *dev)
>       em28xx_info("Closing audio extension");
>  
>       snd_card_disconnect(dev->adev.sndcard);
> +     flush_work(&dev->wq_trigger);
> +
>       em28xx_audio_free_urb(dev);
>  
>       if (dev->adev.sndcard) {
audio_trigger() doesn't re-schedule the work and flush_work() waits
until the current work is finished.

No, wait ! You are calling flush_work here for synchronization, right ?
That makes sense, but you should update the patch description. ;)


--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to