Commit adfcf2e9 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab

media: fsl-viu: mark static functions as such

There are several functions that are used only inside the
driver. Stop exposing that to global symbolspace.

Get rid of the following gcc warnings:

drivers/media/platform/fsl-viu.c:240:17: warning: no previous prototype for ‘format_by_fourcc’ [-Wmissing-prototypes]
 struct viu_fmt *format_by_fourcc(int fourcc)
                 ^~~~~~~~~~~~~~~~
drivers/media/platform/fsl-viu.c:253:6: warning: no previous prototype for ‘viu_start_dma’ [-Wmissing-prototypes]
 void viu_start_dma(struct viu_dev *dev)
      ^~~~~~~~~~~~~
drivers/media/platform/fsl-viu.c:262:6: warning: no previous prototype for ‘viu_stop_dma’ [-Wmissing-prototypes]
 void viu_stop_dma(struct viu_dev *dev)
      ^~~~~~~~~~~~
drivers/media/platform/fsl-viu.c:807:5: warning: no previous prototype for ‘vidioc_g_fbuf’ [-Wmissing-prototypes]
 int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg)
     ^~~~~~~~~~~~~
drivers/media/platform/fsl-viu.c:818:5: warning: no previous prototype for ‘vidioc_s_fbuf’ [-Wmissing-prototypes]
 int vidioc_s_fbuf(struct file *file, void *priv, const struct v4l2_framebuffer *arg)
     ^~~~~~~~~~~~~
drivers/media/platform/fsl-viu.c: In function ‘viu_open’:
drivers/media/platform/fsl-viu.c:1170:6: warning: variable ‘status_cfg’ set but not used [-Wunused-but-set-variable]
  u32 status_cfg;
      ^~~~~~~~~~
drivers/media/platform/fsl-viu.c: At top level:
drivers/media/platform/fsl-viu.c:1304:6: warning: no previous prototype for ‘viu_reset’ [-Wmissing-prototypes]
 void viu_reset(struct viu_reg *reg)
      ^~~~~~~~~
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
parent 3f4836be
...@@ -229,7 +229,7 @@ enum status_config { ...@@ -229,7 +229,7 @@ enum status_config {
static irqreturn_t viu_intr(int irq, void *dev_id); static irqreturn_t viu_intr(int irq, void *dev_id);
struct viu_fmt *format_by_fourcc(int fourcc) static struct viu_fmt *format_by_fourcc(int fourcc)
{ {
int i; int i;
...@@ -242,7 +242,7 @@ struct viu_fmt *format_by_fourcc(int fourcc) ...@@ -242,7 +242,7 @@ struct viu_fmt *format_by_fourcc(int fourcc)
return NULL; return NULL;
} }
void viu_start_dma(struct viu_dev *dev) static void viu_start_dma(struct viu_dev *dev)
{ {
struct viu_reg *vr = dev->vr; struct viu_reg *vr = dev->vr;
...@@ -253,7 +253,7 @@ void viu_start_dma(struct viu_dev *dev) ...@@ -253,7 +253,7 @@ void viu_start_dma(struct viu_dev *dev)
out_be32(&vr->status_cfg, INT_FIELD_EN); out_be32(&vr->status_cfg, INT_FIELD_EN);
} }
void viu_stop_dma(struct viu_dev *dev) static void viu_stop_dma(struct viu_dev *dev)
{ {
struct viu_reg *vr = dev->vr; struct viu_reg *vr = dev->vr;
int cnt = 100; int cnt = 100;
...@@ -802,7 +802,7 @@ static int vidioc_overlay(struct file *file, void *priv, unsigned int on) ...@@ -802,7 +802,7 @@ static int vidioc_overlay(struct file *file, void *priv, unsigned int on)
return 0; return 0;
} }
int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg) static int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg)
{ {
struct viu_fh *fh = priv; struct viu_fh *fh = priv;
struct viu_dev *dev = fh->dev; struct viu_dev *dev = fh->dev;
...@@ -813,7 +813,7 @@ int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg) ...@@ -813,7 +813,7 @@ int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg)
return 0; return 0;
} }
int vidioc_s_fbuf(struct file *file, void *priv, const struct v4l2_framebuffer *arg) static int vidioc_s_fbuf(struct file *file, void *priv, const struct v4l2_framebuffer *arg)
{ {
struct viu_fh *fh = priv; struct viu_fh *fh = priv;
struct viu_dev *dev = fh->dev; struct viu_dev *dev = fh->dev;
...@@ -1305,7 +1305,7 @@ static int viu_release(struct file *file) ...@@ -1305,7 +1305,7 @@ static int viu_release(struct file *file)
return 0; return 0;
} }
void viu_reset(struct viu_reg *reg) static void viu_reset(struct viu_reg *reg)
{ {
out_be32(&reg->status_cfg, 0); out_be32(&reg->status_cfg, 0);
out_be32(&reg->luminance, 0x9512a254); out_be32(&reg->luminance, 0x9512a254);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment