20 Oct, 2011

1 commit

  • Userspace was sending the priority/id part of the vlan tag
    and sysfs was displaying the id in the vlan file. This
    renames the vlan sysfs file to vlan_id to reflect that it
    was showing the id and to match the vlan_priority file.
    This also adds a ISCSI_NET_PARAM_VLAN_TAG iscsi nl command
    to relfect that we are sending down the vlan/priority
    part of the tag.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     

27 Aug, 2011

9 commits


31 Mar, 2011

1 commit


31 Dec, 2010

1 commit


28 Jul, 2010

1 commit


05 Dec, 2009

1 commit


05 Sep, 2009

1 commit


09 Jun, 2009

1 commit


24 May, 2009

1 commit

  • When we create the tcp/ip connection by calling ep_connect, we currently
    just go by the routing table info.

    I think there are two problems with this.

    1. Some drivers do not have access to a routing table. Some drivers like
    qla4xxx do not even know about other ports.

    2. If you have two initiator ports on the same subnet, the user may have
    set things up so that session1 was supposed to be run through port1. and
    session2 was supposed to be run through port2. It looks like we could
    end with both sessions going through one of the ports.

    Fixes for cxgb3i from Karen Xie.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     

30 Dec, 2008

2 commits

  • cxgb3i does not offload the processing of the header,
    but it will always process the padding. This patch
    adds a padding offload flag to detect when the LLD
    supports this.

    The patch also modifies the header processing so that
    we do not try to read/bypass the header dugest in the
    skb. cxgb3i will not include it with the header like
    with other offload cards.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • cxgb3i is unlike qla4xxx and bnx2i in that it does not offload entire
    scsi commands or iscsi sequences. Instead it only offloads the transfer
    of a ISCSI DATA_IN pdu's data, the digests and padding. This patch fixes up the
    iscsi tcp recv path so that it exports its skb recv processing so
    cxgb3i and other drivers can call them. All they have to do is pass
    the function the skb with the hdr or data pdu header and this function
    will do the rest.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     

13 Oct, 2008

2 commits

  • The segment->done functions return a iscsi error value which gives
    a lot more info than conn failed, so this patch has us return
    that value. I also add a new one for xmit failures.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • If the driver knows when hardware is removed like with cxgb3i,
    bnx2i, qla4xxx and iser then we will want to remove the sessions/devices
    that are bound to that device before removing the host.

    cxgb3i and in the future bnx2i will remove the host and that will
    remove all the sessions on the hba. iser can call iscsi_kill_session
    when it gets an event that indicates that a hca is removed.
    And when qla4xxx is hooked in to the lib (it is only hooked into
    the class right now) it can call iscsi remove host like the
    partial offload card drivers.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     

12 Jul, 2008

4 commits

  • This adds two new attrs used for creating initiator ports and
    binding sessions to hardware.

    The session level initiatorname:

    Since bnx2i does a scsi_host per host device, we need to add the
    iface initiator port settings on the session, so we can create
    multiple initiator ports (each with different inames) per device/scsi_host.

    The current iname reflects that qla4xxx can have one iname per hba, and we are
    allocating a host per session for software. The iname on the host will
    remain so we can export and set the hba level qla4xxx setting.

    The ifacename attr:

    To bind a session to a some peice of hardware in userspace we maintain
    some mappings, but during boot or iscsid restart (iscsid contains the user
    space part of the driver) we need to be able to figure out which of those
    host mappings abstractions maps to certain sessions. This patch adds
    a ifacename attr, which userspace can set to id the host side of the
    endpoint across pivot_roots and iscsid restarts.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • Add sysfs representation for the endpoint, so userspace can match the
    host and session to the endpoint. This will allow us to set the host's
    parent correctly at host creation time.

    The next patches will convert tcp and iser, and fix iser's dma_mask
    bug.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • bnx2i allocates a host per netdevice but will use libiscsi,
    so this unbinds the session from the host in that code.

    This will also be useful for the iser parent device dma settings
    fixes.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • iscsi offload (bnx2i and qla4xx) allocate a scsi host per hba,
    so the session creation path needs a shost/host_no argument.
    Software iscsi/iser will follow the same behabior as before
    where it allcoates a host per session, but in the future iser
    will probably look more like bnx2i where the host's parent is
    the hardware (rnic for iser and for bnx2i it is the nic), because
    it does not use a socket layer like how iscsi_tcp does.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     

