Skip to content

Commit

Permalink
I/OAT: cancel watchdog before dma remove
Browse files Browse the repository at this point in the history
Channel watchdog should be canceled before the rest of dma remove stuff.

Signed-off-by: Maciej Sosnowski <maciej.sosnowski@intel.com>
Signed-off-by: Shannon Nelson <shannon.nelson@intel.com>
Acked-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
  • Loading branch information
Maciej Sosnowski authored and Dan Williams committed Mar 4, 2009
1 parent 8b794b1 commit 2b8a6bf
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions drivers/dma/ioat_dma.c
Original file line number Diff line number Diff line change
Expand Up @@ -1705,6 +1705,9 @@ void ioat_dma_remove(struct ioatdma_device *device)
struct dma_chan *chan, *_chan;
struct ioat_dma_chan *ioat_chan;

if (device->version != IOAT_VER_3_0)
cancel_delayed_work(&device->work);

ioat_dma_remove_interrupts(device);

dma_async_device_unregister(&device->common);
Expand All @@ -1716,10 +1719,6 @@ void ioat_dma_remove(struct ioatdma_device *device)
pci_release_regions(device->pdev);
pci_disable_device(device->pdev);

if (device->version != IOAT_VER_3_0) {
cancel_delayed_work(&device->work);
}

list_for_each_entry_safe(chan, _chan,
&device->common.channels, device_node) {
ioat_chan = to_ioat_chan(chan);
Expand Down

0 comments on commit 2b8a6bf

Please sign in to comment.