Commit d93bf80c authored by Jeff Garzik's avatar Jeff Garzik

[libata] explicitly set consistent DMA mask to 0xffffffff

Do not rely on the default being 0xffffffff.
parent 3b059816
...@@ -3147,6 +3147,9 @@ int ata_pci_init_one (struct pci_dev *pdev, struct ata_port_info **port_info, ...@@ -3147,6 +3147,9 @@ int ata_pci_init_one (struct pci_dev *pdev, struct ata_port_info **port_info,
} }
rc = pci_set_dma_mask(pdev, ATA_DMA_MASK); rc = pci_set_dma_mask(pdev, ATA_DMA_MASK);
if (rc)
goto err_out_regions;
rc = pci_set_consistent_dma_mask(pdev, ATA_DMA_MASK);
if (rc) if (rc)
goto err_out_regions; goto err_out_regions;
......
...@@ -1667,6 +1667,9 @@ static int pdc_sata_init_one (struct pci_dev *pdev, const struct pci_device_id * ...@@ -1667,6 +1667,9 @@ static int pdc_sata_init_one (struct pci_dev *pdev, const struct pci_device_id *
goto err_out; goto err_out;
rc = pci_set_dma_mask(pdev, ATA_DMA_MASK); rc = pci_set_dma_mask(pdev, ATA_DMA_MASK);
if (rc)
goto err_out_regions;
rc = pci_set_consistent_dma_mask(pdev, ATA_DMA_MASK);
if (rc) if (rc)
goto err_out_regions; goto err_out_regions;
......
...@@ -329,6 +329,9 @@ static int sil_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) ...@@ -329,6 +329,9 @@ static int sil_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
goto err_out; goto err_out;
rc = pci_set_dma_mask(pdev, ATA_DMA_MASK); rc = pci_set_dma_mask(pdev, ATA_DMA_MASK);
if (rc)
goto err_out_regions;
rc = pci_set_consistent_dma_mask(pdev, ATA_DMA_MASK);
if (rc) if (rc)
goto err_out_regions; goto err_out_regions;
......
...@@ -287,6 +287,9 @@ static int k2_sata_init_one (struct pci_dev *pdev, const struct pci_device_id *e ...@@ -287,6 +287,9 @@ static int k2_sata_init_one (struct pci_dev *pdev, const struct pci_device_id *e
goto err_out; goto err_out;
rc = pci_set_dma_mask(pdev, ATA_DMA_MASK); rc = pci_set_dma_mask(pdev, ATA_DMA_MASK);
if (rc)
goto err_out_regions;
rc = pci_set_consistent_dma_mask(pdev, ATA_DMA_MASK);
if (rc) if (rc)
goto err_out_regions; goto err_out_regions;
......
...@@ -187,10 +187,10 @@ static int svia_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) ...@@ -187,10 +187,10 @@ static int svia_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
goto err_out_regions; goto err_out_regions;
} }
rc = pci_set_dma_mask(pdev, 0xffffffffULL); rc = pci_set_dma_mask(pdev, ATA_DMA_MASK);
if (rc) if (rc)
goto err_out_regions; goto err_out_regions;
rc = pci_set_consistent_dma_mask(pdev, 0xffffffffULL); rc = pci_set_consistent_dma_mask(pdev, ATA_DMA_MASK);
if (rc) if (rc)
goto err_out_regions; goto err_out_regions;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment