summaryrefslogtreecommitdiff
path: root/drivers/staging/most/cdev
diff options
context:
space:
mode:
authorChristian Gromm <christian.gromm@microchip.com>2020-06-22 10:48:11 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-06-25 15:40:28 +0200
commit08839388d31ba85d550f60e8e4bc3956b0586e86 (patch)
tree42676d57bf4a5ead2d7eb3cc85f0befe74f59f81 /drivers/staging/most/cdev
parent61fd971eddecdc82586bbdcce26be01c984ae193 (diff)
staging: most: cdev: use dev_*() functions to print messages
This patch removes the pr_*() functions and uses dev_*() instead. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Link: https://lore.kernel.org/r/1592815695-19305-3-git-send-email-christian.gromm@microchip.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/most/cdev')
-rw-r--r--drivers/staging/most/cdev/cdev.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/staging/most/cdev/cdev.c b/drivers/staging/most/cdev/cdev.c
index 093b44d095a9..394c7621cb51 100644
--- a/drivers/staging/most/cdev/cdev.c
+++ b/drivers/staging/most/cdev/cdev.c
@@ -5,7 +5,6 @@
* Copyright (C) 2013-2015 Microchip Technology Germany II GmbH & Co. KG
*/
-#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
#include <linux/module.h>
#include <linux/sched.h>
#include <linux/fs.h>
@@ -375,7 +374,7 @@ static int comp_rx_completion(struct mbo *mbo)
spin_unlock(&c->unlink);
#ifdef DEBUG_MESG
if (kfifo_is_full(&c->fifo))
- pr_info("WARN: Fifo is full\n");
+ dev_warn(c->dev, "Fifo is full\n");
#endif
wake_up_interruptible(&c->wq);
return 0;
@@ -395,14 +394,15 @@ static int comp_tx_completion(struct most_interface *iface, int channel_id)
if (!iface)
return -EINVAL;
+ c = get_channel(iface, channel_id);
+ if (!c)
+ return -ENXIO;
+
if ((channel_id < 0) || (channel_id >= iface->num_channels)) {
- pr_info("Channel ID out of range\n");
+ dev_warn(c->dev, "Channel ID out of range\n");
return -EINVAL;
}
- c = get_channel(iface, channel_id);
- if (!c)
- return -ENXIO;
wake_up_interruptible(&c->wq);
return 0;
}