[SCSI] Add target alloc/destroy callbacks to the host template
This gives the HBA driver notice when a target is created and destroyed to allow it to manage its own target based allocations accordingly. This is a much reduced verson of the original patch sent in by James.Smart@Emulex.com Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
This commit is contained in:
committed by
James Bottomley
parent
631e8a1398
commit
a283bd37d0
@@ -154,7 +154,9 @@ struct scsi_target {
|
||||
unsigned int id; /* target id ... replace
|
||||
* scsi_device.id eventually */
|
||||
unsigned long create:1; /* signal that it needs to be added */
|
||||
unsigned long starget_data[0];
|
||||
void *hostdata; /* available to low-level driver */
|
||||
unsigned long starget_data[0]; /* for the transport */
|
||||
/* starget_data must be the last element!!!! */
|
||||
} __attribute__((aligned(sizeof(unsigned long))));
|
||||
|
||||
#define to_scsi_target(d) container_of(d, struct scsi_target, dev)
|
||||
|
Reference in New Issue
Block a user