diff options
author | Dave Jiang <djiang@mvista.com> | 2007-07-19 10:50:10 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-19 19:04:55 +0200 |
commit | 456a2f9552e7849475f4aea1a9aa4c0e54b3ddda (patch) | |
tree | df1a120c837fe4c4635c55d81e249ee6d06f4436 /drivers/edac/i5000_edac.c | |
parent | drivers/edac: Lindent r82600 (diff) | |
download | linux-456a2f9552e7849475f4aea1a9aa4c0e54b3ddda.tar.xz linux-456a2f9552e7849475f4aea1a9aa4c0e54b3ddda.zip |
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/i5000_edac.c')
-rw-r--r-- | drivers/edac/i5000_edac.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/drivers/edac/i5000_edac.c b/drivers/edac/i5000_edac.c index aa05c45efc08..4b4ec978df2c 100644 --- a/drivers/edac/i5000_edac.c +++ b/drivers/edac/i5000_edac.c @@ -28,6 +28,7 @@ * Alter this version for the I5000 module when modifications are made */ #define I5000_REVISION " Ver: 2.0.12 " __DATE__ +#define EDAC_MOD_STR "i5000_edac" #define i5000_printk(level, fmt, arg...) \ edac_printk(level, "i5000", fmt, ##arg) @@ -381,6 +382,8 @@ struct i5000_error_info { }; +static struct edac_pci_ctl_info *i5000_pci; + /****************************************************************************** * i5000_get_error_info Retrieve the hardware error information from * the hardware and cache it in the 'info' @@ -1375,6 +1378,17 @@ static int i5000_probe1(struct pci_dev *pdev, int dev_idx) i5000_clear_error(mci); + /* allocating generic PCI control info */ + i5000_pci = edac_pci_create_generic_ctl(&pdev->dev, EDAC_MOD_STR); + if (!i5000_pci) { + printk(KERN_WARNING + "%s(): Unable to create PCI control\n", + __func__); + printk(KERN_WARNING + "%s(): PCI error report via EDAC not setup\n", + __func__); + } + return 0; /* Error exit unwinding stack */ @@ -1420,6 +1434,9 @@ static void __devexit i5000_remove_one(struct pci_dev *pdev) debugf0(__FILE__ ": %s()\n", __func__); + if (i5000_pci) + edac_pci_release_generic_ctl(i5000_pci); + if ((mci = edac_mc_del_mc(&pdev->dev)) == NULL) return; |