From a9524a76f70f3343e4be27f95a7e92a8ba5f9009 Mon Sep 17 00:00:00 2001 From: Jeff Garzik Date: Sun, 30 Oct 2005 14:39:11 -0500 Subject: [libata] use dev_printk() throughout drivers A few drivers were not following the standard meme of printing out their driver name and version at module load time; this is fixed as well. --- drivers/scsi/sata_sil24.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'drivers/scsi/sata_sil24.c') diff --git a/drivers/scsi/sata_sil24.c b/drivers/scsi/sata_sil24.c index 4afe2b15b803..c66548025657 100644 --- a/drivers/scsi/sata_sil24.c +++ b/drivers/scsi/sata_sil24.c @@ -35,6 +35,7 @@ #include #include #include +#include #include #include "scsi.h" #include @@ -690,7 +691,7 @@ static int sil24_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) int i, rc; if (!printed_version++) - printk(KERN_DEBUG DRV_NAME " version " DRV_VERSION "\n"); + dev_printk(KERN_DEBUG, &pdev->dev, "version " DRV_VERSION "\n"); rc = pci_enable_device(pdev); if (rc) @@ -750,14 +751,14 @@ static int sil24_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) */ rc = pci_set_dma_mask(pdev, DMA_32BIT_MASK); if (rc) { - printk(KERN_ERR DRV_NAME "(%s): 32-bit DMA enable failed\n", - pci_name(pdev)); + dev_printk(KERN_ERR, &pdev->dev, + "32-bit DMA enable failed\n"); goto out_free; } rc = pci_set_consistent_dma_mask(pdev, DMA_32BIT_MASK); if (rc) { - printk(KERN_ERR DRV_NAME "(%s): 32-bit consistent DMA enable failed\n", - pci_name(pdev)); + dev_printk(KERN_ERR, &pdev->dev, + "32-bit consistent DMA enable failed\n"); goto out_free; } @@ -793,9 +794,8 @@ static int sil24_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) break; } if (tmp & PORT_CS_PORT_RST) - printk(KERN_ERR DRV_NAME - "(%s): failed to clear port RST\n", - pci_name(pdev)); + dev_printk(KERN_ERR, &pdev->dev, + "failed to clear port RST\n"); } /* Zero error counters. */ @@ -824,9 +824,8 @@ static int sil24_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) /* Reset itself */ if (__sil24_reset_controller(port)) - printk(KERN_ERR DRV_NAME - "(%s): failed to reset controller\n", - pci_name(pdev)); + dev_printk(KERN_ERR, &pdev->dev, + "failed to reset controller\n"); } /* Turn on interrupts */ -- cgit v1.2.3