Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf
[sfrench/cifs-2.6.git] / drivers / nvme / host / fc.c
index dd8169bbf0d2cfa92fdf47e7f9a8c123d36bb41c..dcb2b799966fe6e112cca1645568388721409c2d 100644 (file)
@@ -2112,7 +2112,8 @@ nvme_fc_map_data(struct nvme_fc_ctrl *ctrl, struct request *rq,
 
        freq->sg_table.sgl = freq->first_sgl;
        ret = sg_alloc_table_chained(&freq->sg_table,
-                       blk_rq_nr_phys_segments(rq), freq->sg_table.sgl);
+                       blk_rq_nr_phys_segments(rq), freq->sg_table.sgl,
+                       SG_CHUNK_SIZE);
        if (ret)
                return -ENOMEM;
 
@@ -2122,7 +2123,7 @@ nvme_fc_map_data(struct nvme_fc_ctrl *ctrl, struct request *rq,
        freq->sg_cnt = fc_dma_map_sg(ctrl->lport->dev, freq->sg_table.sgl,
                                op->nents, dir);
        if (unlikely(freq->sg_cnt <= 0)) {
-               sg_free_table_chained(&freq->sg_table, true);
+               sg_free_table_chained(&freq->sg_table, SG_CHUNK_SIZE);
                freq->sg_cnt = 0;
                return -EFAULT;
        }
@@ -2148,7 +2149,7 @@ nvme_fc_unmap_data(struct nvme_fc_ctrl *ctrl, struct request *rq,
 
        nvme_cleanup_cmd(rq);
 
-       sg_free_table_chained(&freq->sg_table, true);
+       sg_free_table_chained(&freq->sg_table, SG_CHUNK_SIZE);
 
        freq->sg_cnt = 0;
 }
@@ -2607,6 +2608,12 @@ nvme_fc_create_association(struct nvme_fc_ctrl *ctrl)
        if (nvme_fc_ctlr_active_on_rport(ctrl))
                return -ENOTUNIQ;
 
+       dev_info(ctrl->ctrl.device,
+               "NVME-FC{%d}: create association : host wwpn 0x%016llx "
+               " rport wwpn 0x%016llx: NQN \"%s\"\n",
+               ctrl->cnum, ctrl->lport->localport.port_name,
+               ctrl->rport->remoteport.port_name, ctrl->ctrl.opts->subsysnqn);
+
        /*
         * Create the admin queue
         */