diff options
Diffstat (limited to 'drivers/s390/scsi')
-rw-r--r-- | drivers/s390/scsi/zfcp_dbf.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/s390/scsi/zfcp_dbf.c b/drivers/s390/scsi/zfcp_dbf.c index 5019d7b738bc..658053c74707 100644 --- a/drivers/s390/scsi/zfcp_dbf.c +++ b/drivers/s390/scsi/zfcp_dbf.c | |||
@@ -179,6 +179,9 @@ void zfcp_hba_dbf_event_fsf_response(struct zfcp_fsf_req *fsf_req) | |||
179 | (fsf_req->fsf_command == FSF_QTCB_OPEN_LUN)) { | 179 | (fsf_req->fsf_command == FSF_QTCB_OPEN_LUN)) { |
180 | strncpy(rec->tag2, "open", ZFCP_DBF_TAG_SIZE); | 180 | strncpy(rec->tag2, "open", ZFCP_DBF_TAG_SIZE); |
181 | level = 4; | 181 | level = 4; |
182 | } else if (qtcb->header.log_length) { | ||
183 | strncpy(rec->tag2, "qtcb", ZFCP_DBF_TAG_SIZE); | ||
184 | level = 5; | ||
182 | } else { | 185 | } else { |
183 | strncpy(rec->tag2, "norm", ZFCP_DBF_TAG_SIZE); | 186 | strncpy(rec->tag2, "norm", ZFCP_DBF_TAG_SIZE); |
184 | level = 6; | 187 | level = 6; |
@@ -250,6 +253,17 @@ void zfcp_hba_dbf_event_fsf_response(struct zfcp_fsf_req *fsf_req) | |||
250 | 253 | ||
251 | debug_event(adapter->hba_dbf, level, | 254 | debug_event(adapter->hba_dbf, level, |
252 | rec, sizeof(struct zfcp_hba_dbf_record)); | 255 | rec, sizeof(struct zfcp_hba_dbf_record)); |
256 | |||
257 | /* have fcp channel microcode fixed to use as little as possible */ | ||
258 | if (fsf_req->fsf_command != FSF_QTCB_FCP_CMND) { | ||
259 | /* adjust length skipping trailing zeros */ | ||
260 | char *buf = (char *)qtcb + qtcb->header.log_start; | ||
261 | int len = qtcb->header.log_length; | ||
262 | for (; len && !buf[len - 1]; len--); | ||
263 | zfcp_dbf_hexdump(adapter->hba_dbf, rec, sizeof(*rec), level, | ||
264 | buf, len); | ||
265 | } | ||
266 | |||
253 | spin_unlock_irqrestore(&adapter->hba_dbf_lock, flags); | 267 | spin_unlock_irqrestore(&adapter->hba_dbf_lock, flags); |
254 | } | 268 | } |
255 | 269 | ||