diff options
author | Tom Rini <trini@konsulko.com> | 2019-04-13 15:27:26 +0300 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2019-04-13 15:27:26 +0300 |
commit | 0a5228be868622894a5f8f226203cd7bac562187 (patch) | |
tree | 180df0714bcd961c378fb4569cd9b40bd366e5fc /drivers/dma/bcm6348-iudma.c | |
parent | 015289580f81733f7358227743e3e5881653a797 (diff) | |
parent | c3b6c8e2d8fb5b8d0d67858dc4a2133b7065df5b (diff) | |
download | u-boot-0a5228be868622894a5f8f226203cd7bac562187.tar.xz |
Merge tag 'mips-pull-2019-04-12' of git://git.denx.de/u-boot-mips
- mt76xx: add USB support, small fixes
- ath79: small fixes, add support for QCA9563 SoC and AP152 reference board
- mscc: small fixes, add network support for JR2 and ServalT SoCs
- bmips: small fixes, enable more drivers for ARM specific BCM6858 and BCM63158 SoCs
- MIPS: fix redundant relocation of initrd images
Diffstat (limited to 'drivers/dma/bcm6348-iudma.c')
-rw-r--r-- | drivers/dma/bcm6348-iudma.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/dma/bcm6348-iudma.c b/drivers/dma/bcm6348-iudma.c index 1d3c192cfe..e7bd1b2350 100644 --- a/drivers/dma/bcm6348-iudma.c +++ b/drivers/dma/bcm6348-iudma.c @@ -324,6 +324,9 @@ static int bcm6348_iudma_receive(struct dma *dma, void **dst, void *metadata) struct bcm6348_dma_desc *dma_desc = dma_desc = ch_priv->dma_ring; int ret; + if (!ch_priv->running) + return -EINVAL; + /* get dma ring descriptor address */ dma_desc += ch_priv->desc_id; @@ -369,6 +372,9 @@ static int bcm6348_iudma_send(struct dma *dma, void *src, size_t len, struct bcm6348_dma_desc *dma_desc; uint16_t status; + if (!ch_priv->running) + return -EINVAL; + /* flush cache */ bcm6348_iudma_fdc(src, len); |