nvme-pci: remove iod use_sgls
authorKeith Busch <kbusch@kernel.org>
Fri, 10 Feb 2023 18:03:47 +0000 (10:03 -0800)
committerChristoph Hellwig <hch@lst.de>
Tue, 14 Feb 2023 05:40:57 +0000 (06:40 +0100)
It's not used anywhere anymore, so remove it.

Signed-off-by: Keith Busch <kbusch@kernel.org>
Signed-off-by: Christoph Hellwig <hch@lst.de>
drivers/nvme/host/pci.c

index 47d6b0023e3a8adc39b50f2b77c3beebfe94c573..d68e2db00d0d057eeae4cd473cd30aa2297e5a86 100644 (file)
@@ -230,7 +230,6 @@ union nvme_descriptor {
 struct nvme_iod {
        struct nvme_request req;
        struct nvme_command cmd;
-       bool use_sgl;
        bool aborted;
        s8 nr_allocations;      /* PRP list pool allocations. 0 means small
                                   pool in use */
@@ -808,8 +807,7 @@ static blk_status_t nvme_map_data(struct nvme_dev *dev, struct request *req,
                goto out_free_sg;
        }
 
-       iod->use_sgl = nvme_pci_use_sgls(dev, req, iod->sgt.nents);
-       if (iod->use_sgl)
+       if (nvme_pci_use_sgls(dev, req, iod->sgt.nents))
                ret = nvme_pci_setup_sgls(dev, req, &cmnd->rw);
        else
                ret = nvme_pci_setup_prps(dev, req, &cmnd->rw);