Re: [PATCH 2/8] sg: introduce sg_log macro

2018-10-24 Thread Martin K. Petersen
Hello Doug, > Examples please, preferably from the SCSI subsystem. If not, I'll do what > most other drivers do, drop all debug statements. $ git grep trace drivers/scsi/scsi* and $ less include/trace/events/scsi.h We currently only have trace points for command dispatch, completion, and a

Re: [PATCH 2/8] sg: introduce sg_log macro

2018-10-24 Thread Douglas Gilbert
On 2018-10-24 3:58 a.m., Martin K. Petersen wrote: Hi Doug, I'll follow what the scsi mid-level and the other ULDs do. IOW, no change. The debug messages they produce are quite helpful (to me, I use them a lot, and Tony B. has asked for more precision) and well-tuned to the SCSI subsystem

Re: [PATCH 2/8] sg: introduce sg_log macro

2018-10-23 Thread Martin K. Petersen
Hi Doug, > I'll follow what the scsi mid-level and the other ULDs do. IOW, no > change. The debug messages they produce are quite helpful (to me, I > use them a lot, and Tony B. has asked for more precision) and > well-tuned to the SCSI subsystem (e.g. telling us what sdp represents > in useful

Re: [PATCH 2/8] sg: introduce sg_log macro

2018-10-19 Thread Douglas Gilbert
On 2018-10-19 3:45 a.m., Johannes Thumshirn wrote: On 19/10/18 08:24, Douglas Gilbert wrote: [..] +/* + * Kernel needs to be built with CONFIG_SCSI_LOGGING to see log messages. + * 'depth' is a number between 1 (most severe) and 7 (most noisy, most + * information). All messages are logged as

Re: [PATCH 2/8] sg: introduce sg_log macro

2018-10-19 Thread Johannes Thumshirn
On 19/10/18 08:24, Douglas Gilbert wrote: [..] > +/* > + * Kernel needs to be built with CONFIG_SCSI_LOGGING to see log messages. > + * 'depth' is a number between 1 (most severe) and 7 (most noisy, most > + * information). All messages are logged as informational (KERN_INFO). In > + * the

[PATCH 2/8] sg: introduce sg_log macro

2018-10-19 Thread Douglas Gilbert
Introduce the SG_LOG macro to replace long-winded 'SCSI_LOG_TIMEOUT(3, sg_printk ...' debug messages. Use __func__ wherever appropriate to make the debug messages more portable. Signed-off-by: Douglas Gilbert --- drivers/scsi/sg.c | 162 +- 1 file