aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/storvsc_drv.c
diff options
context:
space:
mode:
authorK. Y. Srinivasan <kys@microsoft.com>2013-02-06 08:15:28 -0500
committerJames Bottomley <JBottomley@Parallels.com>2013-02-24 04:24:26 -0500
commit9d2696e658ef4f209955ddaa987d43f1a1bd81a1 (patch)
tree2fecb5030c0e3e8d79eb04a48fd60b432205bc52 /drivers/scsi/storvsc_drv.c
parent7887ea7f942770c2146dbcdfa2a85aa8de93df31 (diff)
[SCSI] storvsc: Initialize the sglist
Properly initialize scatterlist before using it. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Cc: stable@vger.kernel.org Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/storvsc_drv.c')
-rw-r--r--drivers/scsi/storvsc_drv.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi/storvsc_drv.c
index 01440782feb2..9f4e5601b610 100644
--- a/drivers/scsi/storvsc_drv.c
+++ b/drivers/scsi/storvsc_drv.c
@@ -467,6 +467,7 @@ static struct scatterlist *create_bounce_buffer(struct scatterlist *sgl,
467 if (!bounce_sgl) 467 if (!bounce_sgl)
468 return NULL; 468 return NULL;
469 469
470 sg_init_table(bounce_sgl, num_pages);
470 for (i = 0; i < num_pages; i++) { 471 for (i = 0; i < num_pages; i++) {
471 page_buf = alloc_page(GFP_ATOMIC); 472 page_buf = alloc_page(GFP_ATOMIC);
472 if (!page_buf) 473 if (!page_buf)