diff options
| author | John Garry <john.garry@huawei.com> | 2018-11-15 05:20:31 -0500 |
|---|---|---|
| committer | Martin K. Petersen <martin.petersen@oracle.com> | 2018-11-15 14:37:06 -0500 |
| commit | 15ba7806c316ce88d45db7d12d32380f53c01a06 (patch) | |
| tree | 37af10a8d6ee1aad4267f1161726306c27a2d89d /drivers/scsi/libsas/sas_init.c | |
| parent | 71a4a9923122091be1167bac9379d5d1cfdb1153 (diff) | |
scsi: libsas: Drop SAS_DPRINTK() and revise logs levels
Like sas_printk() did previously, SAS_DPRINTK() offers little value now
that libsas logs already have the "sas" prefix through pr_fmt(fmt). So it
can be dropped.
However, after reviewing some logs in libsas, it is noticed that debug
level is too low in many instances.
So this change drops SAS_DPRINTK() and revises some logs to a more
appropriate level. However many stay at debug level, although some
are significantly promoted.
We add -DDEBUG for compilation so that we keep the debug messages by
default, as before.
All the pre-existing checkpatch errors for spanning messages across
multiple lines are also fixed.
Finally, all other references to printk() [apart from special formatting
in sas_ata.c] are removed and replaced with appropriate pr_xxx().
Suggested-by: Joe Perches <joe@perches.com>
Signed-off-by: John Garry <john.garry@huawei.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/libsas/sas_init.c')
| -rw-r--r-- | drivers/scsi/libsas/sas_init.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/scsi/libsas/sas_init.c b/drivers/scsi/libsas/sas_init.c index a3c25e22b939..221340ee8651 100644 --- a/drivers/scsi/libsas/sas_init.c +++ b/drivers/scsi/libsas/sas_init.c | |||
| @@ -128,19 +128,19 @@ int sas_register_ha(struct sas_ha_struct *sas_ha) | |||
| 128 | 128 | ||
| 129 | error = sas_register_phys(sas_ha); | 129 | error = sas_register_phys(sas_ha); |
| 130 | if (error) { | 130 | if (error) { |
| 131 | printk(KERN_NOTICE "couldn't register sas phys:%d\n", error); | 131 | pr_notice("couldn't register sas phys:%d\n", error); |
| 132 | return error; | 132 | return error; |
| 133 | } | 133 | } |
| 134 | 134 | ||
| 135 | error = sas_register_ports(sas_ha); | 135 | error = sas_register_ports(sas_ha); |
| 136 | if (error) { | 136 | if (error) { |
| 137 | printk(KERN_NOTICE "couldn't register sas ports:%d\n", error); | 137 | pr_notice("couldn't register sas ports:%d\n", error); |
| 138 | goto Undo_phys; | 138 | goto Undo_phys; |
| 139 | } | 139 | } |
| 140 | 140 | ||
| 141 | error = sas_init_events(sas_ha); | 141 | error = sas_init_events(sas_ha); |
| 142 | if (error) { | 142 | if (error) { |
| 143 | printk(KERN_NOTICE "couldn't start event thread:%d\n", error); | 143 | pr_notice("couldn't start event thread:%d\n", error); |
| 144 | goto Undo_ports; | 144 | goto Undo_ports; |
| 145 | } | 145 | } |
| 146 | 146 | ||
