Commit d2db42dd authored by Harvey Harrison's avatar Harvey Harrison Committed by Mauro Carvalho Chehab

V4L/DVB (7502): v4l: video/usbvision replace remaining __FUNCTION__ occurrences

__FUNCTION__ is gcc-specific, use __func__
Signed-off-by: default avatarHarvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: default avatarThierry MERLE <thierry.merle@free.fr>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@infradead.org>
parent 1a0063a9
...@@ -386,7 +386,7 @@ int usbvision_scratch_alloc(struct usb_usbvision *usbvision) ...@@ -386,7 +386,7 @@ int usbvision_scratch_alloc(struct usb_usbvision *usbvision)
scratch_reset(usbvision); scratch_reset(usbvision);
if(usbvision->scratch == NULL) { if(usbvision->scratch == NULL) {
err("%s: unable to allocate %d bytes for scratch", err("%s: unable to allocate %d bytes for scratch",
__FUNCTION__, scratch_buf_size); __func__, scratch_buf_size);
return -ENOMEM; return -ENOMEM;
} }
return 0; return 0;
...@@ -495,7 +495,8 @@ int usbvision_decompress_alloc(struct usb_usbvision *usbvision) ...@@ -495,7 +495,8 @@ int usbvision_decompress_alloc(struct usb_usbvision *usbvision)
int IFB_size = MAX_FRAME_WIDTH * MAX_FRAME_HEIGHT * 3 / 2; int IFB_size = MAX_FRAME_WIDTH * MAX_FRAME_HEIGHT * 3 / 2;
usbvision->IntraFrameBuffer = vmalloc_32(IFB_size); usbvision->IntraFrameBuffer = vmalloc_32(IFB_size);
if (usbvision->IntraFrameBuffer == NULL) { if (usbvision->IntraFrameBuffer == NULL) {
err("%s: unable to allocate %d for compr. frame buffer", __FUNCTION__, IFB_size); err("%s: unable to allocate %d for compr. frame buffer",
__func__, IFB_size);
return -ENOMEM; return -ENOMEM;
} }
return 0; return 0;
...@@ -1518,7 +1519,7 @@ static void usbvision_isocIrq(struct urb *urb) ...@@ -1518,7 +1519,7 @@ static void usbvision_isocIrq(struct urb *urb)
if(errCode) { if(errCode) {
err("%s: usb_submit_urb failed: error %d", err("%s: usb_submit_urb failed: error %d",
__FUNCTION__, errCode); __func__, errCode);
} }
return; return;
...@@ -1549,7 +1550,7 @@ int usbvision_read_reg(struct usb_usbvision *usbvision, unsigned char reg) ...@@ -1549,7 +1550,7 @@ int usbvision_read_reg(struct usb_usbvision *usbvision, unsigned char reg)
0, (__u16) reg, buffer, 1, HZ); 0, (__u16) reg, buffer, 1, HZ);
if (errCode < 0) { if (errCode < 0) {
err("%s: failed: error %d", __FUNCTION__, errCode); err("%s: failed: error %d", __func__, errCode);
return errCode; return errCode;
} }
return buffer[0]; return buffer[0];
...@@ -1577,7 +1578,7 @@ int usbvision_write_reg(struct usb_usbvision *usbvision, unsigned char reg, ...@@ -1577,7 +1578,7 @@ int usbvision_write_reg(struct usb_usbvision *usbvision, unsigned char reg,
USB_RECIP_ENDPOINT, 0, (__u16) reg, &value, 1, HZ); USB_RECIP_ENDPOINT, 0, (__u16) reg, &value, 1, HZ);
if (errCode < 0) { if (errCode < 0) {
err("%s: failed: error %d", __FUNCTION__, errCode); err("%s: failed: error %d", __func__, errCode);
} }
return errCode; return errCode;
} }
...@@ -1853,7 +1854,7 @@ int usbvision_set_output(struct usb_usbvision *usbvision, int width, ...@@ -1853,7 +1854,7 @@ int usbvision_set_output(struct usb_usbvision *usbvision, int width,
0, (__u16) USBVISION_LXSIZE_O, value, 4, HZ); 0, (__u16) USBVISION_LXSIZE_O, value, 4, HZ);
if (errCode < 0) { if (errCode < 0) {
err("%s failed: error %d", __FUNCTION__, errCode); err("%s failed: error %d", __func__, errCode);
return errCode; return errCode;
} }
usbvision->curwidth = usbvision->stretch_width * UsbWidth; usbvision->curwidth = usbvision->stretch_width * UsbWidth;
...@@ -2239,7 +2240,7 @@ static int usbvision_set_dram_settings(struct usb_usbvision *usbvision) ...@@ -2239,7 +2240,7 @@ static int usbvision_set_dram_settings(struct usb_usbvision *usbvision)
(__u16) USBVISION_DRM_PRM1, value, 8, HZ); (__u16) USBVISION_DRM_PRM1, value, 8, HZ);
if (rc < 0) { if (rc < 0) {
err("%sERROR=%d", __FUNCTION__, rc); err("%sERROR=%d", __func__, rc);
return rc; return rc;
} }
...@@ -2488,7 +2489,7 @@ int usbvision_init_isoc(struct usb_usbvision *usbvision) ...@@ -2488,7 +2489,7 @@ int usbvision_init_isoc(struct usb_usbvision *usbvision)
urb = usb_alloc_urb(USBVISION_URB_FRAMES, GFP_KERNEL); urb = usb_alloc_urb(USBVISION_URB_FRAMES, GFP_KERNEL);
if (urb == NULL) { if (urb == NULL) {
err("%s: usb_alloc_urb() failed", __FUNCTION__); err("%s: usb_alloc_urb() failed", __func__);
return -ENOMEM; return -ENOMEM;
} }
usbvision->sbuf[bufIdx].urb = urb; usbvision->sbuf[bufIdx].urb = urb;
...@@ -2522,13 +2523,13 @@ int usbvision_init_isoc(struct usb_usbvision *usbvision) ...@@ -2522,13 +2523,13 @@ int usbvision_init_isoc(struct usb_usbvision *usbvision)
GFP_KERNEL); GFP_KERNEL);
if (errCode) { if (errCode) {
err("%s: usb_submit_urb(%d) failed: error %d", err("%s: usb_submit_urb(%d) failed: error %d",
__FUNCTION__, bufIdx, errCode); __func__, bufIdx, errCode);
} }
} }
usbvision->streaming = Stream_Idle; usbvision->streaming = Stream_Idle;
PDEBUG(DBG_ISOC, "%s: streaming=1 usbvision->video_endp=$%02x", PDEBUG(DBG_ISOC, "%s: streaming=1 usbvision->video_endp=$%02x",
__FUNCTION__, __func__,
usbvision->video_endp); usbvision->video_endp);
return 0; return 0;
} }
...@@ -2562,7 +2563,7 @@ void usbvision_stop_isoc(struct usb_usbvision *usbvision) ...@@ -2562,7 +2563,7 @@ void usbvision_stop_isoc(struct usb_usbvision *usbvision)
} }
PDEBUG(DBG_ISOC, "%s: streaming=Stream_Off\n", __FUNCTION__); PDEBUG(DBG_ISOC, "%s: streaming=Stream_Off\n", __func__);
usbvision->streaming = Stream_Off; usbvision->streaming = Stream_Off;
if (!usbvision->remove_pending) { if (!usbvision->remove_pending) {
...@@ -2573,7 +2574,7 @@ void usbvision_stop_isoc(struct usb_usbvision *usbvision) ...@@ -2573,7 +2574,7 @@ void usbvision_stop_isoc(struct usb_usbvision *usbvision)
usbvision->ifaceAlt); usbvision->ifaceAlt);
if (errCode < 0) { if (errCode < 0) {
err("%s: usb_set_interface() failed: error %d", err("%s: usb_set_interface() failed: error %d",
__FUNCTION__, errCode); __func__, errCode);
usbvision->last_error = errCode; usbvision->last_error = errCode;
} }
regValue = (16-usbvision_read_reg(usbvision, USBVISION_ALTER_REG)) & 0x0F; regValue = (16-usbvision_read_reg(usbvision, USBVISION_ALTER_REG)) & 0x0F;
......
...@@ -343,7 +343,7 @@ static void usbvision_create_sysfs(struct video_device *vdev) ...@@ -343,7 +343,7 @@ static void usbvision_create_sysfs(struct video_device *vdev)
return; return;
} while (0); } while (0);
err("%s error: %d\n", __FUNCTION__, res); err("%s error: %d\n", __func__, res);
} }
static void usbvision_remove_sysfs(struct video_device *vdev) static void usbvision_remove_sysfs(struct video_device *vdev)
...@@ -490,7 +490,7 @@ static int usbvision_v4l2_close(struct inode *inode, struct file *file) ...@@ -490,7 +490,7 @@ static int usbvision_v4l2_close(struct inode *inode, struct file *file)
mutex_unlock(&usbvision->lock); mutex_unlock(&usbvision->lock);
if (usbvision->remove_pending) { if (usbvision->remove_pending) {
printk(KERN_INFO "%s: Final disconnect\n", __FUNCTION__); printk(KERN_INFO "%s: Final disconnect\n", __func__);
usbvision_release(usbvision); usbvision_release(usbvision);
} }
...@@ -522,7 +522,7 @@ static int vidioc_g_register (struct file *file, void *priv, ...@@ -522,7 +522,7 @@ static int vidioc_g_register (struct file *file, void *priv,
errCode = usbvision_read_reg(usbvision, reg->reg&0xff); errCode = usbvision_read_reg(usbvision, reg->reg&0xff);
if (errCode < 0) { if (errCode < 0) {
err("%s: VIDIOC_DBG_G_REGISTER failed: error %d", err("%s: VIDIOC_DBG_G_REGISTER failed: error %d",
__FUNCTION__, errCode); __func__, errCode);
return errCode; return errCode;
} }
reg->val = errCode; reg->val = errCode;
...@@ -543,7 +543,7 @@ static int vidioc_s_register (struct file *file, void *priv, ...@@ -543,7 +543,7 @@ static int vidioc_s_register (struct file *file, void *priv,
errCode = usbvision_write_reg(usbvision, reg->reg&0xff, reg->val); errCode = usbvision_write_reg(usbvision, reg->reg&0xff, reg->val);
if (errCode < 0) { if (errCode < 0) {
err("%s: VIDIOC_DBG_S_REGISTER failed: error %d", err("%s: VIDIOC_DBG_S_REGISTER failed: error %d",
__FUNCTION__, errCode); __func__, errCode);
return errCode; return errCode;
} }
return 0; return 0;
...@@ -1102,7 +1102,7 @@ static ssize_t usbvision_v4l2_read(struct file *file, char __user *buf, ...@@ -1102,7 +1102,7 @@ static ssize_t usbvision_v4l2_read(struct file *file, char __user *buf,
int ret,i; int ret,i;
struct usbvision_frame *frame; struct usbvision_frame *frame;
PDEBUG(DBG_IO, "%s: %ld bytes, noblock=%d", __FUNCTION__, PDEBUG(DBG_IO, "%s: %ld bytes, noblock=%d", __func__,
(unsigned long)count, noblock); (unsigned long)count, noblock);
if (!USBVISION_IS_OPERATIONAL(usbvision) || (buf == NULL)) if (!USBVISION_IS_OPERATIONAL(usbvision) || (buf == NULL))
...@@ -1171,7 +1171,7 @@ static ssize_t usbvision_v4l2_read(struct file *file, char __user *buf, ...@@ -1171,7 +1171,7 @@ static ssize_t usbvision_v4l2_read(struct file *file, char __user *buf,
} }
PDEBUG(DBG_IO, "%s: frmx=%d, bytes_read=%ld, scanlength=%ld", PDEBUG(DBG_IO, "%s: frmx=%d, bytes_read=%ld, scanlength=%ld",
__FUNCTION__, __func__,
frame->index, frame->bytes_read, frame->scanlength); frame->index, frame->bytes_read, frame->scanlength);
/* copy bytes to user space; we allow for partials reads */ /* copy bytes to user space; we allow for partials reads */
...@@ -1184,7 +1184,7 @@ static ssize_t usbvision_v4l2_read(struct file *file, char __user *buf, ...@@ -1184,7 +1184,7 @@ static ssize_t usbvision_v4l2_read(struct file *file, char __user *buf,
frame->bytes_read += count; frame->bytes_read += count;
PDEBUG(DBG_IO, "%s: {copy} count used=%ld, new bytes_read=%ld", PDEBUG(DBG_IO, "%s: {copy} count used=%ld, new bytes_read=%ld",
__FUNCTION__, __func__,
(unsigned long)count, frame->bytes_read); (unsigned long)count, frame->bytes_read);
/* For now, forget the frame if it has not been read in one shot. */ /* For now, forget the frame if it has not been read in one shot. */
...@@ -1269,12 +1269,12 @@ static int usbvision_radio_open(struct inode *inode, struct file *file) ...@@ -1269,12 +1269,12 @@ static int usbvision_radio_open(struct inode *inode, struct file *file)
(struct usb_usbvision *) video_get_drvdata(dev); (struct usb_usbvision *) video_get_drvdata(dev);
int errCode = 0; int errCode = 0;
PDEBUG(DBG_IO, "%s:", __FUNCTION__); PDEBUG(DBG_IO, "%s:", __func__);
mutex_lock(&usbvision->lock); mutex_lock(&usbvision->lock);
if (usbvision->user) { if (usbvision->user) {
err("%s: Someone tried to open an already opened USBVision Radio!", __FUNCTION__); err("%s: Someone tried to open an already opened USBVision Radio!", __func__);
errCode = -EBUSY; errCode = -EBUSY;
} }
else { else {
...@@ -1342,7 +1342,7 @@ static int usbvision_radio_close(struct inode *inode, struct file *file) ...@@ -1342,7 +1342,7 @@ static int usbvision_radio_close(struct inode *inode, struct file *file)
mutex_unlock(&usbvision->lock); mutex_unlock(&usbvision->lock);
if (usbvision->remove_pending) { if (usbvision->remove_pending) {
printk(KERN_INFO "%s: Final disconnect\n", __FUNCTION__); printk(KERN_INFO "%s: Final disconnect\n", __func__);
usbvision_release(usbvision); usbvision_release(usbvision);
} }
...@@ -1507,7 +1507,7 @@ static struct video_device *usbvision_vdev_init(struct usb_usbvision *usbvision, ...@@ -1507,7 +1507,7 @@ static struct video_device *usbvision_vdev_init(struct usb_usbvision *usbvision,
struct video_device *vdev; struct video_device *vdev;
if (usb_dev == NULL) { if (usb_dev == NULL) {
err("%s: usbvision->dev is not set", __FUNCTION__); err("%s: usbvision->dev is not set", __func__);
return NULL; return NULL;
} }
...@@ -1759,7 +1759,7 @@ static int __devinit usbvision_probe(struct usb_interface *intf, ...@@ -1759,7 +1759,7 @@ static int __devinit usbvision_probe(struct usb_interface *intf,
PDEBUG(DBG_PROBE, "model out of bounds %d",model); PDEBUG(DBG_PROBE, "model out of bounds %d",model);
return -ENODEV; return -ENODEV;
} }
printk(KERN_INFO "%s: %s found\n", __FUNCTION__, printk(KERN_INFO "%s: %s found\n", __func__,
usbvision_device_data[model].ModelString); usbvision_device_data[model].ModelString);
if (usbvision_device_data[model].Interface >= 0) { if (usbvision_device_data[model].Interface >= 0) {
...@@ -1771,20 +1771,20 @@ static int __devinit usbvision_probe(struct usb_interface *intf, ...@@ -1771,20 +1771,20 @@ static int __devinit usbvision_probe(struct usb_interface *intf,
if ((endpoint->bmAttributes & USB_ENDPOINT_XFERTYPE_MASK) != if ((endpoint->bmAttributes & USB_ENDPOINT_XFERTYPE_MASK) !=
USB_ENDPOINT_XFER_ISOC) { USB_ENDPOINT_XFER_ISOC) {
err("%s: interface %d. has non-ISO endpoint!", err("%s: interface %d. has non-ISO endpoint!",
__FUNCTION__, ifnum); __func__, ifnum);
err("%s: Endpoint attributes %d", err("%s: Endpoint attributes %d",
__FUNCTION__, endpoint->bmAttributes); __func__, endpoint->bmAttributes);
return -ENODEV; return -ENODEV;
} }
if ((endpoint->bEndpointAddress & USB_ENDPOINT_DIR_MASK) == if ((endpoint->bEndpointAddress & USB_ENDPOINT_DIR_MASK) ==
USB_DIR_OUT) { USB_DIR_OUT) {
err("%s: interface %d. has ISO OUT endpoint!", err("%s: interface %d. has ISO OUT endpoint!",
__FUNCTION__, ifnum); __func__, ifnum);
return -ENODEV; return -ENODEV;
} }
if ((usbvision = usbvision_alloc(dev)) == NULL) { if ((usbvision = usbvision_alloc(dev)) == NULL) {
err("%s: couldn't allocate USBVision struct", __FUNCTION__); err("%s: couldn't allocate USBVision struct", __func__);
return -ENOMEM; return -ENOMEM;
} }
...@@ -1868,7 +1868,7 @@ static void __devexit usbvision_disconnect(struct usb_interface *intf) ...@@ -1868,7 +1868,7 @@ static void __devexit usbvision_disconnect(struct usb_interface *intf)
PDEBUG(DBG_PROBE, ""); PDEBUG(DBG_PROBE, "");
if (usbvision == NULL) { if (usbvision == NULL) {
err("%s: usb_get_intfdata() failed", __FUNCTION__); err("%s: usb_get_intfdata() failed", __func__);
return; return;
} }
usb_set_intfdata (intf, NULL); usb_set_intfdata (intf, NULL);
...@@ -1891,7 +1891,7 @@ static void __devexit usbvision_disconnect(struct usb_interface *intf) ...@@ -1891,7 +1891,7 @@ static void __devexit usbvision_disconnect(struct usb_interface *intf)
if (usbvision->user) { if (usbvision->user) {
printk(KERN_INFO "%s: In use, disconnect pending\n", printk(KERN_INFO "%s: In use, disconnect pending\n",
__FUNCTION__); __func__);
wake_up_interruptible(&usbvision->wait_frame); wake_up_interruptible(&usbvision->wait_frame);
wake_up_interruptible(&usbvision->wait_stream); wake_up_interruptible(&usbvision->wait_stream);
} else { } else {
......
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