aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/libsas/sas_task.c
diff options
context:
space:
mode:
authorJohn Garry <[email protected]>2018-11-15 10:20:31 +0000
committerMartin K. Petersen <[email protected]>2018-11-15 19:37:06 +0000
commit15ba7806c316ce88d45db7d12d32380f53c01a06 (patch)
tree37af10a8d6ee1aad4267f1161726306c27a2d89d /drivers/scsi/libsas/sas_task.c
parentscsi: libsas: Drop sas_printk() (diff)
downloadkernel-15ba7806c316ce88d45db7d12d32380f53c01a06.tar.gz
kernel-15ba7806c316ce88d45db7d12d32380f53c01a06.zip
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 <[email protected]> Signed-off-by: John Garry <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
Diffstat (limited to 'drivers/scsi/libsas/sas_task.c')
-rw-r--r--drivers/scsi/libsas/sas_task.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/scsi/libsas/sas_task.c b/drivers/scsi/libsas/sas_task.c
index d305c8f90ee9..c3b9befad4e6 100644
--- a/drivers/scsi/libsas/sas_task.c
+++ b/drivers/scsi/libsas/sas_task.c
@@ -26,11 +26,8 @@ void sas_ssp_task_response(struct device *dev, struct sas_task *task,
memcpy(tstat->buf, iu->sense_data, tstat->buf_valid_size);
if (iu->status != SAM_STAT_CHECK_CONDITION)
- dev_printk(KERN_WARNING, dev,
- "dev %llx sent sense data, but "
- "stat(%x) is not CHECK CONDITION\n",
- SAS_ADDR(task->dev->sas_addr),
- iu->status);
+ dev_warn(dev, "dev %llx sent sense data, but stat(%x) is not CHECK CONDITION\n",
+ SAS_ADDR(task->dev->sas_addr), iu->status);
}
else
/* when datapres contains corrupt/unknown value... */