diff options
Diffstat (limited to 'drivers/scsi/ibmvscsi/ibmvscsi.c')
-rw-r--r-- | drivers/scsi/ibmvscsi/ibmvscsi.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/scsi/ibmvscsi/ibmvscsi.c b/drivers/scsi/ibmvscsi/ibmvscsi.c index 2e9be83a697f..944fc1203ebd 100644 --- a/drivers/scsi/ibmvscsi/ibmvscsi.c +++ b/drivers/scsi/ibmvscsi/ibmvscsi.c | |||
@@ -121,10 +121,9 @@ static int initialize_event_pool(struct event_pool *pool, | |||
121 | 121 | ||
122 | pool->size = size; | 122 | pool->size = size; |
123 | pool->next = 0; | 123 | pool->next = 0; |
124 | pool->events = kmalloc(pool->size * sizeof(*pool->events), GFP_KERNEL); | 124 | pool->events = kcalloc(pool->size, sizeof(*pool->events), GFP_KERNEL); |
125 | if (!pool->events) | 125 | if (!pool->events) |
126 | return -ENOMEM; | 126 | return -ENOMEM; |
127 | memset(pool->events, 0x00, pool->size * sizeof(*pool->events)); | ||
128 | 127 | ||
129 | pool->iu_storage = | 128 | pool->iu_storage = |
130 | dma_alloc_coherent(hostdata->dev, | 129 | dma_alloc_coherent(hostdata->dev, |