2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-28 23:23:55 +08:00

staging: mt7621-mmc: Remove unnecessary BUG_ON() in msdc_dma_setup

The BUG_ON() removed by this patch is just a duplicate of a prior
BUG_ON() statement. There the condition is just clearer, it checks
weather sglen > MAX_BD_NUM and MAX_BD_NUM is equal MAX_BD_PER_GPD. So
this statement can be safely removed.

Signed-off-by: Christian Lütke-Stetzkamp <christian@lkamp.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Christian Lütke-Stetzkamp 2018-06-16 16:14:53 +02:00 committed by Greg Kroah-Hartman
parent d812c6a9bb
commit 41015d06e6

View File

@ -1043,9 +1043,6 @@ static void msdc_dma_setup(struct msdc_host *host, struct msdc_dma *dma,
N_MSG(DMA, "DMA sglen<%d> xfersz<%d>", sglen, host->xfer_size);
/* calculate the required number of gpd */
BUG_ON(((sglen + MAX_BD_PER_GPD - 1) / MAX_BD_PER_GPD) != 1);
gpd = dma->gpd;
bd = dma->bd;