diff options
-rw-r--r-- | drivers/scsi/scsi_lib.c | 4 | ||||
-rw-r--r-- | drivers/scsi/scsi_scan.c | 2 | ||||
-rw-r--r-- | include/scsi/scsi_device.h | 6 |
3 files changed, 6 insertions, 6 deletions
diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c index 199b02452259..b0c59ae63a2f 100644 --- a/drivers/scsi/scsi_lib.c +++ b/drivers/scsi/scsi_lib.c | |||
@@ -526,7 +526,7 @@ static void scsi_run_queue(struct request_queue *q) | |||
526 | struct Scsi_Host *shost = sdev->host; | 526 | struct Scsi_Host *shost = sdev->host; |
527 | unsigned long flags; | 527 | unsigned long flags; |
528 | 528 | ||
529 | if (sdev->single_lun) | 529 | if (scsi_target(sdev)->single_lun) |
530 | scsi_single_lun_run(sdev); | 530 | scsi_single_lun_run(sdev); |
531 | 531 | ||
532 | spin_lock_irqsave(shost->host_lock, flags); | 532 | spin_lock_irqsave(shost->host_lock, flags); |
@@ -1559,7 +1559,7 @@ static void scsi_request_fn(struct request_queue *q) | |||
1559 | 1559 | ||
1560 | if (!scsi_host_queue_ready(q, shost, sdev)) | 1560 | if (!scsi_host_queue_ready(q, shost, sdev)) |
1561 | goto not_ready; | 1561 | goto not_ready; |
1562 | if (sdev->single_lun) { | 1562 | if (scsi_target(sdev)->single_lun) { |
1563 | if (scsi_target(sdev)->starget_sdev_user && | 1563 | if (scsi_target(sdev)->starget_sdev_user && |
1564 | scsi_target(sdev)->starget_sdev_user != sdev) | 1564 | scsi_target(sdev)->starget_sdev_user != sdev) |
1565 | goto not_ready; | 1565 | goto not_ready; |
diff --git a/drivers/scsi/scsi_scan.c b/drivers/scsi/scsi_scan.c index 7e8b2045ccfa..ada72af0a6dd 100644 --- a/drivers/scsi/scsi_scan.c +++ b/drivers/scsi/scsi_scan.c | |||
@@ -865,7 +865,7 @@ static int scsi_add_lun(struct scsi_device *sdev, unsigned char *inq_result, | |||
865 | sdev->no_start_on_add = 1; | 865 | sdev->no_start_on_add = 1; |
866 | 866 | ||
867 | if (*bflags & BLIST_SINGLELUN) | 867 | if (*bflags & BLIST_SINGLELUN) |
868 | sdev->single_lun = 1; | 868 | scsi_target(sdev)->single_lun = 1; |
869 | 869 | ||
870 | sdev->use_10_for_rw = 1; | 870 | sdev->use_10_for_rw = 1; |
871 | 871 | ||
diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h index 6c2d80b36aa1..45bb12b54175 100644 --- a/include/scsi/scsi_device.h +++ b/include/scsi/scsi_device.h | |||
@@ -122,9 +122,6 @@ struct scsi_device { | |||
122 | unsigned tagged_supported:1; /* Supports SCSI-II tagged queuing */ | 122 | unsigned tagged_supported:1; /* Supports SCSI-II tagged queuing */ |
123 | unsigned simple_tags:1; /* simple queue tag messages are enabled */ | 123 | unsigned simple_tags:1; /* simple queue tag messages are enabled */ |
124 | unsigned ordered_tags:1;/* ordered queue tag messages are enabled */ | 124 | unsigned ordered_tags:1;/* ordered queue tag messages are enabled */ |
125 | unsigned single_lun:1; /* Indicates we should only allow I/O to | ||
126 | * one of the luns for the device at a | ||
127 | * time. */ | ||
128 | unsigned was_reset:1; /* There was a bus reset on the bus for | 125 | unsigned was_reset:1; /* There was a bus reset on the bus for |
129 | * this device */ | 126 | * this device */ |
130 | unsigned expecting_cc_ua:1; /* Expecting a CHECK_CONDITION/UNIT_ATTN | 127 | unsigned expecting_cc_ua:1; /* Expecting a CHECK_CONDITION/UNIT_ATTN |
@@ -202,6 +199,9 @@ struct scsi_target { | |||
202 | unsigned int id; /* target id ... replace | 199 | unsigned int id; /* target id ... replace |
203 | * scsi_device.id eventually */ | 200 | * scsi_device.id eventually */ |
204 | unsigned int create:1; /* signal that it needs to be added */ | 201 | unsigned int create:1; /* signal that it needs to be added */ |
202 | unsigned int single_lun:1; /* Indicates we should only | ||
203 | * allow I/O to one of the luns | ||
204 | * for the device at a time. */ | ||
205 | unsigned int pdt_1f_for_no_lun; /* PDT = 0x1f */ | 205 | unsigned int pdt_1f_for_no_lun; /* PDT = 0x1f */ |
206 | /* means no lun present */ | 206 | /* means no lun present */ |
207 | 207 | ||