aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/edac/i3000_edac.c
diff options
context:
space:
mode:
authorDave Jiang <djiang@mvista.com>2007-07-19 04:50:10 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-07-19 13:04:55 -0400
commit456a2f9552e7849475f4aea1a9aa4c0e54b3ddda (patch)
treedf1a120c837fe4c4635c55d81e249ee6d06f4436 /drivers/edac/i3000_edac.c
parentcddbfcacf02dc2d5b074fc2717358a7529a190db (diff)
drivers/edac: drivers to use new PCI operation
Move x86 drivers to new pci controller setup Signed-off-by: Dave Jiang <djiang@mvista.com> Signed-off-by: Douglas Thompson <dougthompson@xmission.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/edac/i3000_edac.c')
-rw-r--r--drivers/edac/i3000_edac.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/edac/i3000_edac.c b/drivers/edac/i3000_edac.c
index c8418fcea254..fa4c4d48756f 100644
--- a/drivers/edac/i3000_edac.c
+++ b/drivers/edac/i3000_edac.c
@@ -153,6 +153,7 @@ static const struct i3000_dev_info i3000_devs[] = {
153 153
154static struct pci_dev *mci_pdev = NULL; 154static struct pci_dev *mci_pdev = NULL;
155static int i3000_registered = 1; 155static int i3000_registered = 1;
156static struct edac_pci_ctl_info *i3000_pci;
156 157
157static void i3000_get_error_info(struct mem_ctl_info *mci, 158static void i3000_get_error_info(struct mem_ctl_info *mci,
158 struct i3000_error_info *info) 159 struct i3000_error_info *info)
@@ -373,6 +374,17 @@ static int i3000_probe1(struct pci_dev *pdev, int dev_idx)
373 goto fail; 374 goto fail;
374 } 375 }
375 376
377 /* allocating generic PCI control info */
378 i3000_pci = edac_pci_create_generic_ctl(&pdev->dev, EDAC_MOD_STR);
379 if (!i3000_pci) {
380 printk(KERN_WARNING
381 "%s(): Unable to create PCI control\n",
382 __func__);
383 printk(KERN_WARNING
384 "%s(): PCI error report via EDAC not setup\n",
385 __func__);
386 }
387
376 /* get this far and it's successful */ 388 /* get this far and it's successful */
377 debugf3("MC: %s(): success\n", __func__); 389 debugf3("MC: %s(): success\n", __func__);
378 return 0; 390 return 0;
@@ -408,6 +420,9 @@ static void __devexit i3000_remove_one(struct pci_dev *pdev)
408 420
409 debugf0("%s()\n", __func__); 421 debugf0("%s()\n", __func__);
410 422
423 if (i3000_pci)
424 edac_pci_release_generic_ctl(i3000_pci);
425
411 if ((mci = edac_mc_del_mc(&pdev->dev)) == NULL) 426 if ((mci = edac_mc_del_mc(&pdev->dev)) == NULL)
412 return; 427 return;
413 428