Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 18828
b: refs/heads/master
c: d1f3d4d
h: refs/heads/master
v: v3
  • Loading branch information
Stephen Hemminger authored and Jeff Garzik committed Jan 18, 2006
1 parent 7ad4c02 commit 67c92ac
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 82788c7a47e50ee8d42e3be23afb23448d651c4c
refs/heads/master: d1f3d4ddddc3c86e25ce2a41dc129cbe10e24991
17 changes: 11 additions & 6 deletions trunk/drivers/net/sky2.c
Original file line number Diff line number Diff line change
Expand Up @@ -3054,20 +3054,25 @@ static int __devinit sky2_probe(struct pci_dev *pdev,
goto err_out_free_regions;
}

if (sizeof(dma_addr_t) > sizeof(u32)) {
err = pci_set_dma_mask(pdev, DMA_64BIT_MASK);
if (!err)
using_dac = 1;
}
if (sizeof(dma_addr_t) > sizeof(u32) &&
!(err = pci_set_dma_mask(pdev, DMA_64BIT_MASK))) {
using_dac = 1;
err = pci_set_consistent_dma_mask(pdev, DMA_64BIT_MASK);
if (err < 0) {
printk(KERN_ERR PFX "%s unable to obtain 64 bit DMA "
"for consistent allocations\n", pci_name(pdev));
goto err_out_free_regions;
}

if (!using_dac) {
} else {
err = pci_set_dma_mask(pdev, DMA_32BIT_MASK);
if (err) {
printk(KERN_ERR PFX "%s no usable DMA configuration\n",
pci_name(pdev));
goto err_out_free_regions;
}
}

#ifdef __BIG_ENDIAN
/* byte swap descriptors in hardware */
{
Expand Down

0 comments on commit 67c92ac

Please sign in to comment.