lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Sat, 28 Dec 2013 03:13:52 -0600
From:	Chase Southwood <chase.southwood@...oo.com>
To:	gregkh@...uxfoundation.org, linux-kernel@...r.kernel.org
Cc:	abbotti@....co.uk, hsweeten@...ionengravers.com,
	devel@...verdev.osuosl.org,
	Chase Southwood <chase.southwood@...oo.com>
Subject: [PATCH] Staging: comedi: replace printk() calls with dev_dbg() in pcmmio.c

From: Chase Southwood <chase.southwood@...oo.com>

This is a patch for pcmmio.c that changes several printk() calls to dev_dbg() or dev_err() to fix checkpatch.pl warnings.  Patched from 3.13-rc5.

Signed-off-by: Chase Southwood <chase.southwood@...oo.com>
---
 drivers/staging/comedi/drivers/pcmmio.c | 23 +++++++++++++----------
 1 file changed, 13 insertions(+), 10 deletions(-)

diff --git a/drivers/staging/comedi/drivers/pcmmio.c b/drivers/staging/comedi/drivers/pcmmio.c
index 14cee3a..8a567c9 100644
--- a/drivers/staging/comedi/drivers/pcmmio.c
+++ b/drivers/staging/comedi/drivers/pcmmio.c
@@ -252,7 +252,8 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev,
 
 #ifdef DAMMIT_ITS_BROKEN
 	/* DEBUG */
-	printk(KERN_DEBUG "write mask: %08x  data: %08x\n", data[0], data[1]);
+	dev_dbg(dev->class_dev, "write mask: %08x  data: %08x\n",
+			data[0], data[1]);
 #endif
 
 	s->state = 0;
@@ -273,10 +274,11 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev,
 
 #ifdef DAMMIT_ITS_BROKEN
 		/* DEBUG */
-		printk
-		    (KERN_DEBUG "byte %d wmb %02x db %02x offset %02d io %04x,"
-		     " data_in %02x ", byte_no, (unsigned)write_mask_byte,
-		     (unsigned)data_byte, offset, ioaddr, (unsigned)byte);
+		dev_dbg(dev->class_dev,
+				"byte %d wmb %02x db %02x offset %02d io %04x data_in %02x ",
+				byte_no, (unsigned)write_mask_byte,
+				(unsigned)data_byte, offset, ioaddr,
+				(unsigned)byte);
 #endif
 
 		if (write_mask_byte) {
@@ -293,7 +295,7 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev,
 		}
 #ifdef DAMMIT_ITS_BROKEN
 		/* DEBUG */
-		printk(KERN_DEBUG "data_out_byte %02x\n", (unsigned)byte);
+		dev_dbg(dev->class_dev, "data_out_byte %02x\n", (unsigned)byte);
 #endif
 		/* save the digital input lines for this byte.. */
 		s->state |= ((unsigned int)byte) << offset;
@@ -304,7 +306,8 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev,
 
 #ifdef DAMMIT_ITS_BROKEN
 	/* DEBUG */
-	printk(KERN_DEBUG "s->state %08x data_out %08x\n", s->state, data[1]);
+	dev_dbg(dev->class_dev, "s->state %08x data_out %08x\n",
+			s->state, data[1]);
 #endif
 
 	return insn->n;
@@ -505,8 +508,8 @@ static irqreturn_t interrupt_pcmmio(int irq, void *d)
 				 * TODO here: dispatch io lines to subdevs
 				 * with commands..
 				 */
-				printk
-				    (KERN_DEBUG "got edge detect interrupt %d asic %d which_chans: %06x\n",
+				dev_dbg(dev->class_dev,
+					 "got edge detect interrupt %d asic %d which_chans: %06x\n",
 				     irq, asic, triggered);
 				for (i = 2; i < dev->n_subdevices; i++) {
 					s = &dev->subdevices[i];
@@ -1021,7 +1024,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it)
 	    kcalloc(n_subdevs, sizeof(struct pcmmio_subdev_private),
 		    GFP_KERNEL);
 	if (!devpriv->sprivs) {
-		printk(KERN_ERR "comedi%d: cannot allocate subdevice private data structures\n",
+		dev_err(dev->class_dev, "comedi%d: cannot allocate subdevice private data structures\n",
 				dev->minor);
 		return -ENOMEM;
 	}
-- 
1.8.4.2

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists