diff options
author | Doug Thompson <dougthompson@xmission.com> | 2007-07-19 04:50:26 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-19 13:04:57 -0400 |
commit | b8f6f9755248026f21282e25cac49a1af698056c (patch) | |
tree | c133319ae70b99d60415aa833719911d47420297 /drivers/edac/i82443bxgx_edac.c | |
parent | fd309a9d8e63e9176759d00630b65d772ae06e0c (diff) |
drivers/edac: fix edac_mc init apis
Refactoring of sysfs code necessitated the refactoring of the edac_mc_alloc()
and edac_mc_add_mc() apis, of moving the index value to the alloc() function.
This patch alters the in tree drivers to utilize this new api signature.
Having the index value performed later created a chicken-and-the-egg issue.
Moving it to the alloc() function allows for creating the necessary sysfs
entries with the proper index number
Cc: Alan Cox alan@lxorguk.ukuu.org.uk
Signed-off-by: Doug Thompson <dougthompson@xmission.com>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/edac/i82443bxgx_edac.c')
-rw-r--r-- | drivers/edac/i82443bxgx_edac.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/edac/i82443bxgx_edac.c b/drivers/edac/i82443bxgx_edac.c index 445ed56558f1..83bfe37c4bbb 100644 --- a/drivers/edac/i82443bxgx_edac.c +++ b/drivers/edac/i82443bxgx_edac.c | |||
@@ -239,7 +239,7 @@ static int i82443bxgx_edacmc_probe1(struct pci_dev *pdev, int dev_idx) | |||
239 | if (pci_read_config_dword(pdev, I82443BXGX_NBXCFG, &nbxcfg)) | 239 | if (pci_read_config_dword(pdev, I82443BXGX_NBXCFG, &nbxcfg)) |
240 | return -EIO; | 240 | return -EIO; |
241 | 241 | ||
242 | mci = edac_mc_alloc(0, I82443BXGX_NR_CSROWS, I82443BXGX_NR_CHANS); | 242 | mci = edac_mc_alloc(0, I82443BXGX_NR_CSROWS, I82443BXGX_NR_CHANS, 0); |
243 | 243 | ||
244 | if (mci == NULL) | 244 | if (mci == NULL) |
245 | return -ENOMEM; | 245 | return -ENOMEM; |
@@ -314,7 +314,7 @@ static int i82443bxgx_edacmc_probe1(struct pci_dev *pdev, int dev_idx) | |||
314 | mci->edac_check = i82443bxgx_edacmc_check; | 314 | mci->edac_check = i82443bxgx_edacmc_check; |
315 | mci->ctl_page_to_phys = NULL; | 315 | mci->ctl_page_to_phys = NULL; |
316 | 316 | ||
317 | if (edac_mc_add_mc(mci, 0)) { | 317 | if (edac_mc_add_mc(mci)) { |
318 | debugf3("%s(): failed edac_mc_add_mc()\n", __func__); | 318 | debugf3("%s(): failed edac_mc_add_mc()\n", __func__); |
319 | goto fail; | 319 | goto fail; |
320 | } | 320 | } |