From: Linas Vepstas Date: Thu, 30 Mar 2006 21:27:33 +0000 (-0600) Subject: [PATCH] powerpc/pseries: fix device name printing, again. X-Git-Tag: v2.6.17-rc1~16^2~6 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a219be2cf48fc77e73936d07187a5f8d1bca2511;p=platform%2Fkernel%2Flinux-3.10.git [PATCH] powerpc/pseries: fix device name printing, again. The recent patch to print device names in EEH reset messages was lacking ... this patch works better. Signed-off-by: Linas Vepstas Signed-off-by: Paul Mackerras --- diff --git a/arch/powerpc/platforms/pseries/eeh_driver.c b/arch/powerpc/platforms/pseries/eeh_driver.c index 0c6b7d7..1fba695 100644 --- a/arch/powerpc/platforms/pseries/eeh_driver.c +++ b/arch/powerpc/platforms/pseries/eeh_driver.c @@ -293,9 +293,10 @@ void handle_eeh_events (struct eeh_event *event) frozen_pdn = PCI_DN(frozen_dn); frozen_pdn->eeh_freeze_count++; - pci_str = pci_name (frozen_pdn->pcidev); - drv_str = pcid_name (frozen_pdn->pcidev); - if (!pci_str) { + if (frozen_pdn->pcidev) { + pci_str = pci_name (frozen_pdn->pcidev); + drv_str = pcid_name (frozen_pdn->pcidev); + } else { pci_str = pci_name (event->dev); drv_str = pcid_name (event->dev); }