diff options
author | Christoph Hellwig <hch@lst.de> | 2016-04-18 17:06:28 -0400 |
---|---|---|
committer | Doug Ledford <dledford@redhat.com> | 2016-05-05 12:41:24 -0400 |
commit | 9c674815d346305068b27bf03b5e86b659a1b111 (patch) | |
tree | b512f798dbdfb99a3cfb7ca971b04fc5c52a9000 /drivers/infiniband/hw/cxgb4 | |
parent | 4c8bb95921e9ac01b9dd0c3abbaf6514ce88af92 (diff) |
IB/iser: Fix max_sectors calculation
iSER currently has a couple places that set max_sectors in either the host
template or SCSI host, and all of them get it wrong.
This patch instead uses a single assignment that (hopefully) gets it right:
the max_sectors value must be derived from the number of segments in the
FR or FMR structure, but actually be one lower than the page size multiplied
by the number of sectors, as it has to handle the case of non-aligned I/O.
Without this I get trivial to reproduce hangs when running xfstests
(on XFS) over iSER to Linux targets.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Max Gurtovoy <maxg@mellanox.com>
Acked-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/hw/cxgb4')
0 files changed, 0 insertions, 0 deletions