12 Jan, 2008

3 commits

  • During root boot and shutdown the target could send us nops.
    At this time iscsid cannot be running, so the target will drop
    the session and the boot or shutdown will hang.

    To handle this and allow us to better control when to check the network
    this patch moves the nop handling to the kernel.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • We were using the device delete sysfs file to remove each device
    then logout. Now in 2.6.21 this will not work because
    the sysfs delete file returns immediately and does not wait for
    the device removal to complete. This causes a hang if a cache sync
    is needed during shutdown. Before .21, that approach had other
    problems, so this patch fixes the shutdown code so that we remove the target
    and unbind the session before logging out and shut down the session

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • This patch adds logical unit reset support. This should work for ib_iser,
    but I have not finished testing that driver so it is not hooked in yet.

    This patch also temporarily reverts the iscsi_tcp r2t write out patch.
    That code is completely rewritten in this patchset.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     

03 Jun, 2007

4 commits

  • 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

    Mike Christie
     
  • This patch exports the local address for the session. For
    qla4xxx this is the ip of the hba's port. For software
    this is the src addr of the socket.

    Signed-off-by: Mike Christie
    Cc: David C Somayajulu
    Signed-off-by: James Bottomley

    Mike Christie
     
  • Userspace will want to know what the driver/FW/HW capabilites
    when it comes to some operations like if the hardware can
    do discovery or if it can store iscsi info like what target
    was used for boot. This patch adds some new caps so userspace
    can tell if the driver supports hardware/fw based sendtargets
    discovery and if the hardware has some flash which may be
    holding or can contain some iscsi target info
    .
    Signed-off-by: Mike Christie
    Cc: David C Somayajulu
    Signed-off-by: James Bottomley

    Mike Christie
     
  • This patch allows us to set can_queue and cmds_per_lun from userspace
    when we create the session/host. From there we can set it on a per
    target basis. The patch fully converts iscsi_tcp, but only hooks
    up ib_iser for cmd_per_lun since it currently has a lots of preallocations
    based on can_queue.

    Signed-off-by: Mike Christie
    Cc: Roland Dreier
    Signed-off-by: James Bottomley

    Mike Christie
     

02 Jun, 2007

4 commits


29 Jun, 2006

2 commits

  • This patch adds or modifies the transport class functions
    used to notify userspace of session state events.

    We modify the session addition up event and add a destruction event
    to notify userspace of session creation, relogin and destruction.

    And we modify the conn error event to be sent by broadcast
    since multiple listeners may want to listen for it.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • Patch from david.somayajulu@qlogic.com:

    Add target discovery event. We may have a setup where the iscsi traffic
    is on a different netowrk than the other network traffic. In this case
    we will want to do discovery though the iscsi card. This patch adds
    a event to the transport class that can be used by hw iscsi cards that
    support this.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     

10 May, 2006

2 commits

  • debugged by Ming and Rohan:

    The problem Ming and Rohan debugged was that during a normal session
    login, open-iscsi is not incrementing the exp_statsn counter. It was
    stuck at zero. From the RFC, it looks like if the login response PDU has
    a successful status then we should be incrementing that value. Also from
    the RFC, it looks like if when we drop a connection then reconnect, we
    should be using the exp_statsn from the old connection in the next
    relogin attempt.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • add transport end point callbacks so iscsi drivers that cannot connect
    from userspace, like iscsi tcp, using sockets do not have to
    implement their own socket infrastructure.

    Signed-off-by: Or Gerlitz
    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Or Gerlitz