summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/cx23885
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2008-09-04 08:33:43 +0200
committerHans Verkuil <hverkuil@xs4all.nl>2008-09-04 08:33:43 +0200
commit9b4cd8c0a62769d3c668e00f4202dfd57b66f765 (patch)
treeba3b5e8333f92d2319d32891d6e43ec6ef0b18e1 /linux/drivers/media/video/cx23885
parent2f41bc61c3b5864177690d7f88d36366c3a05c5c (diff)
downloadmediapointer-dvb-s2-9b4cd8c0a62769d3c668e00f4202dfd57b66f765.tar.gz
mediapointer-dvb-s2-9b4cd8c0a62769d3c668e00f4202dfd57b66f765.tar.bz2
v4l-dvb: fix assorted sparse warnings
From: Hans Verkuil <hverkuil@xs4all.nl> Fix sparse warnings. None are serious, but cutting down on these helps find future serious sparse warnings/errors. Redid the av7710.c patch based on a suggestion by Oliver Endriss. Priority: normal Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Diffstat (limited to 'linux/drivers/media/video/cx23885')
-rw-r--r--linux/drivers/media/video/cx23885/cx23885-417.c2
-rw-r--r--linux/drivers/media/video/cx23885/cx23885-vbi.c7
-rw-r--r--linux/drivers/media/video/cx23885/cx23885-video.c29
3 files changed, 17 insertions, 21 deletions
diff --git a/linux/drivers/media/video/cx23885/cx23885-417.c b/linux/drivers/media/video/cx23885/cx23885-417.c
index 4ac358dd1..25349f6b9 100644
--- a/linux/drivers/media/video/cx23885/cx23885-417.c
+++ b/linux/drivers/media/video/cx23885/cx23885-417.c
@@ -632,7 +632,7 @@ int mc417_memory_read(struct cx23885_dev *dev, u32 address, u32 *value)
/* ------------------------------------------------------------------ */
/* MPEG encoder API */
-char *cmd_to_str(int cmd)
+static char *cmd_to_str(int cmd)
{
switch (cmd) {
case CX2341X_ENC_PING_FW:
diff --git a/linux/drivers/media/video/cx23885/cx23885-vbi.c b/linux/drivers/media/video/cx23885/cx23885-vbi.c
index 0705b9223..4b65552b3 100644
--- a/linux/drivers/media/video/cx23885/cx23885-vbi.c
+++ b/linux/drivers/media/video/cx23885/cx23885-vbi.c
@@ -86,7 +86,9 @@ static int cx23885_start_vbi_dma(struct cx23885_dev *dev,
return 0;
}
-int cx23885_stop_vbi_dma(struct cx23885_dev *dev)
+#if 0
+/* not (yet) used */
+static int cx23885_stop_vbi_dma(struct cx23885_dev *dev)
{
/* stop dma */
cx_clear(VID_A_DMA_CTL, 0x00000022);
@@ -96,8 +98,9 @@ int cx23885_stop_vbi_dma(struct cx23885_dev *dev)
cx_clear(VID_A_INT_MSK, 0x00000022);
return 0;
}
+#endif
-int cx23885_restart_vbi_queue(struct cx23885_dev *dev,
+static int cx23885_restart_vbi_queue(struct cx23885_dev *dev,
struct cx23885_dmaqueue *q)
{
struct cx23885_buffer *buf;
diff --git a/linux/drivers/media/video/cx23885/cx23885-video.c b/linux/drivers/media/video/cx23885/cx23885-video.c
index fd82844bf..70333ee2b 100644
--- a/linux/drivers/media/video/cx23885/cx23885-video.c
+++ b/linux/drivers/media/video/cx23885/cx23885-video.c
@@ -276,7 +276,7 @@ static struct cx23885_ctrl cx23885_ctls[] = {
};
static const int CX23885_CTLS = ARRAY_SIZE(cx23885_ctls);
-const u32 cx23885_user_ctrls[] = {
+static const u32 cx23885_user_ctrls[] = {
V4L2_CID_USER_CLASS,
V4L2_CID_BRIGHTNESS,
V4L2_CID_CONTRAST,
@@ -289,14 +289,13 @@ const u32 cx23885_user_ctrls[] = {
V4L2_CID_AUDIO_MUTE,
0
};
-EXPORT_SYMBOL(cx23885_user_ctrls);
static const u32 *ctrl_classes[] = {
cx23885_user_ctrls,
NULL
};
-void cx23885_video_wakeup(struct cx23885_dev *dev,
+static void cx23885_video_wakeup(struct cx23885_dev *dev,
struct cx23885_dmaqueue *q, u32 count)
{
struct cx23885_buffer *buf;
@@ -331,7 +330,7 @@ void cx23885_video_wakeup(struct cx23885_dev *dev,
__func__, bc);
}
-int cx23885_set_tvnorm(struct cx23885_dev *dev, v4l2_std_id norm)
+static int cx23885_set_tvnorm(struct cx23885_dev *dev, v4l2_std_id norm)
{
dprintk(1, "%s(norm = 0x%08x) name: [%s]\n",
__func__,
@@ -349,7 +348,7 @@ int cx23885_set_tvnorm(struct cx23885_dev *dev, v4l2_std_id norm)
return 0;
}
-struct video_device *cx23885_vdev_init(struct cx23885_dev *dev,
+static struct video_device *cx23885_vdev_init(struct cx23885_dev *dev,
struct pci_dev *pci,
struct video_device *template,
char *type)
@@ -369,7 +368,7 @@ struct video_device *cx23885_vdev_init(struct cx23885_dev *dev,
return vfd;
}
-int cx23885_ctrl_query(struct v4l2_queryctrl *qctrl)
+static int cx23885_ctrl_query(struct v4l2_queryctrl *qctrl)
{
int i;
@@ -386,7 +385,6 @@ int cx23885_ctrl_query(struct v4l2_queryctrl *qctrl)
*qctrl = cx23885_ctls[i].v;
return 0;
}
-EXPORT_SYMBOL(cx23885_ctrl_query);
/* ------------------------------------------------------------------- */
/* resource management */
@@ -437,7 +435,7 @@ static void res_free(struct cx23885_dev *dev, struct cx23885_fh *fh,
mutex_unlock(&dev->lock);
}
-int cx23885_video_mux(struct cx23885_dev *dev, unsigned int input)
+static int cx23885_video_mux(struct cx23885_dev *dev, unsigned int input)
{
struct v4l2_routing route;
memset(&route, 0, sizeof(route));
@@ -462,10 +460,9 @@ int cx23885_video_mux(struct cx23885_dev *dev, unsigned int input)
return 0;
}
-EXPORT_SYMBOL(cx23885_video_mux);
/* ------------------------------------------------------------------ */
-int cx23885_set_scale(struct cx23885_dev *dev, unsigned int width,
+static int cx23885_set_scale(struct cx23885_dev *dev, unsigned int width,
unsigned int height, enum v4l2_field field)
{
dprintk(1, "%s()\n", __func__);
@@ -967,15 +964,14 @@ static int video_mmap(struct file *file, struct vm_area_struct *vma)
/* ------------------------------------------------------------------ */
/* VIDEO CTRL IOCTLS */
-int cx23885_get_control(struct cx23885_dev *dev, struct v4l2_control *ctl)
+static int cx23885_get_control(struct cx23885_dev *dev, struct v4l2_control *ctl)
{
dprintk(1, "%s() calling cx25840(VIDIOC_G_CTRL)\n", __func__);
cx23885_call_i2c_clients(&dev->i2c_bus[2], VIDIOC_G_CTRL, ctl);
return 0;
}
-EXPORT_SYMBOL(cx23885_get_control);
-int cx23885_set_control(struct cx23885_dev *dev, struct v4l2_control *ctl)
+static int cx23885_set_control(struct cx23885_dev *dev, struct v4l2_control *ctl)
{
dprintk(1, "%s() calling cx25840(VIDIOC_S_CTRL)"
" (disabled - no action)\n", __func__);
@@ -984,7 +980,6 @@ int cx23885_set_control(struct cx23885_dev *dev, struct v4l2_control *ctl)
#endif
return 0;
}
-EXPORT_SYMBOL(cx23885_set_control);
static void init_controls(struct cx23885_dev *dev)
{
@@ -1235,7 +1230,7 @@ static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *tvnorms)
return 0;
}
-int cx23885_enum_input(struct cx23885_dev *dev, struct v4l2_input *i)
+static int cx23885_enum_input(struct cx23885_dev *dev, struct v4l2_input *i)
{
static const char *iname[] = {
[CX23885_VMUX_COMPOSITE1] = "Composite1",
@@ -1268,7 +1263,6 @@ int cx23885_enum_input(struct cx23885_dev *dev, struct v4l2_input *i)
i->std = CX23885_NORMS;
return 0;
}
-EXPORT_SYMBOL(cx23885_enum_input);
static int vidioc_enum_input(struct file *file, void *priv,
struct v4l2_input *i)
@@ -1383,7 +1377,7 @@ static int vidioc_g_frequency(struct file *file, void *priv,
return 0;
}
-int cx23885_set_freq(struct cx23885_dev *dev, struct v4l2_frequency *f)
+static int cx23885_set_freq(struct cx23885_dev *dev, struct v4l2_frequency *f)
{
if (unlikely(UNSET == dev->tuner_type))
return -EINVAL;
@@ -1402,7 +1396,6 @@ int cx23885_set_freq(struct cx23885_dev *dev, struct v4l2_frequency *f)
return 0;
}
-EXPORT_SYMBOL(cx23885_set_freq);
static int vidioc_s_frequency(struct file *file, void *priv,
struct v4l2_frequency *f)