Skip to content
  1. Mar 16, 2011
    • David Dillow's avatar
      IB/srp: add support for indirect tables that don't fit in SRP_CMD · c07d424d
      David Dillow authored
      
      
      This allows us to guarantee the ability to submit up to 8 MB requests
      based on the current value of SCSI_MAX_SG_CHAIN_SEGMENTS. While FMR will
      usually condense the requests into 8 SG entries, it is imperative that
      the target support external tables in case the FMR mapping fails or is
      not supported.
      
      We add a safety valve to allow targets without the needed support to
      reap the benefits of the large tables, but fail in a manner that lets
      the user know that the data didn't make it to the device. The user must
      add "allow_ext_sg=1" to the target parameters to indicate that the
      target has the needed support.
      
      If indirect_sg_entries is not specified in the modules options, then
      the sg_tablesize for the target will default to cmd_sg_entries unless
      overridden by the target options.
      
      Signed-off-by: default avatarDavid Dillow <dillowda@ornl.gov>
      c07d424d
    • David Dillow's avatar
      IB/srp: rework mapping engine to use multiple FMR entries · 8f26c9ff
      David Dillow authored
      
      
      Instead of forcing all of the S/G entries to fit in one FMR, and falling
      back to indirect descriptors if that fails, allow the use of as many
      FMRs as needed to map the request. This lays the groundwork for allowing
      indirect descriptor tables that are larger than can fit in the command
      IU, but should marginally improve performance now by reducing the number
      of indirect descriptors needed.
      
      We increase the minimum page size for the FMR pool to 4K, as larger
      pages help increase the coverage of each FMR, and it is rare that the
      kernel would send down a request with scattered 512 byte fragments.
      
      This patch also move some of the target initialization code afte the
      parsing of options, to keep it together with the new code that needs to
      allocate memory based on the options given.
      
      Signed-off-by: default avatarDavid Dillow <dillowda@ornl.gov>
      8f26c9ff
    • David Dillow's avatar
      IB/srp: allow sg_tablesize to be set for each target · 49248644
      David Dillow authored
      
      
      Different configurations of target software allow differing max sizes of
      the command IU. Allowing this to be changed per-target allows all
      targets on an initiator to get an optimal setting.
      
      We deprecate srp_sg_tablesize and replace it with cmd_sg_entries in
      preparation for allowing more indirect descriptors than can fit in the
      IU.
      
      Signed-off-by: default avatarDavid Dillow <dillowda@ornl.gov>
      49248644
    • David Dillow's avatar
      IB/srp: move IB CM setup completion into its own function · 961e0be8
      David Dillow authored
      
      
      This is to clean up prior to further changes.
      
      Signed-off-by: default avatarDavid Dillow <dillowda@ornl.gov>
      961e0be8
    • David Dillow's avatar
      IB/srp: always avoid non-zero offsets into an FMR · 8c4037b5
      David Dillow authored
      
      
      It is unclear exactly how this code works around Mellanox SRP targets,
      or if the problem is on the target side or in the HCA itself. In an
      abundance of caution, we should always enable the workaround.
      
      Signed-off-by: default avatarDavid Dillow <dillowda@ornl.gov>
      8c4037b5
  2. Mar 15, 2011