summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorBrian King <brking@linux.vnet.ibm.com>2007-01-17 21:32:28 +0300
committerJeff Garzik <jeff@garzik.org>2007-01-24 10:04:34 +0300
commitd0f29485686d9d1c4f31240953a742d5dd4fdb72 (patch)
tree5ee0078ac6ace0e4b2a9acfc17594fe006874622 /include
parent7a801184fa480e11e6431f184a5bdf31f63326fb (diff)
downloadlinux-d0f29485686d9d1c4f31240953a742d5dd4fdb72.tar.xz
libata: Initialize qc->pad_len
Initialize qc->pad_len for each new command. This ensures that pad_len is not set to a stale value for zero data length commands. Signed-off-by: Brian King <brking@linux.vnet.ibm.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'include')
-rw-r--r--include/linux/libata.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/libata.h b/include/linux/libata.h
index 65d318746ac6..f7f268e38749 100644
--- a/include/linux/libata.h
+++ b/include/linux/libata.h
@@ -1151,6 +1151,7 @@ static inline void ata_qc_reinit(struct ata_queued_cmd *qc)
qc->nbytes = qc->curbytes = 0;
qc->n_elem = 0;
qc->err_mask = 0;
+ qc->pad_len = 0;
ata_tf_init(qc->dev, &qc->tf);