aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block/lguest_blk.c
diff options
context:
space:
mode:
authorJens Axboe <jens.axboe@oracle.com>2007-08-16 07:43:12 -0400
committerJens Axboe <axboe@carl.home.kernel.dk>2007-10-10 03:25:56 -0400
commit6c92e699b56287da582ccb12a64b959b6d6109ba (patch)
treeac8c9f26640ff8b35cd96f8222f8ce84ba2c53e5 /drivers/block/lguest_blk.c
parentbc1c56fde6dd1c85e2047c276456c07bd4508b5c (diff)
Fixup rq_for_each_segment() indentation
Remove one level of nesting where appropriate. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'drivers/block/lguest_blk.c')
-rw-r--r--drivers/block/lguest_blk.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/drivers/block/lguest_blk.c b/drivers/block/lguest_blk.c
index 1e838ae60a60..fa8e42341b87 100644
--- a/drivers/block/lguest_blk.c
+++ b/drivers/block/lguest_blk.c
@@ -147,18 +147,18 @@ static unsigned int req_to_dma(struct request *req, struct lguest_dma *dma)
147 struct bio_vec *bvec; 147 struct bio_vec *bvec;
148 148
149 rq_for_each_segment(bvec, req, iter) { 149 rq_for_each_segment(bvec, req, iter) {
150 /* We told the block layer not to give us too many. */ 150 /* We told the block layer not to give us too many. */
151 BUG_ON(i == LGUEST_MAX_DMA_SECTIONS); 151 BUG_ON(i == LGUEST_MAX_DMA_SECTIONS);
152 /* If we had a zero-length segment, it would look like 152 /* If we had a zero-length segment, it would look like
153 * the end of the data referred to by the "struct 153 * the end of the data referred to by the "struct
154 * lguest_dma", so make sure that doesn't happen. */ 154 * lguest_dma", so make sure that doesn't happen. */
155 BUG_ON(!bvec->bv_len); 155 BUG_ON(!bvec->bv_len);
156 /* Convert page & offset to a physical address */ 156 /* Convert page & offset to a physical address */
157 dma->addr[i] = page_to_phys(bvec->bv_page) 157 dma->addr[i] = page_to_phys(bvec->bv_page)
158 + bvec->bv_offset; 158 + bvec->bv_offset;
159 dma->len[i] = bvec->bv_len; 159 dma->len[i] = bvec->bv_len;
160 len += bvec->bv_len; 160 len += bvec->bv_len;
161 i++; 161 i++;
162 } 162 }
163 /* If the array isn't full, we mark the end with a 0 length */ 163 /* If the array isn't full, we mark the end with a 0 length */
164 if (i < LGUEST_MAX_DMA_SECTIONS) 164 if (i < LGUEST_MAX_DMA_SECTIONS)