diff options
Diffstat (limited to 'include/scsi/scsi_device.h')
-rw-r--r-- | include/scsi/scsi_device.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h index 9dd37e2f5a84..c86e6ce143df 100644 --- a/include/scsi/scsi_device.h +++ b/include/scsi/scsi_device.h | |||
@@ -5,6 +5,7 @@ | |||
5 | #include <linux/list.h> | 5 | #include <linux/list.h> |
6 | #include <linux/spinlock.h> | 6 | #include <linux/spinlock.h> |
7 | #include <linux/workqueue.h> | 7 | #include <linux/workqueue.h> |
8 | #include <linux/blkdev.h> | ||
8 | #include <asm/atomic.h> | 9 | #include <asm/atomic.h> |
9 | 10 | ||
10 | struct request_queue; | 11 | struct request_queue; |
@@ -154,8 +155,11 @@ struct scsi_device { | |||
154 | #define sdev_printk(prefix, sdev, fmt, a...) \ | 155 | #define sdev_printk(prefix, sdev, fmt, a...) \ |
155 | dev_printk(prefix, &(sdev)->sdev_gendev, fmt, ##a) | 156 | dev_printk(prefix, &(sdev)->sdev_gendev, fmt, ##a) |
156 | 157 | ||
157 | #define scmd_printk(prefix, scmd, fmt, a...) \ | 158 | #define scmd_printk(prefix, scmd, fmt, a...) \ |
158 | dev_printk(prefix, &(scmd)->device->sdev_gendev, fmt, ##a) | 159 | (scmd)->request->rq_disk ? \ |
160 | sdev_printk(prefix, (scmd)->device, "[%s] " fmt, \ | ||
161 | (scmd)->request->rq_disk->disk_name, ##a) : \ | ||
162 | sdev_printk(prefix, (scmd)->device, fmt, ##a) | ||
159 | 163 | ||
160 | enum scsi_target_state { | 164 | enum scsi_target_state { |
161 | STARGET_RUNNING = 1, | 165 | STARGET_RUNNING = 1, |