host->mrq = NULL;
host->cmd = NULL;
- if (mrq->data)
- mrq->data->bytes_xfered = host->data_xfered;
-
/*
* Need to drop the host lock here; mmc_request_done may call
* back into the driver...
host->data = data;
host->size = data->blksz * data->blocks;
- host->data_xfered = 0;
+ data->bytes_xfered = 0;
mmci_init_sg(host, data);
success = 0;
data->error = -EIO;
}
- host->data_xfered = round_down(success, data->blksz);
+ data->bytes_xfered = round_down(success, data->blksz);
}
if (status & MCI_DATABLOCKEND)
if (!data->error)
/* The error clause is handled above, success! */
- host->data_xfered += data->blksz * data->blocks;
+ data->bytes_xfered = data->blksz * data->blocks;
if (!data->stop) {
mmci_request_end(host, data->mrq);