diff options
author | Dan Aloni <da\\-x@monatomic.org> | 2007-03-08 12:57:36 -0500 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2007-07-11 19:10:53 -0400 |
commit | 428ed6024fa74a271142f3257966e9b5e1cb37a1 (patch) | |
tree | b74af2d50f292ec377a567368e0dd41fe439d1b7 /drivers | |
parent | e00c5d8b4d800b95b72b3f072e1d55d7c7034702 (diff) |
I/OAT: fix I/OAT for kexec
Under kexec, I/OAT initialization breaks over busy resources because the
previous kernel did not release them.
I'm not sure this fix can be considered a complete one but it works for me.
I guess something similar to the *_remove method should occur there..
Signed-off-by: Dan Aloni <da-x@monatomic.org>
Signed-off-by: Chris Leech <christopher.leech@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/dma/ioatdma.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/dma/ioatdma.c b/drivers/dma/ioatdma.c index b3fca1200a73..c4209af4fde4 100644 --- a/drivers/dma/ioatdma.c +++ b/drivers/dma/ioatdma.c | |||
@@ -41,6 +41,7 @@ | |||
41 | 41 | ||
42 | /* internal functions */ | 42 | /* internal functions */ |
43 | static int __devinit ioat_probe(struct pci_dev *pdev, const struct pci_device_id *ent); | 43 | static int __devinit ioat_probe(struct pci_dev *pdev, const struct pci_device_id *ent); |
44 | static void ioat_shutdown(struct pci_dev *pdev); | ||
44 | static void __devexit ioat_remove(struct pci_dev *pdev); | 45 | static void __devexit ioat_remove(struct pci_dev *pdev); |
45 | 46 | ||
46 | static int enumerate_dma_channels(struct ioat_device *device) | 47 | static int enumerate_dma_channels(struct ioat_device *device) |
@@ -557,6 +558,7 @@ static struct pci_driver ioat_pci_driver = { | |||
557 | .name = "ioatdma", | 558 | .name = "ioatdma", |
558 | .id_table = ioat_pci_tbl, | 559 | .id_table = ioat_pci_tbl, |
559 | .probe = ioat_probe, | 560 | .probe = ioat_probe, |
561 | .shutdown = ioat_shutdown, | ||
560 | .remove = __devexit_p(ioat_remove), | 562 | .remove = __devexit_p(ioat_remove), |
561 | }; | 563 | }; |
562 | 564 | ||
@@ -781,9 +783,20 @@ err_request_regions: | |||
781 | err_set_dma_mask: | 783 | err_set_dma_mask: |
782 | pci_disable_device(pdev); | 784 | pci_disable_device(pdev); |
783 | err_enable_device: | 785 | err_enable_device: |
786 | |||
787 | printk(KERN_ERR "Intel(R) I/OAT DMA Engine initialization failed\n"); | ||
788 | |||
784 | return err; | 789 | return err; |
785 | } | 790 | } |
786 | 791 | ||
792 | static void ioat_shutdown(struct pci_dev *pdev) | ||
793 | { | ||
794 | struct ioat_device *device; | ||
795 | device = pci_get_drvdata(pdev); | ||
796 | |||
797 | dma_async_device_unregister(&device->common); | ||
798 | } | ||
799 | |||
787 | static void __devexit ioat_remove(struct pci_dev *pdev) | 800 | static void __devexit ioat_remove(struct pci_dev *pdev) |
788 | { | 801 | { |
789 | struct ioat_device *device; | 802 | struct ioat_device *device; |