diff options
Diffstat (limited to 'drivers/scsi/scsi.c')
-rw-r--r-- | drivers/scsi/scsi.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/scsi/scsi.c b/drivers/scsi/scsi.c index c551bb84dbfb..11b27ba0cd41 100644 --- a/drivers/scsi/scsi.c +++ b/drivers/scsi/scsi.c | |||
@@ -136,9 +136,8 @@ struct scsi_request *scsi_allocate_request(struct scsi_device *sdev, | |||
136 | const int size = offset + sizeof(struct request); | 136 | const int size = offset + sizeof(struct request); |
137 | struct scsi_request *sreq; | 137 | struct scsi_request *sreq; |
138 | 138 | ||
139 | sreq = kmalloc(size, gfp_mask); | 139 | sreq = kzalloc(size, gfp_mask); |
140 | if (likely(sreq != NULL)) { | 140 | if (likely(sreq != NULL)) { |
141 | memset(sreq, 0, size); | ||
142 | sreq->sr_request = (struct request *)(((char *)sreq) + offset); | 141 | sreq->sr_request = (struct request *)(((char *)sreq) + offset); |
143 | sreq->sr_device = sdev; | 142 | sreq->sr_device = sdev; |
144 | sreq->sr_host = sdev->host; | 143 | sreq->sr_host = sdev->host; |