[PATCH 5/9] nvme-pci: merge the simple PRP and SGL setup into a common helper
Christoph Hellwig
hch at lst.de
Wed Jun 11 22:01:00 PDT 2025
On Wed, Jun 11, 2025 at 03:44:45PM +0200, Daniel Gomez wrote:
> > -static blk_status_t nvme_setup_sgl_simple(struct nvme_dev *dev,
> > - struct request *req, struct nvme_rw_command *cmnd,
> > - struct bio_vec *bv)
> > -{
> > - struct nvme_iod *iod = blk_mq_rq_to_pdu(req);
> > + if (use_sgl == SGL_FORCED || !prp_possible) {
>
> I couldn't find any place other than this where the new FORCED tristate actually
> matters. So instead of passing the use_sgl tristate around, why not just check
> here whether SGL is forced?
See the check in nvme_map_data.
More information about the Linux-nvme
mailing list