diff options
Diffstat (limited to 'drivers/usb/storage/debug.c')
-rw-r--r-- | drivers/usb/storage/debug.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/usb/storage/debug.c b/drivers/usb/storage/debug.c index e08f64780e30..66a684a29938 100644 --- a/drivers/usb/storage/debug.c +++ b/drivers/usb/storage/debug.c | |||
@@ -164,10 +164,10 @@ void usb_stor_show_sense(const struct us_data *us, | |||
164 | unsigned char asc, | 164 | unsigned char asc, |
165 | unsigned char ascq) | 165 | unsigned char ascq) |
166 | { | 166 | { |
167 | const char *what, *keystr; | 167 | const char *what, *keystr, *fmt; |
168 | 168 | ||
169 | keystr = scsi_sense_key_string(key); | 169 | keystr = scsi_sense_key_string(key); |
170 | what = scsi_extd_sense_format(asc, ascq); | 170 | what = scsi_extd_sense_format(asc, ascq, &fmt); |
171 | 171 | ||
172 | if (keystr == NULL) | 172 | if (keystr == NULL) |
173 | keystr = "(Unknown Key)"; | 173 | keystr = "(Unknown Key)"; |
@@ -175,8 +175,10 @@ void usb_stor_show_sense(const struct us_data *us, | |||
175 | what = "(unknown ASC/ASCQ)"; | 175 | what = "(unknown ASC/ASCQ)"; |
176 | 176 | ||
177 | usb_stor_dbg(us, "%s: ", keystr); | 177 | usb_stor_dbg(us, "%s: ", keystr); |
178 | US_DEBUGPX(what, ascq); | 178 | if (fmt) |
179 | US_DEBUGPX("\n"); | 179 | US_DEBUGPX("%s (%s%x)\n", what, fmt, ascq); |
180 | else | ||
181 | US_DEBUGPX("%s\n", what); | ||
180 | } | 182 | } |
181 | 183 | ||
182 | int usb_stor_dbg(const struct us_data *us, const char *fmt, ...) | 184 | int usb_stor_dbg(const struct us_data *us, const char *fmt, ...) |