Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 71241
b: refs/heads/master
c: dfe2299
h: refs/heads/master
i:
  71239: fa3e9f3
v: v3
  • Loading branch information
Shannon Nelson authored and Linus Torvalds committed Oct 18, 2007
1 parent 5e25d36 commit 7d4579f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 9 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: 7df7cf0676060d778486359676734447347e1caf
refs/heads/master: dfe2299e7b35a0adfc87f04d3e725ccc508d7626
11 changes: 5 additions & 6 deletions trunk/drivers/dma/ioat.c
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ static int ioat_setup_functionality(struct pci_dev *pdev, void __iomem *iobase)
switch (version) {
case IOAT_VER_1_2:
device->dma = ioat_dma_probe(pdev, iobase);
if (ioat_dca_enabled)
if (device->dma && ioat_dca_enabled)
device->dca = ioat_dca_init(pdev, iobase);
break;
default:
Expand All @@ -85,17 +85,16 @@ static void ioat_shutdown_functionality(struct pci_dev *pdev)
{
struct ioat_device *device = pci_get_drvdata(pdev);

if (device->dma) {
ioat_dma_remove(device->dma);
device->dma = NULL;
}

if (device->dca) {
unregister_dca_provider(device->dca);
free_dca_provider(device->dca);
device->dca = NULL;
}

if (device->dma) {
ioat_dma_remove(device->dma);
device->dma = NULL;
}
}

static struct pci_driver ioat_pci_driver = {
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/dma/ioat_dma.c
Original file line number Diff line number Diff line change
Expand Up @@ -941,10 +941,10 @@ void ioat_dma_remove(struct ioatdma_device *device)
struct dma_chan *chan, *_chan;
struct ioat_dma_chan *ioat_chan;

dma_async_device_unregister(&device->common);

ioat_dma_remove_interrupts(device);

dma_async_device_unregister(&device->common);

pci_pool_destroy(device->dma_pool);
pci_pool_destroy(device->completion_pool);

Expand Down

0 comments on commit 7d4579f

Please sign in to comment.