-
由 Christoph Hellwig 提交于
It's possible the preferred HMB size may not be a multiple of the chunk_size. This patch moves len to function scope and uses that in the for loop increment so the last iteration doesn't cause the total size to exceed the allocated HMB size. Based on an earlier patch from Keith Busch. Signed-off-by: NChristoph Hellwig <hch@lst.de> Reported-by: NDan Carpenter <dan.carpenter@oracle.com> Reviewed-by: NKeith Busch <keith.busch@intel.com> Fixes: 87ad72a5 ("nvme-pci: implement host memory buffer support")
50cdb7c6