SCSI: convert struct class_device to struct device
[firefly-linux-kernel-4.4.55.git] / drivers / infiniband / ulp / srp / ib_srp.h
index 1d53c7bc368f5d8fa0e2f10f0a1865eadafae6af..63d2ae72406181338dc248c6554bf341205bee1e 100644 (file)
@@ -54,6 +54,7 @@ enum {
 
        SRP_PORT_REDIRECT       = 1,
        SRP_DLID_REDIRECT       = 2,
+       SRP_STALE_CONN          = 3,
 
        SRP_MAX_LUN             = 512,
        SRP_DEF_SG_TABLESIZE    = 12,
@@ -79,6 +80,11 @@ enum srp_target_state {
        SRP_TARGET_REMOVED
 };
 
+enum srp_request_type {
+       SRP_REQ_NORMAL,
+       SRP_REQ_TASK_MGMT,
+};
+
 struct srp_device {
        struct list_head        dev_list;
        struct ib_device       *dev;
@@ -91,9 +97,9 @@ struct srp_device {
 };
 
 struct srp_host {
-       struct srp_device      *dev;
+       struct srp_device      *srp_dev;
        u8                      port;
-       struct class_device     class_dev;
+       struct device           dev;
        struct list_head        target_list;
        spinlock_t              target_lock;
        struct completion       released;
@@ -106,11 +112,6 @@ struct srp_request {
        struct srp_iu          *cmd;
        struct srp_iu          *tsk_mgmt;
        struct ib_pool_fmr     *fmr;
-       /*
-        * Fake scatterlist used when scmnd->use_sg==0.  Can be killed
-        * when the SCSI midlayer no longer generates non-SG commands.
-        */
-       struct scatterlist      fake_sg;
        struct completion       done;
        short                   index;
        u8                      cmd_done;