From d8196ed2181b4595eaf464a5bcbddb6c28649a39 Mon Sep 17 00:00:00 2001 From: Mike Christie Date: Wed, 30 May 2007 12:57:25 -0500 Subject: [SCSI] iscsi class, iscsi_tcp, iser, qla4xxx: add netdevname sysfs attr iSCSI must support software iscsi (iscsi_tcp, iser), hardware iscsi (qla4xxx), and partial offload (broadcom). To be able to allow each stack or driver or port (virtual or physical) to be able to log into the same target portal we use the initiator tuple [[HWADDRESS | NETDEVNAME], INITIATOR_NAME] and the target tuple [TARGETNAME, CONN_ADDRESS, CONN_PORT] to id a session. This patch adds the netdev name, which is used by software iscsi when it binds a session to a netdevice using the SO_BINDTODEVICE sock opt. It cannot use HWADDRESS because if someone did vlans then the same netdevice will have the same mac and the initiator,target id will not be unique. Signed-off-by: Mike Christie Cc: Roland Dreier Cc: David C Somayajulu Signed-off-by: James Bottomley --- include/scsi/libiscsi.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include/scsi/libiscsi.h') diff --git a/include/scsi/libiscsi.h b/include/scsi/libiscsi.h index eea33f7b1544..3f631b08a1ab 100644 --- a/include/scsi/libiscsi.h +++ b/include/scsi/libiscsi.h @@ -228,8 +228,9 @@ struct iscsi_session { char *password_in; char *targetname; char *initiatorname; - /* hw address being used for iscsi connection */ + /* hw address or netdev iscsi connection is bound to */ char *hwaddress; + char *netdev; /* control data */ struct iscsi_transport *tt; struct Scsi_Host *host; -- cgit v1.2.3-59-g8ed1b