diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/scsi/libfc.h | 36 |
1 files changed, 20 insertions, 16 deletions
diff --git a/include/scsi/libfc.h b/include/scsi/libfc.h index ef04a2c52b8c..efdb6ba310e5 100644 --- a/include/scsi/libfc.h +++ b/include/scsi/libfc.h | |||
@@ -59,47 +59,51 @@ do { \ | |||
59 | 59 | ||
60 | #define FC_LPORT_DBG(lport, fmt, args...) \ | 60 | #define FC_LPORT_DBG(lport, fmt, args...) \ |
61 | FC_CHECK_LOGGING(FC_LPORT_LOGGING, \ | 61 | FC_CHECK_LOGGING(FC_LPORT_LOGGING, \ |
62 | printk(KERN_INFO "lport: %6x: " fmt, \ | 62 | printk(KERN_INFO "host%u: lport %6x: " fmt, \ |
63 | fc_host_port_id(lport->host), ##args)) | 63 | (lport)->host->host_no, \ |
64 | fc_host_port_id((lport)->host), ##args)) | ||
64 | 65 | ||
65 | #define FC_DISC_DBG(disc, fmt, args...) \ | 66 | #define FC_DISC_DBG(disc, fmt, args...) \ |
66 | FC_CHECK_LOGGING(FC_DISC_LOGGING, \ | 67 | FC_CHECK_LOGGING(FC_DISC_LOGGING, \ |
67 | printk(KERN_INFO "disc: %6x: " fmt, \ | 68 | printk(KERN_INFO "host%u: disc: " fmt, \ |
68 | fc_host_port_id(disc->lport->host), \ | 69 | (disc)->lport->host->host_no, \ |
69 | ##args)) | 70 | ##args)) |
70 | 71 | ||
72 | #define FC_RPORT_ID_DBG(lport, port_id, fmt, args...) \ | ||
73 | FC_CHECK_LOGGING(FC_RPORT_LOGGING, \ | ||
74 | printk(KERN_INFO "host%u: rport %6x: " fmt, \ | ||
75 | (lport)->host->host_no, \ | ||
76 | (port_id), ##args)) | ||
77 | |||
71 | #define FC_RPORT_DBG(rport, fmt, args...) \ | 78 | #define FC_RPORT_DBG(rport, fmt, args...) \ |
72 | do { \ | 79 | do { \ |
73 | struct fc_rport_libfc_priv *rdata = rport->dd_data; \ | 80 | struct fc_rport_libfc_priv *rdata = rport->dd_data; \ |
74 | struct fc_lport *lport = rdata->local_port; \ | 81 | struct fc_lport *lport = rdata->local_port; \ |
75 | FC_CHECK_LOGGING(FC_RPORT_LOGGING, \ | 82 | FC_RPORT_ID_DBG(lport, rport->port_id, fmt, ##args); \ |
76 | printk(KERN_INFO "rport: %6x: %6x: " fmt, \ | ||
77 | fc_host_port_id(lport->host), \ | ||
78 | rport->port_id, ##args)); \ | ||
79 | } while (0) | 83 | } while (0) |
80 | 84 | ||
81 | #define FC_FCP_DBG(pkt, fmt, args...) \ | 85 | #define FC_FCP_DBG(pkt, fmt, args...) \ |
82 | FC_CHECK_LOGGING(FC_FCP_LOGGING, \ | 86 | FC_CHECK_LOGGING(FC_FCP_LOGGING, \ |
83 | printk(KERN_INFO "fcp: %6x: %6x: " fmt, \ | 87 | printk(KERN_INFO "host%u: fcp: %6x: " fmt, \ |
84 | fc_host_port_id(pkt->lp->host), \ | 88 | (pkt)->lp->host->host_no, \ |
85 | pkt->rport->port_id, ##args)) | 89 | pkt->rport->port_id, ##args)) |
86 | 90 | ||
87 | #define FC_EM_DBG(em, fmt, args...) \ | 91 | #define FC_EM_DBG(em, fmt, args...) \ |
88 | FC_CHECK_LOGGING(FC_EM_LOGGING, \ | 92 | FC_CHECK_LOGGING(FC_EM_LOGGING, \ |
89 | printk(KERN_INFO "em: %6x: " fmt, \ | 93 | printk(KERN_INFO "host%u: em: " fmt, \ |
90 | fc_host_port_id(em->lp->host), \ | 94 | (em)->lp->host->host_no, \ |
91 | ##args)) | 95 | ##args)) |
92 | 96 | ||
93 | #define FC_EXCH_DBG(exch, fmt, args...) \ | 97 | #define FC_EXCH_DBG(exch, fmt, args...) \ |
94 | FC_CHECK_LOGGING(FC_EXCH_LOGGING, \ | 98 | FC_CHECK_LOGGING(FC_EXCH_LOGGING, \ |
95 | printk(KERN_INFO "exch: %6x: %4x: " fmt, \ | 99 | printk(KERN_INFO "host%u: xid %4x: " fmt, \ |
96 | fc_host_port_id(exch->lp->host), \ | 100 | (exch)->lp->host->host_no, \ |
97 | exch->xid, ##args)) | 101 | exch->xid, ##args)) |
98 | 102 | ||
99 | #define FC_SCSI_DBG(lport, fmt, args...) \ | 103 | #define FC_SCSI_DBG(lport, fmt, args...) \ |
100 | FC_CHECK_LOGGING(FC_SCSI_LOGGING, \ | 104 | FC_CHECK_LOGGING(FC_SCSI_LOGGING, \ |
101 | printk(KERN_INFO "scsi: %6x: " fmt, \ | 105 | printk(KERN_INFO "host%u: scsi: " fmt, \ |
102 | fc_host_port_id(lport->host), ##args)) | 106 | (lport)->host->host_no, ##args)) |
103 | 107 | ||
104 | /* | 108 | /* |
105 | * libfc error codes | 109 | * libfc error codes |