From: Christoph Hellwig Date: Tue, 10 Nov 2015 22:45:42 +0000 (-0800) Subject: sfc: don't call dma_supported X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=8722b8fbceecfb63bdd74674fc5e49a8c511a1f6;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git sfc: don't call dma_supported dma_set_mask already checks for a supported DMA mask before updating it, the call to dma_supported is redundant. Signed-off-by: Christoph Hellwig Cc: Solarflare linux maintainers Cc: Shradha Shah Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/net/ethernet/sfc/efx.c b/drivers/net/ethernet/sfc/efx.c index 6e11ee6173ce..d288f1c928de 100644 --- a/drivers/net/ethernet/sfc/efx.c +++ b/drivers/net/ethernet/sfc/efx.c @@ -1247,11 +1247,9 @@ static int efx_init_io(struct efx_nic *efx) * masks event though they reject 46 bit masks. */ while (dma_mask > 0x7fffffffUL) { - if (dma_supported(&pci_dev->dev, dma_mask)) { - rc = dma_set_mask_and_coherent(&pci_dev->dev, dma_mask); - if (rc == 0) - break; - } + rc = dma_set_mask_and_coherent(&pci_dev->dev, dma_mask); + if (rc == 0) + break; dma_mask >>= 1; } if (rc) {