diff options
author | YueHaibing <yuehaibing@huawei.com> | 2018-09-01 05:13:10 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-09-02 07:30:41 +0200 |
commit | 2d5c2885983996ae5c32585b16bc600da7aa17bc (patch) | |
tree | 2e1db2edc48149f9f78b94347e2f50a3203643ed | |
parent | net: dsa: b53: Provide sensible defaults (diff) | |
download | linux-2d5c2885983996ae5c32585b16bc600da7aa17bc.tar.xz linux-2d5c2885983996ae5c32585b16bc600da7aa17bc.zip |
net: bgmac: remove set but not used variable 'err'
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/net/ethernet/broadcom/bgmac.c: In function 'bgmac_dma_alloc':
drivers/net/ethernet/broadcom/bgmac.c:619:6: warning:
variable 'err' set but not used [-Wunused-but-set-variable]
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/ethernet/broadcom/bgmac.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/net/ethernet/broadcom/bgmac.c b/drivers/net/ethernet/broadcom/bgmac.c index 4c94d9218bba..cabc8e49ad24 100644 --- a/drivers/net/ethernet/broadcom/bgmac.c +++ b/drivers/net/ethernet/broadcom/bgmac.c @@ -616,7 +616,6 @@ static int bgmac_dma_alloc(struct bgmac *bgmac) static const u16 ring_base[] = { BGMAC_DMA_BASE0, BGMAC_DMA_BASE1, BGMAC_DMA_BASE2, BGMAC_DMA_BASE3, }; int size; /* ring size: different for Tx and Rx */ - int err; int i; BUILD_BUG_ON(BGMAC_MAX_TX_RINGS > ARRAY_SIZE(ring_base)); @@ -666,7 +665,6 @@ static int bgmac_dma_alloc(struct bgmac *bgmac) if (!ring->cpu_base) { dev_err(bgmac->dev, "Allocation of RX ring 0x%X failed\n", ring->mmio_base); - err = -ENOMEM; goto err_dma_free; } |