aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/linux/nvme-fc-driver.h
diff options
context:
space:
mode:
authorJames Smart <jsmart2021@gmail.com>2017-07-31 13:21:14 -0700
committerSagi Grimberg <sagi@grimberg.me>2017-08-28 23:00:41 +0300
commit48fa362b6c3f4d69bdb6310b46626049092475e0 (patch)
treec8f7d71b54dec83f09dae2cf659d08a14c2c2af3 /include/linux/nvme-fc-driver.h
parentnvme-fc: Reattach to localports on re-registration (diff)
downloadwireguard-linux-48fa362b6c3f4d69bdb6310b46626049092475e0.tar.xz
wireguard-linux-48fa362b6c3f4d69bdb6310b46626049092475e0.zip
nvmet-fc: simplify sg list handling
The existing nvmet_fc sg list handling has 2 faults: a) the request between LLDD and transport has too large of an sg list (256 elements), which is normally 256k (64 elements). b) sglist handling doesn't optimize on the fact that each element is a page. This patch removes the static sg list in the request and uses the dynamic list already present in the nvmet_fc transport. It also simplies the handling of the sg list on multiple sequences to take advantage of the per-page divisions. Signed-off-by: James Smart <james.smart@broadcom.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'include/linux/nvme-fc-driver.h')
-rw-r--r--include/linux/nvme-fc-driver.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/nvme-fc-driver.h b/include/linux/nvme-fc-driver.h
index 2591878c1d48..9c5cb4480806 100644
--- a/include/linux/nvme-fc-driver.h
+++ b/include/linux/nvme-fc-driver.h
@@ -624,7 +624,7 @@ struct nvmefc_tgt_fcp_req {
u32 timeout;
u32 transfer_length;
struct fc_ba_rjt ba_rjt;
- struct scatterlist sg[NVME_FC_MAX_SEGMENTS];
+ struct scatterlist *sg;
int sg_cnt;
void *rspaddr;
dma_addr_t rspdma;