aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/edac/i82875p_edac.c
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2012-04-29 16:08:39 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-06-11 12:23:49 -0400
commit956b9ba156dbfdb9cede2b2927ddf8be2233b3a7 (patch)
tree6ece471eee029a1ca83ce649f7dc23020ebef182 /drivers/edac/i82875p_edac.c
parent7e881856eee8b889b76cd1d8e04ce2fc79b72099 (diff)
edac: Convert debugfX to edac_dbg(X,
Use a more common debugging style. Remove __FILE__ uses, add missing newlines, coalesce formats and align arguments. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/edac/i82875p_edac.c')
-rw-r--r--drivers/edac/i82875p_edac.c27
1 files changed, 13 insertions, 14 deletions
diff --git a/drivers/edac/i82875p_edac.c b/drivers/edac/i82875p_edac.c
index 4ded498047f7..db64bd74bc54 100644
--- a/drivers/edac/i82875p_edac.c
+++ b/drivers/edac/i82875p_edac.c
@@ -263,7 +263,7 @@ static void i82875p_check(struct mem_ctl_info *mci)
263{ 263{
264 struct i82875p_error_info info; 264 struct i82875p_error_info info;
265 265
266 debugf1("MC%d\n", mci->mc_idx); 266 edac_dbg(1, "MC%d\n", mci->mc_idx);
267 i82875p_get_error_info(mci, &info); 267 i82875p_get_error_info(mci, &info);
268 i82875p_process_error_info(mci, &info, 1); 268 i82875p_process_error_info(mci, &info, 1);
269} 269}
@@ -371,8 +371,7 @@ static void i82875p_init_csrows(struct mem_ctl_info *mci,
371 371
372 value = readb(ovrfl_window + I82875P_DRB + index); 372 value = readb(ovrfl_window + I82875P_DRB + index);
373 cumul_size = value << (I82875P_DRB_SHIFT - PAGE_SHIFT); 373 cumul_size = value << (I82875P_DRB_SHIFT - PAGE_SHIFT);
374 debugf3("(%d) cumul_size 0x%x\n", index, 374 edac_dbg(3, "(%d) cumul_size 0x%x\n", index, cumul_size);
375 cumul_size);
376 if (cumul_size == last_cumul_size) 375 if (cumul_size == last_cumul_size)
377 continue; /* not populated */ 376 continue; /* not populated */
378 377
@@ -405,7 +404,7 @@ static int i82875p_probe1(struct pci_dev *pdev, int dev_idx)
405 u32 nr_chans; 404 u32 nr_chans;
406 struct i82875p_error_info discard; 405 struct i82875p_error_info discard;
407 406
408 debugf0("\n"); 407 edac_dbg(0, "\n");
409 408
410 ovrfl_pdev = pci_get_device(PCI_VEND_DEV(INTEL, 82875_6), NULL); 409 ovrfl_pdev = pci_get_device(PCI_VEND_DEV(INTEL, 82875_6), NULL);
411 410
@@ -426,7 +425,7 @@ static int i82875p_probe1(struct pci_dev *pdev, int dev_idx)
426 goto fail0; 425 goto fail0;
427 } 426 }
428 427
429 debugf3("init mci\n"); 428 edac_dbg(3, "init mci\n");
430 mci->pdev = &pdev->dev; 429 mci->pdev = &pdev->dev;
431 mci->mtype_cap = MEM_FLAG_DDR; 430 mci->mtype_cap = MEM_FLAG_DDR;
432 mci->edac_ctl_cap = EDAC_FLAG_NONE | EDAC_FLAG_SECDED; 431 mci->edac_ctl_cap = EDAC_FLAG_NONE | EDAC_FLAG_SECDED;
@@ -437,7 +436,7 @@ static int i82875p_probe1(struct pci_dev *pdev, int dev_idx)
437 mci->dev_name = pci_name(pdev); 436 mci->dev_name = pci_name(pdev);
438 mci->edac_check = i82875p_check; 437 mci->edac_check = i82875p_check;
439 mci->ctl_page_to_phys = NULL; 438 mci->ctl_page_to_phys = NULL;
440 debugf3("init pvt\n"); 439 edac_dbg(3, "init pvt\n");
441 pvt = (struct i82875p_pvt *)mci->pvt_info; 440 pvt = (struct i82875p_pvt *)mci->pvt_info;
442 pvt->ovrfl_pdev = ovrfl_pdev; 441 pvt->ovrfl_pdev = ovrfl_pdev;
443 pvt->ovrfl_window = ovrfl_window; 442 pvt->ovrfl_window = ovrfl_window;
@@ -448,7 +447,7 @@ static int i82875p_probe1(struct pci_dev *pdev, int dev_idx)
448 * type of memory controller. The ID is therefore hardcoded to 0. 447 * type of memory controller. The ID is therefore hardcoded to 0.
449 */ 448 */
450 if (edac_mc_add_mc(mci)) { 449 if (edac_mc_add_mc(mci)) {
451 debugf3("failed edac_mc_add_mc()\n"); 450 edac_dbg(3, "failed edac_mc_add_mc()\n");
452 goto fail1; 451 goto fail1;
453 } 452 }
454 453
@@ -464,7 +463,7 @@ static int i82875p_probe1(struct pci_dev *pdev, int dev_idx)
464 } 463 }
465 464
466 /* get this far and it's successful */ 465 /* get this far and it's successful */
467 debugf3("success\n"); 466 edac_dbg(3, "success\n");
468 return 0; 467 return 0;
469 468
470fail1: 469fail1:
@@ -485,7 +484,7 @@ static int __devinit i82875p_init_one(struct pci_dev *pdev,
485{ 484{
486 int rc; 485 int rc;
487 486
488 debugf0("\n"); 487 edac_dbg(0, "\n");
489 i82875p_printk(KERN_INFO, "i82875p init one\n"); 488 i82875p_printk(KERN_INFO, "i82875p init one\n");
490 489
491 if (pci_enable_device(pdev) < 0) 490 if (pci_enable_device(pdev) < 0)
@@ -504,7 +503,7 @@ static void __devexit i82875p_remove_one(struct pci_dev *pdev)
504 struct mem_ctl_info *mci; 503 struct mem_ctl_info *mci;
505 struct i82875p_pvt *pvt = NULL; 504 struct i82875p_pvt *pvt = NULL;
506 505
507 debugf0("\n"); 506 edac_dbg(0, "\n");
508 507
509 if (i82875p_pci) 508 if (i82875p_pci)
510 edac_pci_release_generic_ctl(i82875p_pci); 509 edac_pci_release_generic_ctl(i82875p_pci);
@@ -550,7 +549,7 @@ static int __init i82875p_init(void)
550{ 549{
551 int pci_rc; 550 int pci_rc;
552 551
553 debugf3("\n"); 552 edac_dbg(3, "\n");
554 553
555 /* Ensure that the OPSTATE is set correctly for POLL or NMI */ 554 /* Ensure that the OPSTATE is set correctly for POLL or NMI */
556 opstate_init(); 555 opstate_init();
@@ -565,7 +564,7 @@ static int __init i82875p_init(void)
565 PCI_DEVICE_ID_INTEL_82875_0, NULL); 564 PCI_DEVICE_ID_INTEL_82875_0, NULL);
566 565
567 if (!mci_pdev) { 566 if (!mci_pdev) {
568 debugf0("875p pci_get_device fail\n"); 567 edac_dbg(0, "875p pci_get_device fail\n");
569 pci_rc = -ENODEV; 568 pci_rc = -ENODEV;
570 goto fail1; 569 goto fail1;
571 } 570 }
@@ -573,7 +572,7 @@ static int __init i82875p_init(void)
573 pci_rc = i82875p_init_one(mci_pdev, i82875p_pci_tbl); 572 pci_rc = i82875p_init_one(mci_pdev, i82875p_pci_tbl);
574 573
575 if (pci_rc < 0) { 574 if (pci_rc < 0) {
576 debugf0("875p init fail\n"); 575 edac_dbg(0, "875p init fail\n");
577 pci_rc = -ENODEV; 576 pci_rc = -ENODEV;
578 goto fail1; 577 goto fail1;
579 } 578 }
@@ -593,7 +592,7 @@ fail0:
593 592
594static void __exit i82875p_exit(void) 593static void __exit i82875p_exit(void)
595{ 594{
596 debugf3("\n"); 595 edac_dbg(3, "\n");
597 596
598 i82875p_remove_one(mci_pdev); 597 i82875p_remove_one(mci_pdev);
599 pci_dev_put(mci_pdev); 598 pci_dev_put(mci_pdev);