[PATCH 3/4] nvme-pci: use max of PRP or SGL for iod size

Chaitanya Kulkarni Chaitanya.Kulkarni at wdc.com
Wed Jul 8 19:28:40 EDT 2020


On 7/8/20 15:27, Keith Busch wrote:
>> -	else
>> -		alloc_size = sizeof(__le64 *) * nvme_npages(size, dev);
>> +	alloc_size *= (npages_sgl > npages ? npages_sgl : npages);
> This would look better as:
> 
> 	alloc_size *= max(npages, npages_sgl);
> 

Okay, I'll fix it.




More information about the Linux-nvme mailing list