aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mmc/card/block.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mmc/card/block.c')
-rw-r--r--drivers/mmc/card/block.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/mmc/card/block.c b/drivers/mmc/card/block.c
index fe8041e619ea..949e99770ad6 100644
--- a/drivers/mmc/card/block.c
+++ b/drivers/mmc/card/block.c
@@ -243,7 +243,7 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)
243 brq.mrq.cmd = &brq.cmd; 243 brq.mrq.cmd = &brq.cmd;
244 brq.mrq.data = &brq.data; 244 brq.mrq.data = &brq.data;
245 245
246 brq.cmd.arg = req->sector; 246 brq.cmd.arg = blk_rq_pos(req);
247 if (!mmc_card_blockaddr(card)) 247 if (!mmc_card_blockaddr(card))
248 brq.cmd.arg <<= 9; 248 brq.cmd.arg <<= 9;
249 brq.cmd.flags = MMC_RSP_SPI_R1 | MMC_RSP_R1 | MMC_CMD_ADTC; 249 brq.cmd.flags = MMC_RSP_SPI_R1 | MMC_RSP_R1 | MMC_CMD_ADTC;
@@ -251,7 +251,7 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)
251 brq.stop.opcode = MMC_STOP_TRANSMISSION; 251 brq.stop.opcode = MMC_STOP_TRANSMISSION;
252 brq.stop.arg = 0; 252 brq.stop.arg = 0;
253 brq.stop.flags = MMC_RSP_SPI_R1B | MMC_RSP_R1B | MMC_CMD_AC; 253 brq.stop.flags = MMC_RSP_SPI_R1B | MMC_RSP_R1B | MMC_CMD_AC;
254 brq.data.blocks = req->nr_sectors; 254 brq.data.blocks = blk_rq_sectors(req);
255 255
256 /* 256 /*
257 * After a read error, we redo the request one sector at a time 257 * After a read error, we redo the request one sector at a time
@@ -293,7 +293,7 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)
293 * Adjust the sg list so it is the same size as the 293 * Adjust the sg list so it is the same size as the
294 * request. 294 * request.
295 */ 295 */
296 if (brq.data.blocks != req->nr_sectors) { 296 if (brq.data.blocks != blk_rq_sectors(req)) {
297 int i, data_size = brq.data.blocks << 9; 297 int i, data_size = brq.data.blocks << 9;
298 struct scatterlist *sg; 298 struct scatterlist *sg;
299 299
@@ -344,8 +344,8 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)
344 printk(KERN_ERR "%s: error %d transferring data," 344 printk(KERN_ERR "%s: error %d transferring data,"
345 " sector %u, nr %u, card status %#x\n", 345 " sector %u, nr %u, card status %#x\n",
346 req->rq_disk->disk_name, brq.data.error, 346 req->rq_disk->disk_name, brq.data.error,
347 (unsigned)req->sector, 347 (unsigned)blk_rq_pos(req),
348 (unsigned)req->nr_sectors, status); 348 (unsigned)blk_rq_sectors(req), status);
349 } 349 }
350 350
351 if (brq.stop.error) { 351 if (brq.stop.error) {