diff options
author | Tejun Heo <tj@kernel.org> | 2010-12-24 10:14:20 -0500 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2010-12-24 10:14:20 -0500 |
commit | 8c71778cbf2c8beaefaa2dee5478aa0622d96682 (patch) | |
tree | 706fbdc96f696454d96538834b0d459967232e91 /drivers/media/video/omap24xxcam.c | |
parent | 707bcf326bd50c875d82bd2e7c31dcfb92b7e813 (diff) |
media/video: don't use flush_scheduled_work()
This patch converts the remaining users of flush_scheduled_work() in
media/video.
* bttv-input.c and cx23885-input.c don't use workqueue at all. No
need to flush.
* Make omap24xxcam.c and saa7134-empress.c flush the used work
directly.
* In fd_defio.c, replace cancel_delayed_work() +
flush_scheduled_work() with cancel_delayed_work_sync(). While at
it, replace the deprecated cancel_rearming_delayed_work() with
cancel_delayed_work_sync().
Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/omap24xxcam.c')
-rw-r--r-- | drivers/media/video/omap24xxcam.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/media/video/omap24xxcam.c b/drivers/media/video/omap24xxcam.c index 378b094aff16..017552762902 100644 --- a/drivers/media/video/omap24xxcam.c +++ b/drivers/media/video/omap24xxcam.c | |||
@@ -1198,7 +1198,7 @@ static int vidioc_streamoff(struct file *file, void *fh, enum v4l2_buf_type i) | |||
1198 | 1198 | ||
1199 | atomic_inc(&cam->reset_disable); | 1199 | atomic_inc(&cam->reset_disable); |
1200 | 1200 | ||
1201 | flush_scheduled_work(); | 1201 | flush_work_sync(&cam->sensor_reset_work); |
1202 | 1202 | ||
1203 | rval = videobuf_streamoff(q); | 1203 | rval = videobuf_streamoff(q); |
1204 | if (!rval) { | 1204 | if (!rval) { |
@@ -1512,7 +1512,7 @@ static int omap24xxcam_release(struct file *file) | |||
1512 | 1512 | ||
1513 | atomic_inc(&cam->reset_disable); | 1513 | atomic_inc(&cam->reset_disable); |
1514 | 1514 | ||
1515 | flush_scheduled_work(); | 1515 | flush_work_sync(&cam->sensor_reset_work); |
1516 | 1516 | ||
1517 | /* stop streaming capture */ | 1517 | /* stop streaming capture */ |
1518 | videobuf_streamoff(&fh->vbq); | 1518 | videobuf_streamoff(&fh->vbq); |
@@ -1536,7 +1536,7 @@ static int omap24xxcam_release(struct file *file) | |||
1536 | * not be scheduled anymore since streaming is already | 1536 | * not be scheduled anymore since streaming is already |
1537 | * disabled.) | 1537 | * disabled.) |
1538 | */ | 1538 | */ |
1539 | flush_scheduled_work(); | 1539 | flush_work_sync(&cam->sensor_reset_work); |
1540 | 1540 | ||
1541 | mutex_lock(&cam->mutex); | 1541 | mutex_lock(&cam->mutex); |
1542 | if (atomic_dec_return(&cam->users) == 0) { | 1542 | if (atomic_dec_return(&cam->users) == 0) { |