cxgbit: Use type ISCSI_CXGBIT + cxgbit tpg_np attribute
authorNicholas Bellinger <nab@linux-iscsi.org>
Sun, 15 May 2016 05:28:51 +0000 (22:28 -0700)
committerNicholas Bellinger <nab@linux-iscsi.org>
Tue, 17 May 2016 05:23:59 +0000 (22:23 -0700)
Instead of having cxgbit use type ISCSI_HW_OFFLOAD + 'hw_offload'
tpg_np attribute, it should be using it's own driver specific
type + attribute

Cc: Varun Prakash <varun@chelsio.com>
Cc: Hariprasad Shenai <hariprasad@chelsio.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
drivers/target/iscsi/cxgbit/cxgbit_main.c
drivers/target/iscsi/iscsi_target_configfs.c
include/target/iscsi/iscsi_target_core.h

index c25f5313322ce9ae2064a5b0fad35d93dda346b2..60dccd02bd852e36e67b5a6d7340dc4f903ab734 100644 (file)
@@ -624,7 +624,7 @@ static enum target_prot_op cxgbit_get_sup_prot_ops(struct iscsi_conn *conn)
 
 static struct iscsit_transport cxgbit_transport = {
        .name                   = DRV_NAME,
-       .transport_type         = ISCSI_HW_OFFLOAD,
+       .transport_type         = ISCSI_CXGBIT,
        .rdma_shutdown          = false,
        .priv_size              = sizeof(struct cxgbit_cmd),
        .owner                  = THIS_MODULE,
index 33d811ac95390313abfc9e4b4b1001c66ab7b006..923c032f0b95f1efe2d1e12e90cb9086f3fd9346 100644 (file)
@@ -131,22 +131,22 @@ static ssize_t lio_target_np_iser_store(struct config_item *item,
 }
 CONFIGFS_ATTR(lio_target_np_, iser);
 
-static ssize_t lio_target_np_hw_offload_show(struct config_item *item, char *page)
+static ssize_t lio_target_np_cxgbit_show(struct config_item *item, char *page)
 {
-       return lio_target_np_driver_show(item, page, ISCSI_HW_OFFLOAD);
+       return lio_target_np_driver_show(item, page, ISCSI_CXGBIT);
 }
 
-static ssize_t lio_target_np_hw_offload_store(struct config_item *item,
-                                             const char *page, size_t count)
+static ssize_t lio_target_np_cxgbit_store(struct config_item *item,
+                                         const char *page, size_t count)
 {
        return lio_target_np_driver_store(item, page, count,
-                                         ISCSI_HW_OFFLOAD, "");
+                                         ISCSI_CXGBIT, "cxgbit");
 }
-CONFIGFS_ATTR(lio_target_np_, hw_offload);
+CONFIGFS_ATTR(lio_target_np_, cxgbit);
 
 static struct configfs_attribute *lio_target_portal_attrs[] = {
        &lio_target_np_attr_iser,
-       &lio_target_np_attr_hw_offload,
+       &lio_target_np_attr_cxgbit,
        NULL,
 };
 
index 110c1fde7c683ee9978f626d9b47edda6dabd84c..4ac24f5a3308a8c8bcec7c973433f1f714cda9b2 100644 (file)
@@ -74,7 +74,7 @@ enum iscsit_transport_type {
        ISCSI_IWARP_TCP                         = 3,
        ISCSI_IWARP_SCTP                        = 4,
        ISCSI_INFINIBAND                        = 5,
-       ISCSI_HW_OFFLOAD                        = 6,
+       ISCSI_CXGBIT                            = 6,
 };
 
 /* RFC-3720 7.1.4  Standard Connection State Diagram for a Target */