aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/netxen/netxen_nic_main.c
diff options
context:
space:
mode:
authorDhananjay Phadke <dhananjay@netxen.com>2009-08-04 06:39:03 -0400
committerDavid S. Miller <davem@davemloft.net>2009-08-05 13:21:58 -0400
commitf60f785679b507cbeeb03d2db080ab649ac86027 (patch)
treeee8d873ccdaaa9092359db79f949bfd1bf8fbfbe /drivers/net/netxen/netxen_nic_main.c
parent0bf52b981770cbf006323bab5177f2858a196766 (diff)
netxen: fix dma mask update calculation
Fix dma mask calculation that caps at 63-bit addressing even when firmware advertises full 64-bit support. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/netxen/netxen_nic_main.c')
-rw-r--r--drivers/net/netxen/netxen_nic_main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/netxen/netxen_nic_main.c b/drivers/net/netxen/netxen_nic_main.c
index 3cd8cfcf627b..70c05c4c0cab 100644
--- a/drivers/net/netxen/netxen_nic_main.c
+++ b/drivers/net/netxen/netxen_nic_main.c
@@ -260,7 +260,7 @@ nx_update_dma_mask(struct netxen_adapter *adapter)
260 change = 0; 260 change = 0;
261 261
262 shift = NXRD32(adapter, CRB_DMA_SHIFT); 262 shift = NXRD32(adapter, CRB_DMA_SHIFT);
263 if (shift >= 32) 263 if (shift > 32)
264 return 0; 264 return 0;
265 265
266 if (NX_IS_REVISION_P3(adapter->ahw.revision_id) && (shift > 9)) 266 if (NX_IS_REVISION_P3(adapter->ahw.revision_id) && (shift > 9))
@@ -272,7 +272,7 @@ nx_update_dma_mask(struct netxen_adapter *adapter)
272 old_mask = pdev->dma_mask; 272 old_mask = pdev->dma_mask;
273 old_cmask = pdev->dev.coherent_dma_mask; 273 old_cmask = pdev->dev.coherent_dma_mask;
274 274
275 mask = (1ULL<<(32+shift)) - 1; 275 mask = DMA_BIT_MASK(32+shift);
276 276
277 err = pci_set_dma_mask(pdev, mask); 277 err = pci_set_dma_mask(pdev, mask);
278 if (err) 278 if (err)