On 06/04/11 20:07, Per Forlin wrote:
Previously there has only been one function mmc_wait_for_req to start and wait for a request. This patch adds
- mmc_start_req - starts a request wihtout waiting
- mmc_wait_for_req_done - waits until request is done
- mmc_pre_req - asks the host driver to prepare for the next job
- mmc_post_req - asks the host driver to clean up after a completed job
If MMC core had a queue of requests internally you wouldn't need to provide mmc_pre_req() and mmc_post_req() functions outside of the core. i.e., the mmc block driver would just need to queue up two mmc requests and the core would take care of calling pre_req and post_req at the correct time.
Using a MMC request queue has other benefits -- it allows multiple users without having to claim/release the host. This would be useful for (especially multi-function) SDIO.
David