Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[media] v4l2: pass std by value to the write-only s_std ioctl

This ioctl is defined as IOW, so pass the argument by value instead of by
reference. I could have chosen to add const instead, but this is 1) easier
to handle in drivers and 2) consistent with the s_std subdev operation.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: Jonathan Corbet <corbet@lwn.net>
Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>

authored by

Hans Verkuil and committed by
Mauro Carvalho Chehab
314527ac 2f73c7c5

+165 -165
+2 -2
drivers/media/common/saa7146/saa7146_video.c
··· 832 832 } 833 833 */ 834 834 835 - static int vidioc_s_std(struct file *file, void *fh, v4l2_std_id *id) 835 + static int vidioc_s_std(struct file *file, void *fh, v4l2_std_id id) 836 836 { 837 837 struct saa7146_dev *dev = ((struct saa7146_fh *)fh)->dev; 838 838 struct saa7146_vv *vv = dev->vv_data; ··· 856 856 } 857 857 858 858 for (i = 0; i < dev->ext_vv_data->num_stds; i++) 859 - if (*id & dev->ext_vv_data->stds[i].id) 859 + if (id & dev->ext_vv_data->stds[i].id) 860 860 break; 861 861 if (i != dev->ext_vv_data->num_stds) { 862 862 vv->standard = &dev->ext_vv_data->stds[i];
+2 -2
drivers/media/parport/pms.c
··· 735 735 return 0; 736 736 } 737 737 738 - static int pms_s_std(struct file *file, void *fh, v4l2_std_id *std) 738 + static int pms_s_std(struct file *file, void *fh, v4l2_std_id std) 739 739 { 740 740 struct pms *dev = video_drvdata(file); 741 741 int ret = 0; 742 742 743 - dev->std = *std; 743 + dev->std = std; 744 744 if (dev->std & V4L2_STD_NTSC) { 745 745 pms_framerate(dev, 30); 746 746 pms_secamcross(dev, 0);
+3 -3
drivers/media/pci/bt8xx/bttv-driver.c
··· 1713 1713 } 1714 1714 } 1715 1715 1716 - static int bttv_s_std(struct file *file, void *priv, v4l2_std_id *id) 1716 + static int bttv_s_std(struct file *file, void *priv, v4l2_std_id id) 1717 1717 { 1718 1718 struct bttv_fh *fh = priv; 1719 1719 struct bttv *btv = fh->btv; ··· 1721 1721 int err = 0; 1722 1722 1723 1723 for (i = 0; i < BTTV_TVNORMS; i++) 1724 - if (*id & bttv_tvnorms[i].v4l2_id) 1724 + if (id & bttv_tvnorms[i].v4l2_id) 1725 1725 break; 1726 1726 if (i == BTTV_TVNORMS) { 1727 1727 err = -EINVAL; 1728 1728 goto err; 1729 1729 } 1730 1730 1731 - btv->std = *id; 1731 + btv->std = id; 1732 1732 set_tvnorm(btv, i); 1733 1733 1734 1734 err:
+1 -1
drivers/media/pci/cx18/cx18-driver.c
··· 1243 1243 in one place. */ 1244 1244 cx->std++; /* Force full standard initialization */ 1245 1245 std = (cx->tuner_std == V4L2_STD_ALL) ? V4L2_STD_NTSC_M : cx->tuner_std; 1246 - cx18_s_std(NULL, &fh, &std); 1246 + cx18_s_std(NULL, &fh, std); 1247 1247 cx18_s_frequency(NULL, &fh, &vf); 1248 1248 return 0; 1249 1249 }
+5 -5
drivers/media/pci/cx18/cx18-ioctl.c
··· 637 637 return 0; 638 638 } 639 639 640 - int cx18_s_std(struct file *file, void *fh, v4l2_std_id *std) 640 + int cx18_s_std(struct file *file, void *fh, v4l2_std_id std) 641 641 { 642 642 struct cx18_open_id *id = fh2id(fh); 643 643 struct cx18 *cx = id->cx; 644 644 645 - if ((*std & V4L2_STD_ALL) == 0) 645 + if ((std & V4L2_STD_ALL) == 0) 646 646 return -EINVAL; 647 647 648 - if (*std == cx->std) 648 + if (std == cx->std) 649 649 return 0; 650 650 651 651 if (test_bit(CX18_F_I_RADIO_USER, &cx->i_flags) || ··· 656 656 return -EBUSY; 657 657 } 658 658 659 - cx->std = *std; 660 - cx->is_60hz = (*std & V4L2_STD_525_60) ? 1 : 0; 659 + cx->std = std; 660 + cx->is_60hz = (std & V4L2_STD_525_60) ? 1 : 0; 661 661 cx->is_50hz = !cx->is_60hz; 662 662 cx2341x_handler_set_50hz(&cx->cxhdl, cx->is_50hz); 663 663 cx->cxhdl.width = 720;
+1 -1
drivers/media/pci/cx18/cx18-ioctl.h
··· 26 26 void cx18_expand_service_set(struct v4l2_sliced_vbi_format *fmt, int is_pal); 27 27 u16 cx18_get_service_set(struct v4l2_sliced_vbi_format *fmt); 28 28 void cx18_set_funcs(struct video_device *vdev); 29 - int cx18_s_std(struct file *file, void *fh, v4l2_std_id *std); 29 + int cx18_s_std(struct file *file, void *fh, v4l2_std_id std); 30 30 int cx18_s_frequency(struct file *file, void *fh, const struct v4l2_frequency *vf); 31 31 int cx18_s_input(struct file *file, void *fh, unsigned int inp);
+3 -3
drivers/media/pci/cx23885/cx23885-417.c
··· 1222 1222 return 0; 1223 1223 } 1224 1224 1225 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *id) 1225 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id id) 1226 1226 { 1227 1227 struct cx23885_fh *fh = file->private_data; 1228 1228 struct cx23885_dev *dev = fh->dev; 1229 1229 unsigned int i; 1230 1230 1231 1231 for (i = 0; i < ARRAY_SIZE(cx23885_tvnorms); i++) 1232 - if (*id & cx23885_tvnorms[i].id) 1232 + if (id & cx23885_tvnorms[i].id) 1233 1233 break; 1234 1234 if (i == ARRAY_SIZE(cx23885_tvnorms)) 1235 1235 return -EINVAL; ··· 1237 1237 1238 1238 /* Have the drier core notify the subdevices */ 1239 1239 mutex_lock(&dev->lock); 1240 - cx23885_set_tvnorm(dev, *id); 1240 + cx23885_set_tvnorm(dev, id); 1241 1241 mutex_unlock(&dev->lock); 1242 1242 1243 1243 return 0;
+2 -2
drivers/media/pci/cx23885/cx23885-video.c
··· 1259 1259 return 0; 1260 1260 } 1261 1261 1262 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *tvnorms) 1262 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id tvnorms) 1263 1263 { 1264 1264 struct cx23885_dev *dev = ((struct cx23885_fh *)priv)->dev; 1265 1265 dprintk(1, "%s()\n", __func__); 1266 1266 1267 1267 mutex_lock(&dev->lock); 1268 - cx23885_set_tvnorm(dev, *tvnorms); 1268 + cx23885_set_tvnorm(dev, tvnorms); 1269 1269 mutex_unlock(&dev->lock); 1270 1270 1271 1271 return 0;
+3 -3
drivers/media/pci/cx25821/cx25821-video.c
··· 1203 1203 } 1204 1204 1205 1205 #ifdef TUNER_FLAG 1206 - int cx25821_vidioc_s_std(struct file *file, void *priv, v4l2_std_id * tvnorms) 1206 + int cx25821_vidioc_s_std(struct file *file, void *priv, v4l2_std_id tvnorms) 1207 1207 { 1208 1208 struct cx25821_fh *fh = priv; 1209 1209 struct cx25821_dev *dev = ((struct cx25821_fh *)priv)->dev; ··· 1218 1218 return err; 1219 1219 } 1220 1220 1221 - if (dev->tvnorm == *tvnorms) 1221 + if (dev->tvnorm == tvnorms) 1222 1222 return 0; 1223 1223 1224 1224 mutex_lock(&dev->lock); 1225 - cx25821_set_tvnorm(dev, *tvnorms); 1225 + cx25821_set_tvnorm(dev, tvnorms); 1226 1226 mutex_unlock(&dev->lock); 1227 1227 1228 1228 medusa_set_videostandard(dev);
+1 -1
drivers/media/pci/cx25821/cx25821-video.h
··· 135 135 extern int cx25821_vidioc_qbuf(struct file *file, void *priv, 136 136 struct v4l2_buffer *p); 137 137 extern int cx25821_vidioc_s_std(struct file *file, void *priv, 138 - v4l2_std_id *tvnorms); 138 + v4l2_std_id tvnorms); 139 139 extern int cx25821_enum_input(struct cx25821_dev *dev, struct v4l2_input *i); 140 140 extern int cx25821_vidioc_enum_input(struct file *file, void *priv, 141 141 struct v4l2_input *i);
+2 -2
drivers/media/pci/cx88/cx88-blackbird.c
··· 939 939 return 0; 940 940 } 941 941 942 - static int vidioc_s_std (struct file *file, void *priv, v4l2_std_id *id) 942 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id id) 943 943 { 944 944 struct cx88_core *core = ((struct cx8802_fh *)priv)->dev->core; 945 945 946 946 mutex_lock(&core->lock); 947 - cx88_set_tvnorm(core,*id); 947 + cx88_set_tvnorm(core, id); 948 948 mutex_unlock(&core->lock); 949 949 return 0; 950 950 }
+2 -2
drivers/media/pci/cx88/cx88-video.c
··· 1193 1193 return 0; 1194 1194 } 1195 1195 1196 - static int vidioc_s_std (struct file *file, void *priv, v4l2_std_id *tvnorms) 1196 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id tvnorms) 1197 1197 { 1198 1198 struct cx88_core *core = ((struct cx8800_fh *)priv)->dev->core; 1199 1199 1200 1200 mutex_lock(&core->lock); 1201 - cx88_set_tvnorm(core,*tvnorms); 1201 + cx88_set_tvnorm(core, tvnorms); 1202 1202 mutex_unlock(&core->lock); 1203 1203 1204 1204 return 0;
+2 -2
drivers/media/pci/ivtv/ivtv-driver.c
··· 1387 1387 if (!itv->has_cx23415) 1388 1388 write_reg_sync(0x03, IVTV_REG_DMACONTROL); 1389 1389 1390 - ivtv_s_std_enc(itv, &itv->tuner_std); 1390 + ivtv_s_std_enc(itv, itv->tuner_std); 1391 1391 1392 1392 /* Default interrupts enabled. For the PVR350 this includes the 1393 1393 decoder VSYNC interrupt, which is always on. It is not only used ··· 1397 1397 if (itv->v4l2_cap & V4L2_CAP_VIDEO_OUTPUT) { 1398 1398 ivtv_clear_irq_mask(itv, IVTV_IRQ_MASK_INIT | IVTV_IRQ_DEC_VSYNC); 1399 1399 ivtv_set_osd_alpha(itv); 1400 - ivtv_s_std_dec(itv, &itv->tuner_std); 1400 + ivtv_s_std_dec(itv, itv->tuner_std); 1401 1401 } else { 1402 1402 ivtv_clear_irq_mask(itv, IVTV_IRQ_MASK_INIT); 1403 1403 }
+2 -2
drivers/media/pci/ivtv/ivtv-firmware.c
··· 302 302 /* Restore encoder video standard */ 303 303 std = itv->std; 304 304 itv->std = 0; 305 - ivtv_s_std_enc(itv, &std); 305 + ivtv_s_std_enc(itv, std); 306 306 307 307 if (itv->v4l2_cap & V4L2_CAP_VIDEO_OUTPUT) { 308 308 ivtv_init_mpeg_decoder(itv); ··· 310 310 /* Restore decoder video standard */ 311 311 std = itv->std_out; 312 312 itv->std_out = 0; 313 - ivtv_s_std_dec(itv, &std); 313 + ivtv_s_std_dec(itv, std); 314 314 315 315 /* Restore framebuffer if active */ 316 316 if (itv->ivtvfb_restore)
+9 -9
drivers/media/pci/ivtv/ivtv-ioctl.c
··· 1103 1103 return 0; 1104 1104 } 1105 1105 1106 - void ivtv_s_std_enc(struct ivtv *itv, v4l2_std_id *std) 1106 + void ivtv_s_std_enc(struct ivtv *itv, v4l2_std_id std) 1107 1107 { 1108 - itv->std = *std; 1109 - itv->is_60hz = (*std & V4L2_STD_525_60) ? 1 : 0; 1108 + itv->std = std; 1109 + itv->is_60hz = (std & V4L2_STD_525_60) ? 1 : 0; 1110 1110 itv->is_50hz = !itv->is_60hz; 1111 1111 cx2341x_handler_set_50hz(&itv->cxhdl, itv->is_50hz); 1112 1112 itv->cxhdl.width = 720; ··· 1122 1122 ivtv_call_all(itv, core, s_std, itv->std); 1123 1123 } 1124 1124 1125 - void ivtv_s_std_dec(struct ivtv *itv, v4l2_std_id *std) 1125 + void ivtv_s_std_dec(struct ivtv *itv, v4l2_std_id std) 1126 1126 { 1127 1127 struct yuv_playback_info *yi = &itv->yuv_info; 1128 1128 DEFINE_WAIT(wait); 1129 1129 int f; 1130 1130 1131 1131 /* set display standard */ 1132 - itv->std_out = *std; 1133 - itv->is_out_60hz = (*std & V4L2_STD_525_60) ? 1 : 0; 1132 + itv->std_out = std; 1133 + itv->is_out_60hz = (std & V4L2_STD_525_60) ? 1 : 0; 1134 1134 itv->is_out_50hz = !itv->is_out_60hz; 1135 1135 ivtv_call_all(itv, video, s_std_output, itv->std_out); 1136 1136 ··· 1168 1168 } 1169 1169 } 1170 1170 1171 - static int ivtv_s_std(struct file *file, void *fh, v4l2_std_id *std) 1171 + static int ivtv_s_std(struct file *file, void *fh, v4l2_std_id std) 1172 1172 { 1173 1173 struct ivtv *itv = fh2id(fh)->itv; 1174 1174 1175 - if ((*std & V4L2_STD_ALL) == 0) 1175 + if ((std & V4L2_STD_ALL) == 0) 1176 1176 return -EINVAL; 1177 1177 1178 - if (*std == itv->std) 1178 + if (std == itv->std) 1179 1179 return 0; 1180 1180 1181 1181 if (test_bit(IVTV_F_I_RADIO_USER, &itv->i_flags) ||
+2 -2
drivers/media/pci/ivtv/ivtv-ioctl.h
··· 27 27 void ivtv_set_osd_alpha(struct ivtv *itv); 28 28 int ivtv_set_speed(struct ivtv *itv, int speed); 29 29 void ivtv_set_funcs(struct video_device *vdev); 30 - void ivtv_s_std_enc(struct ivtv *itv, v4l2_std_id *std); 31 - void ivtv_s_std_dec(struct ivtv *itv, v4l2_std_id *std); 30 + void ivtv_s_std_enc(struct ivtv *itv, v4l2_std_id std); 31 + void ivtv_s_std_dec(struct ivtv *itv, v4l2_std_id std); 32 32 int ivtv_s_frequency(struct file *file, void *fh, const struct v4l2_frequency *vf); 33 33 int ivtv_s_input(struct file *file, void *fh, unsigned int inp); 34 34
+1 -1
drivers/media/pci/saa7134/saa7134-empress.c
··· 428 428 return -EINVAL; 429 429 } 430 430 431 - static int empress_s_std(struct file *file, void *priv, v4l2_std_id *id) 431 + static int empress_s_std(struct file *file, void *priv, v4l2_std_id id) 432 432 { 433 433 struct saa7134_dev *dev = file->private_data; 434 434
+7 -7
drivers/media/pci/saa7134/saa7134-video.c
··· 1828 1828 return 0; 1829 1829 } 1830 1830 1831 - int saa7134_s_std_internal(struct saa7134_dev *dev, struct saa7134_fh *fh, v4l2_std_id *id) 1831 + int saa7134_s_std_internal(struct saa7134_dev *dev, struct saa7134_fh *fh, v4l2_std_id id) 1832 1832 { 1833 1833 unsigned long flags; 1834 1834 unsigned int i; ··· 1849 1849 } 1850 1850 1851 1851 for (i = 0; i < TVNORMS; i++) 1852 - if (*id == tvnorms[i].id) 1852 + if (id == tvnorms[i].id) 1853 1853 break; 1854 1854 1855 1855 if (i == TVNORMS) 1856 1856 for (i = 0; i < TVNORMS; i++) 1857 - if (*id & tvnorms[i].id) 1857 + if (id & tvnorms[i].id) 1858 1858 break; 1859 1859 if (i == TVNORMS) 1860 1860 return -EINVAL; 1861 1861 1862 - if ((*id & V4L2_STD_SECAM) && (secam[0] != '-')) { 1862 + if ((id & V4L2_STD_SECAM) && (secam[0] != '-')) { 1863 1863 if (secam[0] == 'L' || secam[0] == 'l') { 1864 1864 if (secam[1] == 'C' || secam[1] == 'c') 1865 1865 fixup = V4L2_STD_SECAM_LC; ··· 1879 1879 return -EINVAL; 1880 1880 } 1881 1881 1882 - *id = tvnorms[i].id; 1882 + id = tvnorms[i].id; 1883 1883 1884 1884 mutex_lock(&dev->lock); 1885 1885 if (fh && res_check(fh, RESOURCE_OVERLAY)) { ··· 1901 1901 } 1902 1902 EXPORT_SYMBOL_GPL(saa7134_s_std_internal); 1903 1903 1904 - static int saa7134_s_std(struct file *file, void *priv, v4l2_std_id *id) 1904 + static int saa7134_s_std(struct file *file, void *priv, v4l2_std_id id) 1905 1905 { 1906 1906 struct saa7134_fh *fh = priv; 1907 1907 ··· 2396 2396 return 0; 2397 2397 } 2398 2398 2399 - static int radio_s_std(struct file *file, void *fh, v4l2_std_id *norm) 2399 + static int radio_s_std(struct file *file, void *fh, v4l2_std_id norm) 2400 2400 { 2401 2401 return 0; 2402 2402 }
+1 -1
drivers/media/pci/saa7134/saa7134.h
··· 766 766 int saa7134_s_ctrl_internal(struct saa7134_dev *dev, struct saa7134_fh *fh, struct v4l2_control *c); 767 767 int saa7134_g_ctrl_internal(struct saa7134_dev *dev, struct saa7134_fh *fh, struct v4l2_control *c); 768 768 int saa7134_queryctrl(struct file *file, void *priv, struct v4l2_queryctrl *c); 769 - int saa7134_s_std_internal(struct saa7134_dev *dev, struct saa7134_fh *fh, v4l2_std_id *id); 769 + int saa7134_s_std_internal(struct saa7134_dev *dev, struct saa7134_fh *fh, v4l2_std_id id); 770 770 771 771 int saa7134_videoport_init(struct saa7134_dev *dev); 772 772 void saa7134_set_tvnorm_hw(struct saa7134_dev *dev);
+4 -4
drivers/media/pci/saa7164/saa7164-encoder.c
··· 211 211 } 212 212 213 213 /* -- V4L2 --------------------------------------------------------- */ 214 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *id) 214 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id id) 215 215 { 216 216 struct saa7164_encoder_fh *fh = file->private_data; 217 217 struct saa7164_port *port = fh->port; 218 218 struct saa7164_dev *dev = port->dev; 219 219 unsigned int i; 220 220 221 - dprintk(DBGLVL_ENC, "%s(id=0x%x)\n", __func__, (u32)*id); 221 + dprintk(DBGLVL_ENC, "%s(id=0x%x)\n", __func__, (u32)id); 222 222 223 223 for (i = 0; i < ARRAY_SIZE(saa7164_tvnorms); i++) { 224 - if (*id & saa7164_tvnorms[i].id) 224 + if (id & saa7164_tvnorms[i].id) 225 225 break; 226 226 } 227 227 if (i == ARRAY_SIZE(saa7164_tvnorms)) ··· 234 234 */ 235 235 saa7164_api_set_audio_std(port); 236 236 237 - dprintk(DBGLVL_ENC, "%s(id=0x%x) OK\n", __func__, (u32)*id); 237 + dprintk(DBGLVL_ENC, "%s(id=0x%x) OK\n", __func__, (u32)id); 238 238 239 239 return 0; 240 240 }
+4 -4
drivers/media/pci/saa7164/saa7164-vbi.c
··· 183 183 } 184 184 185 185 /* -- V4L2 --------------------------------------------------------- */ 186 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *id) 186 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id id) 187 187 { 188 188 struct saa7164_vbi_fh *fh = file->private_data; 189 189 struct saa7164_port *port = fh->port; 190 190 struct saa7164_dev *dev = port->dev; 191 191 unsigned int i; 192 192 193 - dprintk(DBGLVL_VBI, "%s(id=0x%x)\n", __func__, (u32)*id); 193 + dprintk(DBGLVL_VBI, "%s(id=0x%x)\n", __func__, (u32)id); 194 194 195 195 for (i = 0; i < ARRAY_SIZE(saa7164_tvnorms); i++) { 196 - if (*id & saa7164_tvnorms[i].id) 196 + if (id & saa7164_tvnorms[i].id) 197 197 break; 198 198 } 199 199 if (i == ARRAY_SIZE(saa7164_tvnorms)) ··· 206 206 */ 207 207 saa7164_api_set_audio_std(port); 208 208 209 - dprintk(DBGLVL_VBI, "%s(id=0x%x) OK\n", __func__, (u32)*id); 209 + dprintk(DBGLVL_VBI, "%s(id=0x%x) OK\n", __func__, (u32)id); 210 210 211 211 return 0; 212 212 }
+9 -9
drivers/media/pci/sta2x11/sta2x11_vip.c
··· 439 439 * 440 440 * other, returned from video DAC. 441 441 */ 442 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *std) 442 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id std) 443 443 { 444 444 struct sta2x11_vip *vip = video_drvdata(file); 445 445 v4l2_std_id oldstd = vip->std, newstd; 446 446 int status; 447 447 448 - if (V4L2_STD_ALL == *std) { 449 - v4l2_subdev_call(vip->decoder, core, s_std, *std); 448 + if (V4L2_STD_ALL == std) { 449 + v4l2_subdev_call(vip->decoder, core, s_std, std); 450 450 ssleep(2); 451 451 v4l2_subdev_call(vip->decoder, video, querystd, &newstd); 452 452 v4l2_subdev_call(vip->decoder, video, g_input_status, &status); 453 453 if (status & V4L2_IN_ST_NO_SIGNAL) 454 454 return -EIO; 455 - *std = vip->std = newstd; 456 - if (oldstd != *std) { 457 - if (V4L2_STD_525_60 & (*std)) 455 + std = vip->std = newstd; 456 + if (oldstd != std) { 457 + if (V4L2_STD_525_60 & std) 458 458 vip->format = formats_60[0]; 459 459 else 460 460 vip->format = formats_50[0]; ··· 462 462 return 0; 463 463 } 464 464 465 - if (oldstd != *std) { 466 - if (V4L2_STD_525_60 & (*std)) 465 + if (oldstd != std) { 466 + if (V4L2_STD_525_60 & std) 467 467 vip->format = formats_60[0]; 468 468 else 469 469 vip->format = formats_50[0]; 470 470 } 471 471 472 - return v4l2_subdev_call(vip->decoder, core, s_std, *std); 472 + return v4l2_subdev_call(vip->decoder, core, s_std, std); 473 473 } 474 474 475 475 /**
+2 -2
drivers/media/pci/zoran/zoran_driver.c
··· 2435 2435 return 0; 2436 2436 } 2437 2437 2438 - static int zoran_s_std(struct file *file, void *__fh, v4l2_std_id *std) 2438 + static int zoran_s_std(struct file *file, void *__fh, v4l2_std_id std) 2439 2439 { 2440 2440 struct zoran_fh *fh = __fh; 2441 2441 struct zoran *zr = fh->zr; 2442 2442 int res = 0; 2443 2443 2444 2444 mutex_lock(&zr->resource_lock); 2445 - res = zoran_set_norm(zr, *std); 2445 + res = zoran_set_norm(zr, std); 2446 2446 if (res) 2447 2447 goto sstd_unlock_and_return; 2448 2448
+3 -3
drivers/media/platform/blackfin/bfin_capture.c
··· 633 633 return 0; 634 634 } 635 635 636 - static int bcap_s_std(struct file *file, void *priv, v4l2_std_id *std) 636 + static int bcap_s_std(struct file *file, void *priv, v4l2_std_id std) 637 637 { 638 638 struct bcap_device *bcap_dev = video_drvdata(file); 639 639 int ret; ··· 641 641 if (vb2_is_busy(&bcap_dev->buffer_queue)) 642 642 return -EBUSY; 643 643 644 - ret = v4l2_subdev_call(bcap_dev->sd, core, s_std, *std); 644 + ret = v4l2_subdev_call(bcap_dev->sd, core, s_std, std); 645 645 if (ret < 0) 646 646 return ret; 647 647 648 - bcap_dev->std = *std; 648 + bcap_dev->std = std; 649 649 return 0; 650 650 } 651 651
+4 -4
drivers/media/platform/davinci/vpbe.c
··· 431 431 * Sets the standard if supported by the current encoder. Return the status. 432 432 * 0 - success & -EINVAL on error 433 433 */ 434 - static int vpbe_s_std(struct vpbe_device *vpbe_dev, v4l2_std_id *std_id) 434 + static int vpbe_s_std(struct vpbe_device *vpbe_dev, v4l2_std_id std_id) 435 435 { 436 436 struct vpbe_config *cfg = vpbe_dev->cfg; 437 437 int out_index = vpbe_dev->current_out_index; ··· 442 442 V4L2_OUT_CAP_STD)) 443 443 return -EINVAL; 444 444 445 - ret = vpbe_get_std_info(vpbe_dev, *std_id); 445 + ret = vpbe_get_std_info(vpbe_dev, std_id); 446 446 if (ret) 447 447 return ret; 448 448 449 449 mutex_lock(&vpbe_dev->lock); 450 450 451 451 ret = v4l2_subdev_call(vpbe_dev->encoders[sd_index], video, 452 - s_std_output, *std_id); 452 + s_std_output, std_id); 453 453 /* set the lcd controller output for the given mode */ 454 454 if (!ret) { 455 455 struct osd_state *osd_device = vpbe_dev->osd_device; ··· 513 513 */ 514 514 if (preset_mode->timings_type & VPBE_ENC_STD) 515 515 return vpbe_s_std(vpbe_dev, 516 - &preset_mode->std_id); 516 + preset_mode->std_id); 517 517 if (preset_mode->timings_type & 518 518 VPBE_ENC_DV_TIMINGS) { 519 519 dv_timings =
+1 -1
drivers/media/platform/davinci/vpbe_display.c
··· 983 983 * 0 - success & -EINVAL on error 984 984 */ 985 985 static int vpbe_display_s_std(struct file *file, void *priv, 986 - v4l2_std_id *std_id) 986 + v4l2_std_id std_id) 987 987 { 988 988 struct vpbe_fh *fh = priv; 989 989 struct vpbe_layer *layer = fh->layer;
+6 -6
drivers/media/platform/davinci/vpfe_capture.c
··· 376 376 * values in ccdc 377 377 */ 378 378 static int vpfe_config_image_format(struct vpfe_device *vpfe_dev, 379 - const v4l2_std_id *std_id) 379 + v4l2_std_id std_id) 380 380 { 381 381 struct vpfe_subdev_info *sdinfo = vpfe_dev->current_subdev; 382 382 struct v4l2_mbus_framefmt mbus_fmt; ··· 384 384 int i, ret = 0; 385 385 386 386 for (i = 0; i < ARRAY_SIZE(vpfe_standards); i++) { 387 - if (vpfe_standards[i].std_id & *std_id) { 387 + if (vpfe_standards[i].std_id & std_id) { 388 388 vpfe_dev->std_info.active_pixels = 389 389 vpfe_standards[i].width; 390 390 vpfe_dev->std_info.active_lines = ··· 461 461 462 462 /* Configure the default format information */ 463 463 ret = vpfe_config_image_format(vpfe_dev, 464 - &vpfe_standards[vpfe_dev->std_index].std_id); 464 + vpfe_standards[vpfe_dev->std_index].std_id); 465 465 if (ret) 466 466 return ret; 467 467 ··· 1168 1168 1169 1169 /* set the default image parameters in the device */ 1170 1170 ret = vpfe_config_image_format(vpfe_dev, 1171 - &vpfe_standards[vpfe_dev->std_index].std_id); 1171 + vpfe_standards[vpfe_dev->std_index].std_id); 1172 1172 unlock_out: 1173 1173 mutex_unlock(&vpfe_dev->lock); 1174 1174 return ret; ··· 1193 1193 return ret; 1194 1194 } 1195 1195 1196 - static int vpfe_s_std(struct file *file, void *priv, v4l2_std_id *std_id) 1196 + static int vpfe_s_std(struct file *file, void *priv, v4l2_std_id std_id) 1197 1197 { 1198 1198 struct vpfe_device *vpfe_dev = video_drvdata(file); 1199 1199 struct vpfe_subdev_info *sdinfo; ··· 1215 1215 } 1216 1216 1217 1217 ret = v4l2_device_call_until_err(&vpfe_dev->v4l2_dev, sdinfo->grp_id, 1218 - core, s_std, *std_id); 1218 + core, s_std, std_id); 1219 1219 if (ret < 0) { 1220 1220 v4l2_err(&vpfe_dev->v4l2_dev, "Failed to set standard\n"); 1221 1221 goto unlock_out;
+3 -3
drivers/media/platform/davinci/vpif_capture.c
··· 1395 1395 * @priv: file handle 1396 1396 * @std_id: ptr to std id 1397 1397 */ 1398 - static int vpif_s_std(struct file *file, void *priv, v4l2_std_id *std_id) 1398 + static int vpif_s_std(struct file *file, void *priv, v4l2_std_id std_id) 1399 1399 { 1400 1400 struct vpif_fh *fh = priv; 1401 1401 struct channel_obj *ch = fh->channel; ··· 1424 1424 fh->initialized = 1; 1425 1425 1426 1426 /* Call encoder subdevice function to set the standard */ 1427 - ch->video.stdid = *std_id; 1427 + ch->video.stdid = std_id; 1428 1428 memset(&ch->video.dv_timings, 0, sizeof(ch->video.dv_timings)); 1429 1429 1430 1430 /* Get the information about the standard */ ··· 1437 1437 vpif_config_format(ch); 1438 1438 1439 1439 /* set standard in the sub device */ 1440 - ret = v4l2_subdev_call(ch->sd, core, s_std, *std_id); 1440 + ret = v4l2_subdev_call(ch->sd, core, s_std, std_id); 1441 1441 if (ret && ret != -ENOIOCTLCMD && ret != -ENODEV) { 1442 1442 vpif_dbg(1, debug, "Failed to set standard for sub devices\n"); 1443 1443 return ret;
+5 -5
drivers/media/platform/davinci/vpif_display.c
··· 1059 1059 return vb2_qbuf(&common->buffer_queue, buf); 1060 1060 } 1061 1061 1062 - static int vpif_s_std(struct file *file, void *priv, v4l2_std_id *std_id) 1062 + static int vpif_s_std(struct file *file, void *priv, v4l2_std_id std_id) 1063 1063 { 1064 1064 struct vpif_fh *fh = priv; 1065 1065 struct channel_obj *ch = fh->channel; 1066 1066 struct common_obj *common = &ch->common[VPIF_VIDEO_INDEX]; 1067 1067 int ret = 0; 1068 1068 1069 - if (!(*std_id & VPIF_V4L2_STD)) 1069 + if (!(std_id & VPIF_V4L2_STD)) 1070 1070 return -EINVAL; 1071 1071 1072 1072 if (common->started) { ··· 1075 1075 } 1076 1076 1077 1077 /* Call encoder subdevice function to set the standard */ 1078 - ch->video.stdid = *std_id; 1078 + ch->video.stdid = std_id; 1079 1079 memset(&ch->video.dv_timings, 0, sizeof(ch->video.dv_timings)); 1080 1080 /* Get the information about the standard */ 1081 1081 if (vpif_update_resolution(ch)) ··· 1093 1093 vpif_config_format(ch); 1094 1094 1095 1095 ret = v4l2_device_call_until_err(&vpif_obj.v4l2_dev, 1, video, 1096 - s_std_output, *std_id); 1096 + s_std_output, std_id); 1097 1097 if (ret < 0) { 1098 1098 vpif_err("Failed to set output standard\n"); 1099 1099 return ret; 1100 1100 } 1101 1101 1102 1102 ret = v4l2_device_call_until_err(&vpif_obj.v4l2_dev, 1, core, 1103 - s_std, *std_id); 1103 + s_std, std_id); 1104 1104 if (ret < 0) 1105 1105 vpif_err("Failed to set standard for sub devices\n"); 1106 1106 return ret;
+3 -3
drivers/media/platform/fsl-viu.c
··· 957 957 return 0; 958 958 } 959 959 960 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *id) 960 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id id) 961 961 { 962 962 struct viu_fh *fh = priv; 963 963 964 - fh->dev->std = *id; 965 - decoder_call(fh->dev, core, s_std, *id); 964 + fh->dev->std = id; 965 + decoder_call(fh->dev, core, s_std, id); 966 966 return 0; 967 967 } 968 968
+1 -1
drivers/media/platform/marvell-ccic/mcam-core.c
··· 1357 1357 } 1358 1358 1359 1359 /* from vivi.c */ 1360 - static int mcam_vidioc_s_std(struct file *filp, void *priv, v4l2_std_id *a) 1360 + static int mcam_vidioc_s_std(struct file *filp, void *priv, v4l2_std_id a) 1361 1361 { 1362 1362 return 0; 1363 1363 }
+2 -2
drivers/media/platform/s5p-tv/mixer_video.c
··· 574 574 return ret ? -EINVAL : 0; 575 575 } 576 576 577 - static int mxr_s_std(struct file *file, void *fh, v4l2_std_id *norm) 577 + static int mxr_s_std(struct file *file, void *fh, v4l2_std_id norm) 578 578 { 579 579 struct mxr_layer *layer = video_drvdata(file); 580 580 struct mxr_device *mdev = layer->mdev; ··· 591 591 return -EBUSY; 592 592 } 593 593 594 - ret = v4l2_subdev_call(to_outsd(mdev), video, s_std_output, *norm); 594 + ret = v4l2_subdev_call(to_outsd(mdev), video, s_std_output, norm); 595 595 596 596 mutex_unlock(&mdev->mutex); 597 597
+6 -6
drivers/media/platform/sh_vou.c
··· 881 881 } 882 882 } 883 883 884 - static int sh_vou_s_std(struct file *file, void *priv, v4l2_std_id *std_id) 884 + static int sh_vou_s_std(struct file *file, void *priv, v4l2_std_id std_id) 885 885 { 886 886 struct sh_vou_device *vou_dev = video_drvdata(file); 887 887 int ret; 888 888 889 - dev_dbg(vou_dev->v4l2_dev.dev, "%s(): 0x%llx\n", __func__, *std_id); 889 + dev_dbg(vou_dev->v4l2_dev.dev, "%s(): 0x%llx\n", __func__, std_id); 890 890 891 - if (*std_id & ~vou_dev->vdev->tvnorms) 891 + if (std_id & ~vou_dev->vdev->tvnorms) 892 892 return -EINVAL; 893 893 894 894 ret = v4l2_device_call_until_err(&vou_dev->v4l2_dev, 0, video, 895 - s_std_output, *std_id); 895 + s_std_output, std_id); 896 896 /* Shall we continue, if the subdev doesn't support .s_std_output()? */ 897 897 if (ret < 0 && ret != -ENOIOCTLCMD) 898 898 return ret; 899 899 900 - if (*std_id & V4L2_STD_525_60) 900 + if (std_id & V4L2_STD_525_60) 901 901 sh_vou_reg_ab_set(vou_dev, VOUCR, 902 902 sh_vou_ntsc_mode(vou_dev->pdata->bus_fmt) << 29, 7 << 29); 903 903 else 904 904 sh_vou_reg_ab_set(vou_dev, VOUCR, 5 << 29, 7 << 29); 905 905 906 - vou_dev->std = *std_id; 906 + vou_dev->std = std_id; 907 907 908 908 return 0; 909 909 }
+2 -2
drivers/media/platform/soc_camera/soc_camera.c
··· 256 256 return 0; 257 257 } 258 258 259 - static int soc_camera_s_std(struct file *file, void *priv, v4l2_std_id *a) 259 + static int soc_camera_s_std(struct file *file, void *priv, v4l2_std_id a) 260 260 { 261 261 struct soc_camera_device *icd = file->private_data; 262 262 struct v4l2_subdev *sd = soc_camera_to_subdev(icd); 263 263 264 - return v4l2_subdev_call(sd, core, s_std, *a); 264 + return v4l2_subdev_call(sd, core, s_std, a); 265 265 } 266 266 267 267 static int soc_camera_g_std(struct file *file, void *priv, v4l2_std_id *a)
+3 -3
drivers/media/platform/timblogiw.c
··· 336 336 return 0; 337 337 } 338 338 339 - static int timblogiw_s_std(struct file *file, void *priv, v4l2_std_id *std) 339 + static int timblogiw_s_std(struct file *file, void *priv, v4l2_std_id std) 340 340 { 341 341 struct video_device *vdev = video_devdata(file); 342 342 struct timblogiw *lw = video_get_drvdata(vdev); ··· 348 348 mutex_lock(&lw->lock); 349 349 350 350 if (TIMBLOGIW_HAS_DECODER(lw)) 351 - err = v4l2_subdev_call(lw->sd_enc, core, s_std, *std); 351 + err = v4l2_subdev_call(lw->sd_enc, core, s_std, std); 352 352 353 353 if (!err) 354 - fh->cur_norm = timblogiw_get_norm(*std); 354 + fh->cur_norm = timblogiw_get_norm(std); 355 355 356 356 mutex_unlock(&lw->lock); 357 357
+1 -1
drivers/media/platform/via-camera.c
··· 847 847 return 0; 848 848 } 849 849 850 - static int viacam_s_std(struct file *filp, void *priv, v4l2_std_id *std) 850 + static int viacam_s_std(struct file *filp, void *priv, v4l2_std_id std) 851 851 { 852 852 return 0; 853 853 }
+5 -5
drivers/media/platform/vino.c
··· 3042 3042 } 3043 3043 3044 3044 static int vino_s_std(struct file *file, void *__fh, 3045 - v4l2_std_id *std) 3045 + v4l2_std_id std) 3046 3046 { 3047 3047 struct vino_channel_settings *vcs = video_drvdata(file); 3048 3048 unsigned long flags; ··· 3056 3056 } 3057 3057 3058 3058 /* check if the standard is valid for the current input */ 3059 - if ((*std) & vino_inputs[vcs->input].std) { 3059 + if (std & vino_inputs[vcs->input].std) { 3060 3060 dprintk("standard accepted\n"); 3061 3061 3062 3062 /* change the video norm for SAA7191 ··· 3065 3065 if (vcs->input == VINO_INPUT_D1) 3066 3066 goto out; 3067 3067 3068 - if ((*std) & V4L2_STD_PAL) { 3068 + if (std & V4L2_STD_PAL) { 3069 3069 ret = vino_set_data_norm(vcs, VINO_DATA_NORM_PAL, 3070 3070 &flags); 3071 - } else if ((*std) & V4L2_STD_NTSC) { 3071 + } else if (std & V4L2_STD_NTSC) { 3072 3072 ret = vino_set_data_norm(vcs, VINO_DATA_NORM_NTSC, 3073 3073 &flags); 3074 - } else if ((*std) & V4L2_STD_SECAM) { 3074 + } else if (std & V4L2_STD_SECAM) { 3075 3075 ret = vino_set_data_norm(vcs, VINO_DATA_NORM_SECAM, 3076 3076 &flags); 3077 3077 } else {
+2 -2
drivers/media/usb/au0828/au0828-video.c
··· 1320 1320 return rc; 1321 1321 } 1322 1322 1323 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id * norm) 1323 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id norm) 1324 1324 { 1325 1325 struct au0828_fh *fh = priv; 1326 1326 struct au0828_dev *dev = fh->dev; ··· 1332 1332 have to make the au0828 bridge adjust the size of its capture 1333 1333 buffer, which is currently hardcoded at 720x480 */ 1334 1334 1335 - v4l2_device_call_all(&dev->v4l2_dev, 0, core, s_std, *norm); 1335 + v4l2_device_call_all(&dev->v4l2_dev, 0, core, s_std, norm); 1336 1336 dev->std_set_in_tuner_core = 1; 1337 1337 1338 1338 if (dev->dvb.frontend && dev->dvb.frontend->ops.analog_ops.i2c_gate_ctrl)
+2 -2
drivers/media/usb/cx231xx/cx231xx-417.c
··· 1492 1492 return 0; 1493 1493 } 1494 1494 1495 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *id) 1495 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id id) 1496 1496 { 1497 1497 struct cx231xx_fh *fh = file->private_data; 1498 1498 struct cx231xx *dev = fh->dev; 1499 1499 unsigned int i; 1500 1500 1501 1501 for (i = 0; i < ARRAY_SIZE(cx231xx_tvnorms); i++) 1502 - if (*id & cx231xx_tvnorms[i].id) 1502 + if (id & cx231xx_tvnorms[i].id) 1503 1503 break; 1504 1504 if (i == ARRAY_SIZE(cx231xx_tvnorms)) 1505 1505 return -EINVAL;
+3 -3
drivers/media/usb/cx231xx/cx231xx-video.c
··· 987 987 return 0; 988 988 } 989 989 990 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *norm) 990 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id norm) 991 991 { 992 992 struct cx231xx_fh *fh = priv; 993 993 struct cx231xx *dev = fh->dev; ··· 998 998 if (rc < 0) 999 999 return rc; 1000 1000 1001 - if (dev->norm == *norm) 1001 + if (dev->norm == norm) 1002 1002 return 0; 1003 1003 1004 1004 if (videobuf_queue_is_busy(&fh->vb_vidq)) 1005 1005 return -EBUSY; 1006 1006 1007 - dev->norm = *norm; 1007 + dev->norm = norm; 1008 1008 1009 1009 /* Adjusts width/height, if needed */ 1010 1010 dev->width = 720;
+4 -4
drivers/media/usb/em28xx/em28xx-video.c
··· 996 996 return 0; 997 997 } 998 998 999 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *norm) 999 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id norm) 1000 1000 { 1001 1001 struct em28xx_fh *fh = priv; 1002 1002 struct em28xx *dev = fh->dev; 1003 1003 struct v4l2_format f; 1004 1004 1005 - if (*norm == dev->norm) 1005 + if (norm == dev->norm) 1006 1006 return 0; 1007 1007 1008 1008 if (dev->streaming_users > 0) 1009 1009 return -EBUSY; 1010 1010 1011 - dev->norm = *norm; 1011 + dev->norm = norm; 1012 1012 1013 1013 /* Adjusts width/height, if needed */ 1014 1014 f.fmt.pix.width = 720; 1015 - f.fmt.pix.height = (*norm & V4L2_STD_525_60) ? 480 : 576; 1015 + f.fmt.pix.height = (norm & V4L2_STD_525_60) ? 480 : 576; 1016 1016 vidioc_try_fmt_vid_cap(file, priv, &f); 1017 1017 1018 1018 /* set new image size */
+2 -2
drivers/media/usb/hdpvr/hdpvr-video.c
··· 582 582 } 583 583 584 584 static int vidioc_s_std(struct file *file, void *private_data, 585 - v4l2_std_id *std) 585 + v4l2_std_id std) 586 586 { 587 587 struct hdpvr_fh *fh = file->private_data; 588 588 struct hdpvr_device *dev = fh->dev; 589 589 u8 std_type = 1; 590 590 591 - if (*std & (V4L2_STD_NTSC | V4L2_STD_PAL_60)) 591 + if (std & (V4L2_STD_NTSC | V4L2_STD_PAL_60)) 592 592 std_type = 0; 593 593 594 594 return hdpvr_config_call(dev, CTRL_VIDEO_STD_TYPE, std_type);
+2 -2
drivers/media/usb/pvrusb2/pvrusb2-v4l2.c
··· 196 196 return ret; 197 197 } 198 198 199 - static int pvr2_s_std(struct file *file, void *priv, v4l2_std_id *std) 199 + static int pvr2_s_std(struct file *file, void *priv, v4l2_std_id std) 200 200 { 201 201 struct pvr2_v4l2_fh *fh = file->private_data; 202 202 struct pvr2_hdw *hdw = fh->channel.mc_head->hdw; 203 203 204 204 return pvr2_ctrl_set_value( 205 - pvr2_hdw_get_ctrl_by_id(hdw, PVR2_CID_STDCUR), *std); 205 + pvr2_hdw_get_ctrl_by_id(hdw, PVR2_CID_STDCUR), std); 206 206 } 207 207 208 208 static int pvr2_querystd(struct file *file, void *priv, v4l2_std_id *std)
+4 -4
drivers/media/usb/s2255/s2255drv.c
··· 1294 1294 return 0; 1295 1295 } 1296 1296 1297 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *i) 1297 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id i) 1298 1298 { 1299 1299 struct s2255_fh *fh = priv; 1300 1300 struct s2255_mode mode; ··· 1314 1314 goto out_s_std; 1315 1315 } 1316 1316 mode = fh->channel->mode; 1317 - if (*i & V4L2_STD_525_60) { 1317 + if (i & V4L2_STD_525_60) { 1318 1318 dprintk(4, "%s 60 Hz\n", __func__); 1319 1319 /* if changing format, reset frame decimation/intervals */ 1320 1320 if (mode.format != FORMAT_NTSC) { ··· 1324 1324 channel->width = LINE_SZ_4CIFS_NTSC; 1325 1325 channel->height = NUM_LINES_4CIFS_NTSC * 2; 1326 1326 } 1327 - } else if (*i & V4L2_STD_625_50) { 1327 + } else if (i & V4L2_STD_625_50) { 1328 1328 dprintk(4, "%s 50 Hz\n", __func__); 1329 1329 if (mode.format != FORMAT_PAL) { 1330 1330 mode.restart = 1; ··· 1337 1337 ret = -EINVAL; 1338 1338 goto out_s_std; 1339 1339 } 1340 - fh->channel->std = *i; 1340 + fh->channel->std = i; 1341 1341 if (mode.restart) 1342 1342 s2255_set_mode(fh->channel, &mode); 1343 1343 out_s_std:
+2 -2
drivers/media/usb/stk1160/stk1160-v4l.c
··· 375 375 return 0; 376 376 } 377 377 378 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *norm) 378 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id norm) 379 379 { 380 380 struct stk1160 *dev = video_drvdata(file); 381 381 struct vb2_queue *q = &dev->vb_vidq; ··· 388 388 return -ENODEV; 389 389 390 390 /* We need to set this now, before we call stk1160_set_std */ 391 - dev->norm = *norm; 391 + dev->norm = norm; 392 392 393 393 /* This is taken from saa7115 video decoder */ 394 394 if (dev->norm & V4L2_STD_525_60) {
+4 -4
drivers/media/usb/tlg2300/pd-video.c
··· 801 801 return 0; 802 802 } 803 803 804 - static int set_std(struct poseidon *pd, v4l2_std_id *norm) 804 + static int set_std(struct poseidon *pd, v4l2_std_id norm) 805 805 { 806 806 struct video_data *video = &pd->video_data; 807 807 struct vbi_data *vbi = &pd->vbi_data; ··· 811 811 int height; 812 812 813 813 for (i = 0; i < POSEIDON_TVNORMS; i++) { 814 - if (*norm & poseidon_tvnorms[i].v4l2_id) { 814 + if (norm & poseidon_tvnorms[i].v4l2_id) { 815 815 param = poseidon_tvnorms[i].tlg_tvnorm; 816 816 log("name : %s", poseidon_tvnorms[i].name); 817 817 goto found; ··· 846 846 return ret; 847 847 } 848 848 849 - static int vidioc_s_std(struct file *file, void *fh, v4l2_std_id *norm) 849 + static int vidioc_s_std(struct file *file, void *fh, v4l2_std_id norm) 850 850 { 851 851 struct front_face *front = fh; 852 852 ··· 1270 1270 1271 1271 pd_video_checkmode(pd); 1272 1272 1273 - set_std(pd, &context->tvnormid); 1273 + set_std(pd, context->tvnormid); 1274 1274 vidioc_s_input(NULL, front, context->sig_index); 1275 1275 pd_vidioc_s_tuner(pd, context->audio_idx); 1276 1276 pd_vidioc_s_fmt(pd, &context->pix);
+3 -3
drivers/media/usb/tm6000/tm6000-video.c
··· 1056 1056 return 0; 1057 1057 } 1058 1058 1059 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *norm) 1059 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id norm) 1060 1060 { 1061 1061 int rc = 0; 1062 1062 struct tm6000_fh *fh = priv; 1063 1063 struct tm6000_core *dev = fh->dev; 1064 1064 1065 - dev->norm = *norm; 1065 + dev->norm = norm; 1066 1066 rc = tm6000_init_analog_mode(dev); 1067 1067 1068 1068 fh->width = dev->width; ··· 1134 1134 1135 1135 dev->input = i; 1136 1136 1137 - rc = vidioc_s_std(file, priv, &dev->vfd->current_norm); 1137 + rc = vidioc_s_std(file, priv, dev->vfd->current_norm); 1138 1138 1139 1139 return rc; 1140 1140 }
+2 -2
drivers/media/usb/usbvision/usbvision-video.c
··· 595 595 return 0; 596 596 } 597 597 598 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *id) 598 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id id) 599 599 { 600 600 struct usb_usbvision *usbvision = video_drvdata(file); 601 601 602 - usbvision->tvnorm_id = *id; 602 + usbvision->tvnorm_id = id; 603 603 604 604 call_all(usbvision, core, s_std, usbvision->tvnorm_id); 605 605 /* propagate the change to the decoder */
+3 -3
drivers/media/v4l2-core/v4l2-ioctl.c
··· 1383 1383 struct file *file, void *fh, void *arg) 1384 1384 { 1385 1385 struct video_device *vfd = video_devdata(file); 1386 - v4l2_std_id *id = arg, norm; 1386 + v4l2_std_id id = *(v4l2_std_id *)arg, norm; 1387 1387 int ret; 1388 1388 1389 - norm = (*id) & vfd->tvnorms; 1389 + norm = id & vfd->tvnorms; 1390 1390 if (vfd->tvnorms && !norm) /* Check if std is supported */ 1391 1391 return -EINVAL; 1392 1392 1393 1393 /* Calls the specific handler */ 1394 - ret = ops->vidioc_s_std(file, fh, &norm); 1394 + ret = ops->vidioc_s_std(file, fh, norm); 1395 1395 1396 1396 /* Updates standard information */ 1397 1397 if (ret >= 0)
+3 -3
drivers/staging/media/davinci_vpfe/vpfe_video.c
··· 924 924 * 925 925 * Return 0 on success, error code otherwise 926 926 */ 927 - static int vpfe_s_std(struct file *file, void *priv, v4l2_std_id *std_id) 927 + static int vpfe_s_std(struct file *file, void *priv, v4l2_std_id std_id) 928 928 { 929 929 struct vpfe_video_device *video = video_drvdata(file); 930 930 struct vpfe_device *vpfe_dev = video->vpfe_dev; ··· 945 945 goto unlock_out; 946 946 } 947 947 ret = v4l2_device_call_until_err(&vpfe_dev->v4l2_dev, sdinfo->grp_id, 948 - core, s_std, *std_id); 948 + core, s_std, std_id); 949 949 if (ret < 0) { 950 950 v4l2_err(&vpfe_dev->v4l2_dev, "Failed to set standard\n"); 951 951 video->stdid = V4L2_STD_UNKNOWN; 952 952 goto unlock_out; 953 953 } 954 - video->stdid = *std_id; 954 + video->stdid = std_id; 955 955 unlock_out: 956 956 mutex_unlock(&video->lock); 957 957 return ret;
+2 -2
drivers/staging/media/dt3155v4l/dt3155v4l.c
··· 612 612 } 613 613 614 614 static int 615 - dt3155_ioc_s_std(struct file *filp, void *p, v4l2_std_id *norm) 615 + dt3155_ioc_s_std(struct file *filp, void *p, v4l2_std_id norm) 616 616 { 617 - if (*norm & DT3155_CURRENT_NORM) 617 + if (norm & DT3155_CURRENT_NORM) 618 618 return 0; 619 619 return -EINVAL; 620 620 }
+8 -8
drivers/staging/media/go7007/go7007-v4l2.c
··· 1117 1117 return 0; 1118 1118 } 1119 1119 1120 - static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *std) 1120 + static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id std) 1121 1121 { 1122 1122 struct go7007 *go = ((struct go7007_file *) priv)->go; 1123 1123 1124 1124 if (go->streaming) 1125 1125 return -EBUSY; 1126 1126 1127 - if (!(go->board_info->sensor_flags & GO7007_SENSOR_TV) && *std != 0) 1127 + if (!(go->board_info->sensor_flags & GO7007_SENSOR_TV) && std != 0) 1128 1128 return -EINVAL; 1129 1129 1130 - if (*std == 0) 1130 + if (std == 0) 1131 1131 return -EINVAL; 1132 1132 1133 1133 if ((go->board_info->flags & GO7007_BOARD_HAS_TUNER) && 1134 1134 go->input == go->board_info->num_inputs - 1) { 1135 1135 if (!go->i2c_adapter_online) 1136 1136 return -EIO; 1137 - if (call_all(&go->v4l2_dev, core, s_std, *std) < 0) 1137 + if (call_all(&go->v4l2_dev, core, s_std, std) < 0) 1138 1138 return -EINVAL; 1139 1139 } 1140 1140 1141 - if (*std & V4L2_STD_NTSC) { 1141 + if (std & V4L2_STD_NTSC) { 1142 1142 go->standard = GO7007_STD_NTSC; 1143 1143 go->sensor_framerate = 30000; 1144 - } else if (*std & V4L2_STD_PAL) { 1144 + } else if (std & V4L2_STD_PAL) { 1145 1145 go->standard = GO7007_STD_PAL; 1146 1146 go->sensor_framerate = 25025; 1147 - } else if (*std & V4L2_STD_SECAM) { 1147 + } else if (std & V4L2_STD_SECAM) { 1148 1148 go->standard = GO7007_STD_PAL; 1149 1149 go->sensor_framerate = 25025; 1150 1150 } else 1151 1151 return -EINVAL; 1152 1152 1153 - call_all(&go->v4l2_dev, core, s_std, *std); 1153 + call_all(&go->v4l2_dev, core, s_std, std); 1154 1154 set_capture_size(go, NULL, 0); 1155 1155 1156 1156 return 0;
+1 -1
drivers/staging/media/solo6x10/v4l2-enc.c
··· 1326 1326 return videobuf_streamoff(&fh->vidq); 1327 1327 } 1328 1328 1329 - static int solo_enc_s_std(struct file *file, void *priv, v4l2_std_id *i) 1329 + static int solo_enc_s_std(struct file *file, void *priv, v4l2_std_id i) 1330 1330 { 1331 1331 return 0; 1332 1332 }
+1 -1
drivers/staging/media/solo6x10/v4l2.c
··· 773 773 return videobuf_streamoff(&fh->vidq); 774 774 } 775 775 776 - static int solo_s_std(struct file *file, void *priv, v4l2_std_id *i) 776 + static int solo_s_std(struct file *file, void *priv, v4l2_std_id i) 777 777 { 778 778 return 0; 779 779 }
+1 -1
include/media/davinci/vpbe.h
··· 132 132 struct v4l2_enum_dv_timings *timings_info); 133 133 134 134 /* Set std at the output */ 135 - int (*s_std)(struct vpbe_device *vpbe_dev, v4l2_std_id *std_id); 135 + int (*s_std)(struct vpbe_device *vpbe_dev, v4l2_std_id std_id); 136 136 137 137 /* Get the current std at the output */ 138 138 int (*g_std)(struct vpbe_device *vpbe_dev, v4l2_std_id *std_id);
+1 -1
include/media/v4l2-ioctl.h
··· 132 132 ENUMSTD is handled by videodev.c 133 133 */ 134 134 int (*vidioc_g_std) (struct file *file, void *fh, v4l2_std_id *norm); 135 - int (*vidioc_s_std) (struct file *file, void *fh, v4l2_std_id *norm); 135 + int (*vidioc_s_std) (struct file *file, void *fh, v4l2_std_id norm); 136 136 int (*vidioc_querystd) (struct file *file, void *fh, v4l2_std_id *a); 137 137 138 138 /* Input handling */