Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

scsi: lpfc: Introduce LOG_NODE_VERBOSE messaging flag

The preexisting LOG_NODE message flag frequently spams a subset of the same
log messages during normal FC driver operations. When analyzing driver
logs, this sometimes leads to difficulty in troubleshooting.

Because LOG_IP log message flag is unused, convert it to a new
LOG_NODE_VERBOSE flag. The LOG_NODE_VERBOSE shall specifically be used for
diagnosing issues that require precise ndlp tracking detail.

Signed-off-by: Justin Tee <justin.tee@broadcom.com>
Link: https://lore.kernel.org/r/20231009161812.97232-6-justintee8345@gmail.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>

authored by

Justin Tee and committed by
Martin K. Petersen
41c831bb a3c3c0a8

+5 -5
+4 -4
drivers/scsi/lpfc/lpfc_hbadisc.c
··· 5653 5653 ((uint32_t)ndlp->nlp_xri << 16) | 5654 5654 ((uint32_t)ndlp->nlp_type << 8) 5655 5655 ); 5656 - lpfc_printf_vlog(vport, KERN_INFO, LOG_NODE, 5656 + lpfc_printf_vlog(vport, KERN_INFO, LOG_NODE_VERBOSE, 5657 5657 "0929 FIND node DID " 5658 5658 "Data: x%px x%x x%x x%x x%x x%px\n", 5659 5659 ndlp, ndlp->nlp_DID, ··· 5700 5700 ((uint32_t)ndlp->nlp_type << 8) | 5701 5701 ((uint32_t)ndlp->nlp_rpi & 0xff)); 5702 5702 spin_unlock_irqrestore(shost->host_lock, iflags); 5703 - lpfc_printf_vlog(vport, KERN_INFO, LOG_NODE, 5704 - "2025 FIND node DID " 5703 + lpfc_printf_vlog(vport, KERN_INFO, LOG_NODE_VERBOSE, 5704 + "2025 FIND node DID MAPPED " 5705 5705 "Data: x%px x%x x%x x%x x%px\n", 5706 5706 ndlp, ndlp->nlp_DID, 5707 5707 ndlp->nlp_flag, data1, ··· 6467 6467 6468 6468 list_for_each_entry(ndlp, &vport->fc_nodes, nlp_listp) { 6469 6469 if (filter(ndlp, param)) { 6470 - lpfc_printf_vlog(vport, KERN_INFO, LOG_NODE, 6470 + lpfc_printf_vlog(vport, KERN_INFO, LOG_NODE_VERBOSE, 6471 6471 "3185 FIND node filter %ps DID " 6472 6472 "ndlp x%px did x%x flg x%x st x%x " 6473 6473 "xri x%x type x%x rpi x%x\n",
+1 -1
drivers/scsi/lpfc/lpfc_logmsg.h
··· 25 25 #define LOG_MBOX 0x00000004 /* Mailbox events */ 26 26 #define LOG_INIT 0x00000008 /* Initialization events */ 27 27 #define LOG_LINK_EVENT 0x00000010 /* Link events */ 28 - #define LOG_IP 0x00000020 /* IP traffic history */ 28 + #define LOG_NODE_VERBOSE 0x00000020 /* Node verbose events */ 29 29 #define LOG_FCP 0x00000040 /* FCP traffic history */ 30 30 #define LOG_NODE 0x00000080 /* Node table events */ 31 31 #define LOG_TEMP 0x00000100 /* Temperature sensor events */