From: Robert LeBlanc <robert-4JaGZRWAfWbajFs6igw21g@public.gmane.org>
To: lduncan-IBi9RG/b67k@public.gmane.org
Cc: cleech-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
jejb-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org,
martin.petersen-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org,
open-iscsi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org,
linux-scsi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
ogerlitz-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org,
sagi-NQWnxTmZq1alnMjI0IkVqw@public.gmane.org,
roid-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org,
dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
sean.hefty-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org,
hal.rosenstock-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
subbu.seetharaman-dY08KVG/lbpWk0Htik3J/w@public.gmane.org,
ketan.mukadam-dY08KVG/lbpWk0Htik3J/w@public.gmane.org,
jitendra.bhivare-dY08KVG/lbpWk0Htik3J/w@public.gmane.org,
QLogic-Storage-Upstream-h88ZbnxC6KDQT0dZR+AlfA@public.gmane.org,
varun-ut6Up61K2wZBDgjK7y7TUQ@public.gmane.org,
Robert LeBlanc <robert-4JaGZRWAfWbajFs6igw21g@public.gmane.org>
Subject: [PATCH 1/7] scsi/scsi_transport_iscsi: Add iface struct to kernel.
Date: Tue, 6 Jun 2017 12:07:11 -0600 [thread overview]
Message-ID: <20170606180717.5007-2-robert@leblancnet.us> (raw)
In-Reply-To: <20170606180717.5007-1-robert-4JaGZRWAfWbajFs6igw21g@public.gmane.org>
Allow the userspace iscsiadm to pass the iface struct of the connection
so that the underlying driver can use what is most appropriate to create
the iSCSI connection.
Signed-off-by: Robert LeBlanc <robert-4JaGZRWAfWbajFs6igw21g@public.gmane.org>
---
include/scsi/scsi_transport_iscsi.h | 95 +++++++++++++++++++++++++++++++++++++
1 file changed, 95 insertions(+)
diff --git a/include/scsi/scsi_transport_iscsi.h b/include/scsi/scsi_transport_iscsi.h
index 6183d20a01fb..26fe284daf9a 100644
--- a/include/scsi/scsi_transport_iscsi.h
+++ b/include/scsi/scsi_transport_iscsi.h
@@ -37,6 +37,7 @@ struct iscsi_cls_conn;
struct iscsi_conn;
struct iscsi_task;
struct sockaddr;
+struct iface_rec;
struct iscsi_iface;
struct bsg_job;
struct iscsi_bus_flash_session;
@@ -291,6 +292,100 @@ struct iscsi_endpoint {
struct iscsi_cls_conn *conn;
};
+/* max len of interface */
+#define ISCSI_MAX_IFACE_LEN 65
+#define NI_MAXHOST 1025
+#define ISCSI_HWADDRESS_BUF_SIZE 18
+#define ISCSI_TRANSPORT_NAME_MAXLEN 16
+#define ISCSI_MAX_STR_LEN 80
+
+struct iface_rec {
+ struct list_head list;
+ /* iscsi iface record name */
+ char name[ISCSI_MAX_IFACE_LEN];
+ uint32_t iface_num;
+ /* network layer iface name (eth0) */
+ char netdev[IFNAMSIZ];
+ char ipaddress[NI_MAXHOST];
+ char subnet_mask[NI_MAXHOST];
+ char gateway[NI_MAXHOST];
+ char bootproto[ISCSI_MAX_STR_LEN];
+ char ipv6_linklocal[NI_MAXHOST];
+ char ipv6_router[NI_MAXHOST];
+ char ipv6_autocfg[NI_MAXHOST];
+ char linklocal_autocfg[NI_MAXHOST];
+ char router_autocfg[NI_MAXHOST];
+ uint16_t vlan_id;
+ uint8_t vlan_priority;
+ char vlan_state[ISCSI_MAX_STR_LEN];
+ char state[ISCSI_MAX_STR_LEN]; /* 0 = disable,
+ * 1 = enable */
+ uint16_t mtu;
+ uint16_t port;
+ char delayed_ack[ISCSI_MAX_STR_LEN];
+ char nagle[ISCSI_MAX_STR_LEN];
+ char tcp_wsf_state[ISCSI_MAX_STR_LEN];
+ uint8_t tcp_wsf;
+ uint8_t tcp_timer_scale;
+ char tcp_timestamp[ISCSI_MAX_STR_LEN];
+ char dhcp_dns[ISCSI_MAX_STR_LEN];
+ char dhcp_slp_da[ISCSI_MAX_STR_LEN];
+ char tos_state[ISCSI_MAX_STR_LEN];
+ uint8_t tos;
+ char gratuitous_arp[ISCSI_MAX_STR_LEN];
+ char dhcp_alt_client_id_state[ISCSI_MAX_STR_LEN];
+ char dhcp_alt_client_id[ISCSI_MAX_STR_LEN];
+ char dhcp_req_vendor_id_state[ISCSI_MAX_STR_LEN];
+ char dhcp_vendor_id_state[ISCSI_MAX_STR_LEN];
+ char dhcp_vendor_id[ISCSI_MAX_STR_LEN];
+ char dhcp_learn_iqn[ISCSI_MAX_STR_LEN];
+ char fragmentation[ISCSI_MAX_STR_LEN];
+ char incoming_forwarding[ISCSI_MAX_STR_LEN];
+ uint8_t ttl;
+ char gratuitous_neighbor_adv[ISCSI_MAX_STR_LEN];
+ char redirect[ISCSI_MAX_STR_LEN];
+ char mld[ISCSI_MAX_STR_LEN];
+ uint32_t flow_label;
+ uint32_t traffic_class;
+ uint8_t hop_limit;
+ uint32_t nd_reachable_tmo;
+ uint32_t nd_rexmit_time;
+ uint32_t nd_stale_tmo;
+ uint8_t dup_addr_detect_cnt;
+ uint32_t router_adv_link_mtu;
+ uint16_t def_task_mgmt_tmo;
+ char header_digest[ISCSI_MAX_STR_LEN];
+ char data_digest[ISCSI_MAX_STR_LEN];
+ char immediate_data[ISCSI_MAX_STR_LEN];
+ char initial_r2t[ISCSI_MAX_STR_LEN];
+ char data_seq_inorder[ISCSI_MAX_STR_LEN];
+ char data_pdu_inorder[ISCSI_MAX_STR_LEN];
+ uint8_t erl;
+ uint32_t max_recv_dlength;
+ uint32_t first_burst_len;
+ uint16_t max_out_r2t;
+ uint32_t max_burst_len;
+ char chap_auth[ISCSI_MAX_STR_LEN];
+ char bidi_chap[ISCSI_MAX_STR_LEN];
+ char strict_login_comp[ISCSI_MAX_STR_LEN];
+ char discovery_auth[ISCSI_MAX_STR_LEN];
+ char discovery_logout[ISCSI_MAX_STR_LEN];
+ char port_state[ISCSI_MAX_STR_LEN];
+ char port_speed[ISCSI_MAX_STR_LEN];
+ /*
+ * TODO: we may have to make this bigger and interconnect
+ * specific for infiniband
+ */
+ char hwaddress[ISCSI_HWADDRESS_BUF_SIZE];
+ char transport_name[ISCSI_TRANSPORT_NAME_MAXLEN];
+ /*
+ * This is only used for boot now, but the iser guys
+ * can use this for their virtualization idea.
+ */
+ char alias[TARGET_NAME_MAXLEN + 1];
+ char iname[TARGET_NAME_MAXLEN + 1];
+};
+
struct iscsi_iface {
struct device dev;
struct iscsi_transport *transport;
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2017-06-06 18:07 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-06 18:07 [PATCH 0/7] Enable iSCSI offload drivers to use information from iface Robert LeBlanc
[not found] ` <20170606180717.5007-1-robert-4JaGZRWAfWbajFs6igw21g@public.gmane.org>
2017-06-06 18:07 ` Robert LeBlanc [this message]
[not found] ` <20170606180717.5007-2-robert-4JaGZRWAfWbajFs6igw21g@public.gmane.org>
2017-06-08 12:29 ` [PATCH 1/7] scsi/scsi_transport_iscsi: Add iface struct to kernel kbuild test robot
2017-06-06 18:07 ` [PATCH 2/7] scsi/scsi_transport_iscsi: Update ep_connect to include iface Robert LeBlanc
[not found] ` <20170606180717.5007-3-robert-4JaGZRWAfWbajFs6igw21g@public.gmane.org>
2017-06-08 12:24 ` kbuild test robot
2017-06-08 12:53 ` kbuild test robot
2017-06-06 18:07 ` [PATCH 3/7] ib/iSER: Add binding to source IP address Robert LeBlanc
2017-06-06 18:07 ` [PATCH 4/7] scsi/be2iscsi: Update beiscsi_ep_connect to accept iface and sockaddr_storage Robert LeBlanc
2017-06-06 18:07 ` [PATCH 5/7] scsi/bnx2i: Update bnx2i_ep_connect " Robert LeBlanc
2017-06-06 18:07 ` [PATCH 6/7] scsi/cxgbi: Update cxgbi_ep_connect " Robert LeBlanc
2017-06-06 18:07 ` [PATCH 7/7] scsi/qla4xxx: Update qla4xxx_ep_connect " Robert LeBlanc
2017-06-07 8:09 ` [PATCH 0/7] Enable iSCSI offload drivers to use information from iface Hannes Reinecke
2017-06-07 16:28 ` Chris Leech
2017-06-07 18:30 ` Robert LeBlanc
[not found] ` <CAANLjFomYCEmjfE7HLAsE7SgVqBKH8KSxYzFqxuV7t8as8+-ZQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-06-13 16:49 ` Robert LeBlanc
2017-06-14 9:20 ` Rangankar, Manish
[not found] ` <D566FD10.3ABC0%manish.rangankar-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org>
2017-06-14 16:47 ` Robert LeBlanc
2017-07-24 18:32 ` Robert LeBlanc
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170606180717.5007-2-robert@leblancnet.us \
--to=robert-4jagzrwafwbajfs6igw21g@public.gmane.org \
--cc=QLogic-Storage-Upstream-h88ZbnxC6KDQT0dZR+AlfA@public.gmane.org \
--cc=cleech-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
--cc=dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
--cc=hal.rosenstock-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=jejb-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org \
--cc=jitendra.bhivare-dY08KVG/lbpWk0Htik3J/w@public.gmane.org \
--cc=ketan.mukadam-dY08KVG/lbpWk0Htik3J/w@public.gmane.org \
--cc=lduncan-IBi9RG/b67k@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-scsi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=martin.petersen-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org \
--cc=ogerlitz-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
--cc=open-iscsi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
--cc=roid-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
--cc=sagi-NQWnxTmZq1alnMjI0IkVqw@public.gmane.org \
--cc=sean.hefty-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
--cc=subbu.seetharaman-dY08KVG/lbpWk0Htik3J/w@public.gmane.org \
--cc=varun-ut6Up61K2wZBDgjK7y7TUQ@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox