aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/sata_sis.c
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@pobox.com>2005-10-30 14:39:11 -0500
committerJeff Garzik <jgarzik@pobox.com>2005-10-30 14:39:11 -0500
commita9524a76f70f3343e4be27f95a7e92a8ba5f9009 (patch)
tree00d2b6d02dfaa4796ad4bee51171aabe39b52dd8 /drivers/scsi/sata_sis.c
parentfbf30fbaa61595e9026f628f3913888b0df2b288 (diff)
[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.
Diffstat (limited to 'drivers/scsi/sata_sis.c')
-rw-r--r--drivers/scsi/sata_sis.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/drivers/scsi/sata_sis.c b/drivers/scsi/sata_sis.c
index 057f7b98b6c4..42288be0e561 100644
--- a/drivers/scsi/sata_sis.c
+++ b/drivers/scsi/sata_sis.c
@@ -38,6 +38,7 @@
38#include <linux/blkdev.h> 38#include <linux/blkdev.h>
39#include <linux/delay.h> 39#include <linux/delay.h>
40#include <linux/interrupt.h> 40#include <linux/interrupt.h>
41#include <linux/device.h>
41#include "scsi.h" 42#include "scsi.h"
42#include <scsi/scsi_host.h> 43#include <scsi/scsi_host.h>
43#include <linux/libata.h> 44#include <linux/libata.h>
@@ -237,6 +238,7 @@ static void sis_scr_write (struct ata_port *ap, unsigned int sc_reg, u32 val)
237 238
238static int sis_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) 239static int sis_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
239{ 240{
241 static int printed_version;
240 struct ata_probe_ent *probe_ent = NULL; 242 struct ata_probe_ent *probe_ent = NULL;
241 int rc; 243 int rc;
242 u32 genctl; 244 u32 genctl;
@@ -245,6 +247,9 @@ static int sis_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
245 u8 pmr; 247 u8 pmr;
246 u8 port2_start; 248 u8 port2_start;
247 249
250 if (!printed_version++)
251 dev_printk(KERN_INFO, &pdev->dev, "version " DRV_VERSION "\n");
252
248 rc = pci_enable_device(pdev); 253 rc = pci_enable_device(pdev);
249 if (rc) 254 if (rc)
250 return rc; 255 return rc;
@@ -288,16 +293,18 @@ static int sis_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
288 pci_read_config_byte(pdev, SIS_PMR, &pmr); 293 pci_read_config_byte(pdev, SIS_PMR, &pmr);
289 if (ent->device != 0x182) { 294 if (ent->device != 0x182) {
290 if ((pmr & SIS_PMR_COMBINED) == 0) { 295 if ((pmr & SIS_PMR_COMBINED) == 0) {
291 printk(KERN_INFO "sata_sis: Detected SiS 180/181 chipset in SATA mode\n"); 296 dev_printk(KERN_INFO, &pdev->dev,
297 "Detected SiS 180/181 chipset in SATA mode\n");
292 port2_start = 64; 298 port2_start = 64;
293 } 299 }
294 else { 300 else {
295 printk(KERN_INFO "sata_sis: Detected SiS 180/181 chipset in combined mode\n"); 301 dev_printk(KERN_INFO, &pdev->dev,
302 "Detected SiS 180/181 chipset in combined mode\n");
296 port2_start=0; 303 port2_start=0;
297 } 304 }
298 } 305 }
299 else { 306 else {
300 printk(KERN_INFO "sata_sis: Detected SiS 182 chipset\n"); 307 dev_printk(KERN_INFO, &pdev->dev, "Detected SiS 182 chipset\n");
301 port2_start = 0x20; 308 port2_start = 0x20;
302 } 309 }
303 310