summaryrefslogtreecommitdiffstats
path: root/drivers/media/video/cx18/cx18-queue.c
diff options
context:
space:
mode:
authorAndy Walls <awalls@radix.net>2008-12-14 22:52:12 +0100
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-12-30 12:39:07 +0100
commit0ef0289264e8f278312909f1639a7764cc9cf580 (patch)
tree8727d4d5d7519db50e8cd77e03b0d00892d35d76 /drivers/media/video/cx18/cx18-queue.c
parentV4L/DVB (9889): CX24113: Fixed more typos (diff)
downloadlinux-0ef0289264e8f278312909f1639a7764cc9cf580.tar.xz
linux-0ef0289264e8f278312909f1639a7764cc9cf580.zip
V4L/DVB (9891): cx18 Replace magic number 63 with CX18_MAX_FW_MDLS_PER_STREAM
Removed magic number that referred to firmware limit on the number of MDLs the firmware can maintain for any stream at any one time. Signed-off-by: Andy Walls <awalls@radix.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/cx18/cx18-queue.c')
-rw-r--r--drivers/media/video/cx18/cx18-queue.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/media/video/cx18/cx18-queue.c b/drivers/media/video/cx18/cx18-queue.c
index a6b0666f0ba3..2c58b0c478c0 100644
--- a/drivers/media/video/cx18/cx18-queue.c
+++ b/drivers/media/video/cx18/cx18-queue.c
@@ -55,8 +55,9 @@ struct cx18_queue *_cx18_enqueue(struct cx18_stream *s, struct cx18_buffer *buf,
mutex_lock(&s->qlock);
- /* q_busy is restricted to 63 buffers to stay within firmware limits */
- if (q == &s->q_busy && atomic_read(&q->buffers) >= 63)
+ /* q_busy is restricted to a max buffer count imposed by firmware */
+ if (q == &s->q_busy &&
+ atomic_read(&q->buffers) >= CX18_MAX_FW_MDLS_PER_STREAM)
q = &s->q_free;
if (to_front)