提交 edd31476 编写于 作者: M Merav Sicron 提交者: David S. Miller

bnx2x: Set NETIF_F_HIGHDMA unconditionally

Current driver implementation incorrectly sets the flag only if 64-bit
DMA mask succeeded.
Signed-off-by: NMerav Sicron <meravs@broadcom.com>
Signed-off-by: NYuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: NAriel Elior <ariele@broadcom.com>
Signed-off-by: NEilon Greenstein <eilong@broadcom.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 4293b9f5
...@@ -1528,7 +1528,6 @@ struct bnx2x { ...@@ -1528,7 +1528,6 @@ struct bnx2x {
#define PCI_32BIT_FLAG (1 << 1) #define PCI_32BIT_FLAG (1 << 1)
#define ONE_PORT_FLAG (1 << 2) #define ONE_PORT_FLAG (1 << 2)
#define NO_WOL_FLAG (1 << 3) #define NO_WOL_FLAG (1 << 3)
#define USING_DAC_FLAG (1 << 4)
#define USING_MSIX_FLAG (1 << 5) #define USING_MSIX_FLAG (1 << 5)
#define USING_MSI_FLAG (1 << 6) #define USING_MSI_FLAG (1 << 6)
#define DISABLE_MSI_FLAG (1 << 7) #define DISABLE_MSI_FLAG (1 << 7)
......
...@@ -12118,7 +12118,6 @@ static int bnx2x_set_coherency_mask(struct bnx2x *bp) ...@@ -12118,7 +12118,6 @@ static int bnx2x_set_coherency_mask(struct bnx2x *bp)
struct device *dev = &bp->pdev->dev; struct device *dev = &bp->pdev->dev;
if (dma_set_mask(dev, DMA_BIT_MASK(64)) == 0) { if (dma_set_mask(dev, DMA_BIT_MASK(64)) == 0) {
bp->flags |= USING_DAC_FLAG;
if (dma_set_coherent_mask(dev, DMA_BIT_MASK(64)) != 0) { if (dma_set_coherent_mask(dev, DMA_BIT_MASK(64)) != 0) {
dev_err(dev, "dma_set_coherent_mask failed, aborting\n"); dev_err(dev, "dma_set_coherent_mask failed, aborting\n");
return -EIO; return -EIO;
...@@ -12286,8 +12285,7 @@ static int bnx2x_init_dev(struct bnx2x *bp, struct pci_dev *pdev, ...@@ -12286,8 +12285,7 @@ static int bnx2x_init_dev(struct bnx2x *bp, struct pci_dev *pdev,
NETIF_F_TSO | NETIF_F_TSO_ECN | NETIF_F_TSO6 | NETIF_F_HIGHDMA; NETIF_F_TSO | NETIF_F_TSO_ECN | NETIF_F_TSO6 | NETIF_F_HIGHDMA;
dev->features |= dev->hw_features | NETIF_F_HW_VLAN_CTAG_RX; dev->features |= dev->hw_features | NETIF_F_HW_VLAN_CTAG_RX;
if (bp->flags & USING_DAC_FLAG) dev->features |= NETIF_F_HIGHDMA;
dev->features |= NETIF_F_HIGHDMA;
/* Add Loopback capability to the device */ /* Add Loopback capability to the device */
dev->hw_features |= NETIF_F_LOOPBACK; dev->hw_features |= NETIF_F_LOOPBACK;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册