提交 788ee7b0 编写于 作者: R Russell King 提交者: Russell King

[MMC] Add DATA_MULTI flag

Some hosts need to know that a transfer will be multi-block.
Add a data flag to indicate multiple data block transfers.
Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
上级 cfa7f521
......@@ -200,7 +200,13 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)
brq.data.flags |= MMC_DATA_WRITE;
brq.data.blocks = 1;
}
brq.mrq.stop = brq.data.blocks > 1 ? &brq.stop : NULL;
if (brq.data.blocks > 1) {
brq.data.flags |= MMC_DATA_MULTI;
brq.mrq.stop = &brq.stop;
} else {
brq.mrq.stop = NULL;
}
brq.data.sg = mq->sg;
brq.data.sg_len = blk_rq_map_sg(req->q, req, brq.data.sg);
......
......@@ -64,6 +64,7 @@ struct mmc_data {
#define MMC_DATA_WRITE (1 << 8)
#define MMC_DATA_READ (1 << 9)
#define MMC_DATA_STREAM (1 << 10)
#define MMC_DATA_MULTI (1 << 11)
unsigned int bytes_xfered;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册