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.