scsi: pm80xx: Squashed logging cleanup changes
The default logging doesn't include the device name, so it's difficult to determine which controller is being logged about in error scenarios. The logging level was only settable via sysfs, which made it inconvenient for actual debugging. This changes the default to only cover error handling. Link: https://lore.kernel.org/r/20191114100910.6153-6-deepak.ukey@microchip.com Acked-by: Jack Wang <jinpu.wang@cloud.ionos.com> Signed-off-by: peter chang <dpf@google.com> Signed-off-by: Deepak Ukey <deepak.ukey@microchip.com> Signed-off-by: Viswas G <Viswas.G@microchip.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:

committed by
Martin K. Petersen

parent
4daf1ef3c6
commit
7370672dc3
@@ -66,8 +66,11 @@
|
||||
#define PM8001_EH_LOGGING 0x10 /* libsas EH function logging*/
|
||||
#define PM8001_IOCTL_LOGGING 0x20 /* IOCTL message logging */
|
||||
#define PM8001_MSG_LOGGING 0x40 /* misc message logging */
|
||||
#define pm8001_printk(format, arg...) printk(KERN_INFO "pm80xx %s %d:" \
|
||||
format, __func__, __LINE__, ## arg)
|
||||
#define PM8001_DEV_LOGGING 0x80 /* development message logging */
|
||||
#define PM8001_DEVIO_LOGGING 0x100 /* development io message logging */
|
||||
#define PM8001_IOERR_LOGGING 0x200 /* development io err message logging */
|
||||
#define pm8001_printk(format, arg...) pr_info("%s:: %s %d:" \
|
||||
format, pm8001_ha->name, __func__, __LINE__, ## arg)
|
||||
#define PM8001_CHECK_LOGGING(HBA, LEVEL, CMD) \
|
||||
do { \
|
||||
if (unlikely(HBA->logging_level & LEVEL)) \
|
||||
@@ -97,6 +100,14 @@ do { \
|
||||
#define PM8001_MSG_DBG(HBA, CMD) \
|
||||
PM8001_CHECK_LOGGING(HBA, PM8001_MSG_LOGGING, CMD)
|
||||
|
||||
#define PM8001_DEV_DBG(HBA, CMD) \
|
||||
PM8001_CHECK_LOGGING(HBA, PM8001_DEV_LOGGING, CMD)
|
||||
|
||||
#define PM8001_DEVIO_DBG(HBA, CMD) \
|
||||
PM8001_CHECK_LOGGING(HBA, PM8001_DEVIO_LOGGING, CMD)
|
||||
|
||||
#define PM8001_IOERR_DBG(HBA, CMD) \
|
||||
PM8001_CHECK_LOGGING(HBA, PM8001_IOERR_LOGGING, CMD)
|
||||
|
||||
#define PM8001_USE_TASKLET
|
||||
#define PM8001_USE_MSIX
|
||||
|
Reference in New Issue
Block a user