aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorTejun Heo <htejun@gmail.com>2007-01-03 03:30:39 -0500
committerJeff Garzik <jeff@garzik.org>2007-02-09 17:39:31 -0500
commit726f0785b608d09bdd64bdbadc09217ebbf9920e (patch)
treecefc97e9d5fefb2735b1b7a5ca22d3b3cc742b13 /include/linux
parent16454445e1f0ca21ca2f29accb58478a7ff765a2 (diff)
libata: kill qc->nsect and cursect
libata used two separate sets of variables to record request size and current offset for ATA and ATAPI. This is confusing and fragile. This patch replaces qc->nsect/cursect with qc->nbytes/curbytes and kills them. Also, ata_pio_sector() is updated to use bytes for qc->cursg_ofs instead of sectors. The field used to be used in bytes for ATAPI and in sectors for ATA. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/libata.h6
1 files changed, 1 insertions, 5 deletions
diff --git a/include/linux/libata.h b/include/linux/libata.h
index a8ecaaad55ff..a2458dfefb17 100644
--- a/include/linux/libata.h
+++ b/include/linux/libata.h
@@ -427,9 +427,6 @@ struct ata_queued_cmd {
427 427
428 unsigned int pad_len; 428 unsigned int pad_len;
429 429
430 unsigned int nsect;
431 unsigned int cursect;
432
433 unsigned int nbytes; 430 unsigned int nbytes;
434 unsigned int curbytes; 431 unsigned int curbytes;
435 432
@@ -1145,8 +1142,7 @@ static inline void ata_qc_reinit(struct ata_queued_cmd *qc)
1145 qc->dma_dir = DMA_NONE; 1142 qc->dma_dir = DMA_NONE;
1146 qc->__sg = NULL; 1143 qc->__sg = NULL;
1147 qc->flags = 0; 1144 qc->flags = 0;
1148 qc->cursect = qc->cursg = qc->cursg_ofs = 0; 1145 qc->cursg = qc->cursg_ofs = 0;
1149 qc->nsect = 0;
1150 qc->nbytes = qc->curbytes = 0; 1146 qc->nbytes = qc->curbytes = 0;
1151 qc->n_elem = 0; 1147 qc->n_elem = 0;
1152 qc->err_mask = 0; 1148 qc->err_mask = 0;