Skip to contentSkip to conversation

Staging: dgnc: Replace printk() with dev_dbg()

PATCH In review Cristina Opriceana 2 participants 2 messages Feb 28, 2015 – Mar 1, 2015 Staging

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 Staging: dgnc: Replace printk() with dev_dbg()

This patch replaces printk() with dev_dbg() in order to avoid the suggestion of using a more specific function while printing debug information. Warning found by checkpatch.pl.

---
Changes in v2:
- Use dev_dbg() instead of dev_info()
- Make the commit message more clear

 drivers/staging/dgnc/dgnc_driver.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/dgnc/dgnc_driver.c +2 -2
index a2543cf..c1d1a97 100644
@@ -362,7 +362,7 @@ static void dgnc_cleanup_board(struct dgnc_board *brd)
 
 		spin_lock_irqsave(&dgnc_global_lock, flags);
 		brd->msgbuf = NULL;
-		printk("%s", brd->msgbuf_head);
+		dev_dbg(&brd->pdev->dev, "%s\n", brd->msgbuf_head);
 		kfree(brd->msgbuf_head);
 		brd->msgbuf_head = NULL;
 		spin_unlock_irqrestore(&dgnc_global_lock, flags);
@@ -610,7 +610,7 @@ static int dgnc_found_board(struct pci_dev *pdev, int id)
 
 	spin_lock_irqsave(&dgnc_global_lock, flags);
 	brd->msgbuf = NULL;
-	printk("%s", brd->msgbuf_head);
+	dev_dbg(&brd->pdev->dev, "%s\n", brd->msgbuf_head);
 	kfree(brd->msgbuf_head);
 	brd->msgbuf_head = NULL;
 	spin_unlock_irqrestore(&dgnc_global_lock, flags);
Signature · 1 line
1.9.1