Commit 75744bc7 authored by Christian Lütke-Stetzkamp's avatar Christian Lütke-Stetzkamp Committed by Greg Kroah-Hartman

staging: mt7621-mmc: Remove unused field burstsz from msdc_dma

The burstsz field in msdc_dma is set to a constant value and later
only used two times, using the constant directly in that places allows
to remove the field and improves readability.
Signed-off-by: default avatarChristian Lütke-Stetzkamp <christian@lkamp.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent ab71f5d7
...@@ -909,7 +909,6 @@ struct msdc_dma { ...@@ -909,7 +909,6 @@ struct msdc_dma {
struct scatterlist *sg; /* I/O scatter list */ struct scatterlist *sg; /* I/O scatter list */
struct scatterlist_ex *esg; /* extended I/O scatter list */ struct scatterlist_ex *esg; /* extended I/O scatter list */
u8 mode; /* dma mode */ u8 mode; /* dma mode */
u8 burstsz; /* burst size */
u8 intr; /* dma done interrupt */ u8 intr; /* dma done interrupt */
u8 padding; /* padding */ u8 padding; /* padding */
u32 cmd; /* enhanced mode command */ u32 cmd; /* enhanced mode command */
......
...@@ -1338,7 +1338,8 @@ static int msdc_dma_config(struct msdc_host *host, struct msdc_dma *dma) ...@@ -1338,7 +1338,8 @@ static int msdc_dma_config(struct msdc_host *host, struct msdc_dma *dma)
else else
sdr_write32((volatile u32 *)(RALINK_MSDC_BASE + 0xa8), sg_dma_len(sg)); sdr_write32((volatile u32 *)(RALINK_MSDC_BASE + 0xa8), sg_dma_len(sg));
//#endif //#endif
sdr_set_field(MSDC_DMA_CTRL, MSDC_DMA_CTRL_BRUSTSZ, dma->burstsz); sdr_set_field(MSDC_DMA_CTRL, MSDC_DMA_CTRL_BRUSTSZ,
MSDC_BRUST_64B);
sdr_set_field(MSDC_DMA_CTRL, MSDC_DMA_CTRL_MODE, 0); sdr_set_field(MSDC_DMA_CTRL, MSDC_DMA_CTRL_MODE, 0);
break; break;
case MSDC_MODE_DMA_DESC: case MSDC_MODE_DMA_DESC:
...@@ -1377,7 +1378,8 @@ static int msdc_dma_config(struct msdc_host *host, struct msdc_dma *dma) ...@@ -1377,7 +1378,8 @@ static int msdc_dma_config(struct msdc_host *host, struct msdc_dma *dma)
dma->used_bd += bdlen; dma->used_bd += bdlen;
sdr_set_field(MSDC_DMA_CFG, MSDC_DMA_CFG_DECSEN, chksum); sdr_set_field(MSDC_DMA_CFG, MSDC_DMA_CFG_DECSEN, chksum);
sdr_set_field(MSDC_DMA_CTRL, MSDC_DMA_CTRL_BRUSTSZ, dma->burstsz); sdr_set_field(MSDC_DMA_CTRL, MSDC_DMA_CTRL_BRUSTSZ,
MSDC_BRUST_64B);
sdr_set_field(MSDC_DMA_CTRL, MSDC_DMA_CTRL_MODE, 1); sdr_set_field(MSDC_DMA_CTRL, MSDC_DMA_CTRL_MODE, 1);
sdr_write32(MSDC_DMA_SA, PHYSADDR((u32)dma->gpd_addr)); sdr_write32(MSDC_DMA_SA, PHYSADDR((u32)dma->gpd_addr));
...@@ -1404,7 +1406,6 @@ static void msdc_dma_setup(struct msdc_host *host, struct msdc_dma *dma, ...@@ -1404,7 +1406,6 @@ static void msdc_dma_setup(struct msdc_host *host, struct msdc_dma *dma,
//dma->flags = DMA_FLAG_NONE; /* CHECKME */ //dma->flags = DMA_FLAG_NONE; /* CHECKME */
dma->sglen = sglen; dma->sglen = sglen;
dma->xfersz = host->xfer_size; dma->xfersz = host->xfer_size;
dma->burstsz = MSDC_BRUST_64B;
if (sglen == 1 && sg_dma_len(sg) <= MAX_DMA_CNT) if (sglen == 1 && sg_dma_len(sg) <= MAX_DMA_CNT)
dma->mode = MSDC_MODE_DMA_BASIC; dma->mode = MSDC_MODE_DMA_BASIC;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment