summaryrefslogtreecommitdiff
path: root/drivers/scsi/isci/remote_device.h
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2011-03-04 01:59:32 (GMT)
committerDan Williams <dan.j.williams@intel.com>2011-07-03 10:55:29 (GMT)
commitd9c37390c4f02153188a64a7a89fa6798dc3ffc2 (patch)
tree508f28b5b88348b2d989f479442cbd6813bd2b42 /drivers/scsi/isci/remote_device.h
parent6ad31fec306d532031b2f778f8656385df1b9d8f (diff)
downloadlinux-fsl-qoriq-d9c37390c4f02153188a64a7a89fa6798dc3ffc2.tar.xz
isci: preallocate remote devices
Until we synchronize against device removal this limits the damage of use after free bugs to the driver's own objects. Unless we implement reference counting we need to ensure at least a subset of a remote device is valid at all times. We follow the lead of other libsas drivers that also preallocate devices. This also enforces maximum remote device accounting at the lldd layer, but the core may still run out of RNC's before we hit this limit. Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/scsi/isci/remote_device.h')
-rw-r--r--drivers/scsi/isci/remote_device.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/isci/remote_device.h b/drivers/scsi/isci/remote_device.h
index 3c22137..f45a5f0 100644
--- a/drivers/scsi/isci/remote_device.h
+++ b/drivers/scsi/isci/remote_device.h
@@ -63,8 +63,8 @@ struct isci_remote_device {
enum isci_status status;
#define IDEV_START_PENDING 0
#define IDEV_STOP_PENDING 1
+ #define IDEV_ALLOCATED 2
unsigned long flags;
- struct completion *cmp;
struct isci_port *isci_port;
struct domain_device *domain_dev;
struct list_head node;