diff options
author | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2014-11-01 11:09:44 (GMT) |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2014-11-03 17:55:23 (GMT) |
commit | 589dadf299bc8dab27589ecd62024c96a3812505 (patch) | |
tree | ca4b1213906a970a6579a386716878a01f216d84 /drivers/media/usb/cx231xx/cx231xx-audio.c | |
parent | f2dd851ff19412bdc80471048283edbb465f812e (diff) | |
download | linux-589dadf299bc8dab27589ecd62024c96a3812505.tar.xz |
[media] cx231xx: get rid of driver-defined printk macros
It currently does just like what pr_foo() macros do. So,
replace them.
A deeper cleanup is needed, as there are lots of debug macros
printed with pr_info.
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/usb/cx231xx/cx231xx-audio.c')
-rw-r--r-- | drivers/media/usb/cx231xx/cx231xx-audio.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/drivers/media/usb/cx231xx/cx231xx-audio.c b/drivers/media/usb/cx231xx/cx231xx-audio.c index 9b92587..8312388 100644 --- a/drivers/media/usb/cx231xx/cx231xx-audio.c +++ b/drivers/media/usb/cx231xx/cx231xx-audio.c @@ -20,6 +20,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ +#include "cx231xx.h" #include <linux/kernel.h> #include <linux/usb.h> #include <linux/init.h> @@ -37,7 +38,6 @@ #include <sound/initval.h> #include <sound/control.h> #include <media/v4l2-common.h> -#include "cx231xx.h" static int debug; module_param(debug, int, 0644); @@ -182,7 +182,7 @@ static void cx231xx_audio_isocirq(struct urb *urb) status = usb_submit_urb(urb, GFP_ATOMIC); if (status < 0) { - cx231xx_errdev("resubmit of audio urb failed (error=%i)\n", + pr_err("resubmit of audio urb failed (error=%i)\n", status); } return; @@ -266,7 +266,7 @@ static void cx231xx_audio_bulkirq(struct urb *urb) status = usb_submit_urb(urb, GFP_ATOMIC); if (status < 0) { - cx231xx_errdev("resubmit of audio urb failed (error=%i)\n", + pr_err("resubmit of audio urb failed (error=%i)\n", status); } return; @@ -277,7 +277,7 @@ static int cx231xx_init_audio_isoc(struct cx231xx *dev) int i, errCode; int sb_size; - cx231xx_info("%s: Starting ISO AUDIO transfers\n", __func__); + pr_info("%s: Starting ISO AUDIO transfers\n", __func__); if (dev->state & DEV_DISCONNECTED) return -ENODEV; @@ -295,7 +295,7 @@ static int cx231xx_init_audio_isoc(struct cx231xx *dev) memset(dev->adev.transfer_buffer[i], 0x80, sb_size); urb = usb_alloc_urb(CX231XX_ISO_NUM_AUDIO_PACKETS, GFP_ATOMIC); if (!urb) { - cx231xx_errdev("usb_alloc_urb failed!\n"); + pr_err("usb_alloc_urb failed!\n"); for (j = 0; j < i; j++) { usb_free_urb(dev->adev.urb[j]); kfree(dev->adev.transfer_buffer[j]); @@ -338,7 +338,7 @@ static int cx231xx_init_audio_bulk(struct cx231xx *dev) int i, errCode; int sb_size; - cx231xx_info("%s: Starting BULK AUDIO transfers\n", __func__); + pr_info("%s: Starting BULK AUDIO transfers\n", __func__); if (dev->state & DEV_DISCONNECTED) return -ENODEV; @@ -356,7 +356,7 @@ static int cx231xx_init_audio_bulk(struct cx231xx *dev) memset(dev->adev.transfer_buffer[i], 0x80, sb_size); urb = usb_alloc_urb(CX231XX_NUM_AUDIO_PACKETS, GFP_ATOMIC); if (!urb) { - cx231xx_errdev("usb_alloc_urb failed!\n"); + pr_err("usb_alloc_urb failed!\n"); for (j = 0; j < i; j++) { usb_free_urb(dev->adev.urb[j]); kfree(dev->adev.transfer_buffer[j]); @@ -439,13 +439,13 @@ static int snd_cx231xx_capture_open(struct snd_pcm_substream *substream) dprintk("opening device and trying to acquire exclusive lock\n"); if (!dev) { - cx231xx_errdev("BUG: cx231xx can't find device struct." + pr_err("BUG: cx231xx can't find device struct." " Can't proceed with open\n"); return -ENODEV; } if (dev->state & DEV_DISCONNECTED) { - cx231xx_errdev("Can't open. the device was removed.\n"); + pr_err("Can't open. the device was removed.\n"); return -ENODEV; } @@ -458,7 +458,7 @@ static int snd_cx231xx_capture_open(struct snd_pcm_substream *substream) ret = cx231xx_set_alt_setting(dev, INDEX_AUDIO, 0); mutex_unlock(&dev->lock); if (ret < 0) { - cx231xx_errdev("failed to set alternate setting !\n"); + pr_err("failed to set alternate setting !\n"); return ret; } @@ -494,7 +494,7 @@ static int snd_cx231xx_pcm_close(struct snd_pcm_substream *substream) /* 1 - 48000 samples per sec */ ret = cx231xx_set_alt_setting(dev, INDEX_AUDIO, 0); if (ret < 0) { - cx231xx_errdev("failed to set alternate setting !\n"); + pr_err("failed to set alternate setting !\n"); mutex_unlock(&dev->lock); return ret; @@ -662,7 +662,7 @@ static int cx231xx_audio_init(struct cx231xx *dev) return 0; } - cx231xx_info("cx231xx-audio.c: probing for cx231xx " + pr_info("cx231xx-audio.c: probing for cx231xx " "non standard usbaudio\n"); err = snd_card_new(&dev->udev->dev, index[devnr], "Cx231xx Audio", @@ -707,12 +707,12 @@ static int cx231xx_audio_init(struct cx231xx *dev) bEndpointAddress; adev->num_alt = uif->num_altsetting; - cx231xx_info("EndPoint Addr 0x%x, Alternate settings: %i\n", + pr_info("EndPoint Addr 0x%x, Alternate settings: %i\n", adev->end_point_addr, adev->num_alt); adev->alt_max_pkt_size = kmalloc(32 * adev->num_alt, GFP_KERNEL); if (adev->alt_max_pkt_size == NULL) { - cx231xx_errdev("out of memory!\n"); + pr_err("out of memory!\n"); return -ENOMEM; } @@ -722,7 +722,7 @@ static int cx231xx_audio_init(struct cx231xx *dev) wMaxPacketSize); adev->alt_max_pkt_size[i] = (tmp & 0x07ff) * (((tmp & 0x1800) >> 11) + 1); - cx231xx_info("Alternate setting %i, max size= %i\n", i, + pr_info("Alternate setting %i, max size= %i\n", i, adev->alt_max_pkt_size[i]); } |