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  linux-hardening  linux-cve-announce  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]
Message-Id: <1313761468-8055-1-git-send-email-ravishankarkm32@gmail.com>
Date:	Fri, 19 Aug 2011 09:44:28 -0400
From:	Ravishankar <ravishankarkm32@...il.com>
To:	gregkh@...e.de, wfp5p@...ginia.edu
Cc:	devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org,
	Ravishankar <ravi.shankar@...enturtles.in>,
	Ravishankar <ravishankarkm32@...l.com>
Subject: [PATCH] Staging: comedi: fix printk issue in adv_pci1710.c

From: Ravishankar <ravi.shankar@...enturtles.in>

This is a patch to the adv_pci1710.c file that fixes up a printk warning found by the checkpatch.pl tool

Signed-off-by: Ravishankar <ravishankarkm32@...l.com>
---
 drivers/staging/comedi/drivers/adv_pci1710.c |   28 +++++++++++++-------------
 1 files changed, 14 insertions(+), 14 deletions(-)

diff --git a/drivers/staging/comedi/drivers/adv_pci1710.c b/drivers/staging/comedi/drivers/adv_pci1710.c
index da2b75b..e6c0f06 100644
--- a/drivers/staging/comedi/drivers/adv_pci1710.c
+++ b/drivers/staging/comedi/drivers/adv_pci1710.c
@@ -1382,14 +1382,13 @@ static int pci1710_attach(struct comedi_device *dev,
 	int i;
 	int board_index;
 
-	printk("comedi%d: adv_pci1710: ", dev->minor);
+	pr_info("comedi%d: adv_pci1710: ", dev->minor);
 
 	opt_bus = it->options[0];
 	opt_slot = it->options[1];
 
 	ret = alloc_private(dev, sizeof(struct pci1710_private));
 	if (ret < 0) {
-		printk(" - Allocation failed!\n");
 		return -ENOMEM;
 	}
 
@@ -1436,10 +1435,13 @@ static int pci1710_attach(struct comedi_device *dev,
 
 	if (!pcidev) {
 		if (opt_bus || opt_slot) {
-			printk(" - Card at b:s %d:%d %s\n",
-			       opt_bus, opt_slot, errstr);
+			pr_cont("\n");
+			pr_err("comedi%d: adv_pci1710: Card at b:s %d:%d %s\n",
+					dev->minor, opt_bus, opt_slot, errstr);
 		} else {
-			printk(" - Card %s\n", errstr);
+			pr_cont("\n");
+			pr_err("comedi%d: adv_pci1710: Card %s\n", dev->minor,
+					errstr);
 		}
 		return -EIO;
 	}
@@ -1450,8 +1452,8 @@ static int pci1710_attach(struct comedi_device *dev,
 	irq = pcidev->irq;
 	iobase = pci_resource_start(pcidev, 2);
 
-	printk(", b:s:f=%d:%d:%d, io=0x%4lx", pci_bus, pci_slot, pci_func,
-	       iobase);
+	pr_cont(", b:s:f=%d:%d:%d, io=0x%4lx", pci_bus, pci_slot, pci_func,
+			iobase);
 
 	dev->iobase = iobase;
 
@@ -1472,7 +1474,6 @@ static int pci1710_attach(struct comedi_device *dev,
 
 	ret = alloc_subdevices(dev, n_subdevices);
 	if (ret < 0) {
-		printk(" - Allocation failed!\n");
 		return ret;
 	}
 
@@ -1483,15 +1484,14 @@ static int pci1710_attach(struct comedi_device *dev,
 			if (request_irq(irq, interrupt_service_pci1710,
 					IRQF_SHARED, "Advantech PCI-1710",
 					dev)) {
-				printk
-				    (", unable to allocate IRQ %d, DISABLING IT",
-				     irq);
+				pr_info(", unable to allocate IRQ %d, DISABLING IT",
+						irq);
 				irq = 0;	/* Can't use IRQ */
 			} else {
-				printk(", irq=%u", irq);
+				pr_cont(", irq=%u", irq);
 			}
 		} else {
-			printk(", IRQ disabled");
+			pr_cont(", IRQ disabled");
 		}
 	} else {
 		irq = 0;
@@ -1499,7 +1499,7 @@ static int pci1710_attach(struct comedi_device *dev,
 
 	dev->irq = irq;
 
-	printk(".\n");
+	pr_cont(".\n");
 
 	subdev = 0;
 
-- 
1.7.6

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