]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commitdiff
V4L/DVB (7376): Improve compile-time type-checking in videobuf
authorGuennadi Liakhovetski <g.liakhovetski@pengutronix.de>
Tue, 22 Apr 2008 17:46:02 +0000 (14:46 -0300)
committerMauro Carvalho Chehab <mchehab@infradead.org>
Thu, 24 Apr 2008 17:07:51 +0000 (14:07 -0300)
Make the dev member of the struct videobuf_queue of type "struct device *"
to avoid future problems. Also change the prototype of the
videobuf_queue_core_init() function.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@pengutronix.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
drivers/media/video/videobuf-core.c
include/media/videobuf-core.h

index 5ea635fac2364eefdf7e77891994b594aec2acec..137a1ff4a149a061cd236d2fbe378a32ed10bc66 100644 (file)
@@ -120,7 +120,7 @@ int videobuf_iolock(struct videobuf_queue *q, struct videobuf_buffer *vb,
 
 void videobuf_queue_core_init(struct videobuf_queue *q,
                         struct videobuf_queue_ops *ops,
-                        void *dev,
+                        struct device *dev,
                         spinlock_t *irqlock,
                         enum v4l2_buf_type type,
                         enum v4l2_field field,
index 99033945cdee3790c45240ac0f43a2f61fdec749..fcdffdd6330492e56edc09ef306b4b5b2e985f80 100644 (file)
@@ -151,7 +151,7 @@ struct videobuf_qtype_ops {
 struct videobuf_queue {
        struct mutex               vb_lock;
        spinlock_t                 *irqlock;
-       void                       *dev; /* on pci, points to struct pci_dev */
+       struct device              *dev;
 
        enum v4l2_buf_type         type;
        unsigned int               inputs; /* for V4L2_BUF_FLAG_INPUT */
@@ -185,7 +185,7 @@ void *videobuf_alloc(struct videobuf_queue* q);
 
 void videobuf_queue_core_init(struct videobuf_queue *q,
                         struct videobuf_queue_ops *ops,
-                        void *dev,
+                        struct device *dev,
                         spinlock_t *irqlock,
                         enum v4l2_buf_type type,
                         enum v4l2_field field,