summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/sd.c
diff options
context:
space:
mode:
authorJosh Hunt <johunt@akamai.com>2012-06-09 16:03:39 +0200
committerJames Bottomley <JBottomley@Parallels.com>2012-07-20 09:58:36 +0200
commit9e1a15376bce2fc7746145eb8ee78a3674658bc8 (patch)
tree81f23f7fc1152a4386814dfc443129cc5f7e1de2 /drivers/scsi/sd.c
parent[SCSI] scsi_dh_alua: Re-enable STPG for unavailable ports (diff)
downloadlinux-9e1a15376bce2fc7746145eb8ee78a3674658bc8.tar.xz
linux-9e1a15376bce2fc7746145eb8ee78a3674658bc8.zip
[SCSI] properly initialize atomic_t
Initialize atomic_t scsi_host_next_hn and ioerr_cntas per the guidelines defined in Documentation/atomic_ops.txt Signed-off-by: Josh Hunt <johunt@akamai.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/sd.c')
-rw-r--r--drivers/scsi/sd.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c
index 6f72b80121a0..6e26db11250a 100644
--- a/drivers/scsi/sd.c
+++ b/drivers/scsi/sd.c
@@ -2704,6 +2704,7 @@ static int sd_probe(struct device *dev)
sdkp->disk = gd;
sdkp->index = index;
atomic_set(&sdkp->openers, 0);
+ atomic_set(&sdkp->device->ioerr_cnt, 0);
if (!sdp->request_queue->rq_timeout) {
if (sdp->type != TYPE_MOD)