From 5a01d08217e39f3d36d3ca160361c7b019ff1598 Mon Sep 17 00:00:00 2001 From: Nicholas Bellinger Date: Sat, 22 Feb 2014 18:34:08 -0800 Subject: [PATCH] vhost/scsi: Move sanity check into vhost_scsi_map_iov_to_sgl Move the overflow check for sgl_count > TCM_VHOST_PREALLOC_SGLS into vhost_scsi_map_iov_to_sgl() so that it's based on the total number of SGLs for all IOVs, instead of single IOVs. Also, rename TCM_VHOST_PREALLOC_PAGES -> TCM_VHOST_PREALLOC_UPAGES to better describe pointers to user-space pages. Cc: Michael S. Tsirkin Cc: Paolo Bonzini Cc: Martin K. Petersen Cc: Christoph Hellwig Cc: Hannes Reinecke Acked-by: Michael S. Tsirkin Signed-off-by: Nicholas Bellinger --- Reading git-format-patch failed