mirror of https://gitee.com/openkylin/linux.git
staging: mt7621-mmc: Inline function msdc_set_blknum
The function msdc_set_blknum consists of one (real) line of code and is only called once, so inline it makes the code shorter and more readable. Signed-off-by: Christian Lütke-Stetzkamp <christian@lkamp.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
96a9789306
commit
32a966cb00
|
@ -1182,14 +1182,6 @@ static void msdc_dma_setup(struct msdc_host *host, struct msdc_dma *dma,
|
|||
msdc_dma_config(host, dma);
|
||||
}
|
||||
|
||||
/* set block number before send command */
|
||||
static void msdc_set_blknum(struct msdc_host *host, u32 blknum)
|
||||
{
|
||||
void __iomem *base = host->base;
|
||||
|
||||
sdr_write32(SDC_BLK_NUM, blknum);
|
||||
}
|
||||
|
||||
static int msdc_do_request(struct mmc_host *mmc, struct mmc_request *mrq)
|
||||
__must_hold(&host->lock)
|
||||
{
|
||||
|
@ -1239,7 +1231,7 @@ static int msdc_do_request(struct mmc_host *mmc, struct mmc_request *mrq)
|
|||
}
|
||||
}
|
||||
|
||||
msdc_set_blknum(host, data->blocks);
|
||||
sdr_write32(SDC_BLK_NUM, data->blocks);
|
||||
//msdc_clr_fifo(); /* no need */
|
||||
|
||||
msdc_dma_on(); /* enable DMA mode first!! */
|
||||
|
|
Loading…
Reference in New Issue