Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=e0f90b64181d668ce5995a40f312ed21085bfa98
Commit:     e0f90b64181d668ce5995a40f312ed21085bfa98
Parent:     39d16e295966a1f0025a65eaab4cb59fe5ba8c17
Author:     Linas Vepstas <[EMAIL PROTECTED]>
AuthorDate: Mon Mar 19 14:52:04 2007 -0500
Committer:  Paul Mackerras <[EMAIL PROTECTED]>
CommitDate: Thu Mar 22 22:52:50 2007 +1100

    [POWERPC] EEH: Add clarifying messages.
    
    There are multiple code patchs tht resuls in a "permanent
    failure"; when examining rare events, it can be hard to see
    which was taken. This patch adds printk's to assist.
    
    Signed-off-by: Linas Vepstas <[EMAIL PROTECTED]>
    Signed-off-by: Paul Mackerras <[EMAIL PROTECTED]>
---
 arch/powerpc/platforms/pseries/eeh_driver.c |   20 +++++++++++++++-----
 1 files changed, 15 insertions(+), 5 deletions(-)

diff --git a/arch/powerpc/platforms/pseries/eeh_driver.c 
b/arch/powerpc/platforms/pseries/eeh_driver.c
index a4c0bf8..550fad2 100644
--- a/arch/powerpc/platforms/pseries/eeh_driver.c
+++ b/arch/powerpc/platforms/pseries/eeh_driver.c
@@ -367,8 +367,10 @@ struct pci_dn * handle_eeh_events (struct eeh_event *event)
         */
        if ((event->state == pci_channel_io_perm_failure) &&
            ((event->time_unavail <= 0) ||
-            (event->time_unavail > MAX_WAIT_FOR_RECOVERY*1000)))
+            (event->time_unavail > MAX_WAIT_FOR_RECOVERY*1000))) {
+               printk(KERN_WARNING "EEH: Permanent failure\n");
                goto hard_fail;
+       }
 
        eeh_slot_error_detail(frozen_pdn, 1 /* Temporary Error */);
        printk(KERN_WARNING
@@ -390,8 +392,10 @@ struct pci_dn * handle_eeh_events (struct eeh_event *event)
         */
        if (result == PCI_ERS_RESULT_NONE) {
                rc = eeh_reset_device(frozen_pdn, frozen_bus);
-               if (rc)
+               if (rc) {
+                       printk(KERN_WARNING "EEH: Unable to reset, rc=%d\n", 
rc);
                        goto hard_fail;
+               }
        }
 
        /* If all devices reported they can proceed, then re-enable MMIO */
@@ -417,21 +421,27 @@ struct pci_dn * handle_eeh_events (struct eeh_event 
*event)
        }
 
        /* If any device has a hard failure, then shut off everything. */
-       if (result == PCI_ERS_RESULT_DISCONNECT)
+       if (result == PCI_ERS_RESULT_DISCONNECT) {
+               printk(KERN_WARNING "EEH: Device driver gave up\n");
                goto hard_fail;
+       }
 
        /* If any device called out for a reset, then reset the slot */
        if (result == PCI_ERS_RESULT_NEED_RESET) {
                rc = eeh_reset_device(frozen_pdn, NULL);
-               if (rc)
+               if (rc) {
+                       printk(KERN_WARNING "EEH: Cannot reset, rc=%d\n", rc);
                        goto hard_fail;
+               }
                result = PCI_ERS_RESULT_NONE;
                pci_walk_bus(frozen_bus, eeh_report_reset, &result);
        }
 
        /* All devices should claim they have recovered by now. */
-       if (result != PCI_ERS_RESULT_RECOVERED)
+       if (result != PCI_ERS_RESULT_RECOVERED) {
+               printk(KERN_WARNING "EEH: Not recovered\n");
                goto hard_fail;
+       }
 
        /* Tell all device drivers that they can resume operations */
        pci_walk_bus(frozen_bus, eeh_report_resume, NULL);
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to