linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log
@ 2016-07-22 17:05 Guilherme G. Piccoli
  2016-07-25  0:17 ` Gavin Shan
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Guilherme G. Piccoli @ 2016-07-22 17:05 UTC (permalink / raw)
  To: linuxppc-dev, ruscur; +Cc: mpe, benh, paulus, gwshan

This is a very minor/trivial fix for the output of PCI address on EEH logs.
The PCI address on "OF node" field currently is using ":" as a separator
for the function, but the usual separator is ".". This patch changes the
separator for dot, so the PCI address is printed as usual.

No functional changes were introduced.

Signed-off-by: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com>
---
 arch/powerpc/kernel/eeh.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/powerpc/kernel/eeh.c b/arch/powerpc/kernel/eeh.c
index c9bc78e..7429556 100644
--- a/arch/powerpc/kernel/eeh.c
+++ b/arch/powerpc/kernel/eeh.c
@@ -168,10 +168,10 @@ static size_t eeh_dump_dev_log(struct eeh_dev *edev, char *buf, size_t len)
 	int n = 0, l = 0;
 	char buffer[128];
 
-	n += scnprintf(buf+n, len-n, "%04x:%02x:%02x:%01x\n",
+	n += scnprintf(buf+n, len-n, "%04x:%02x:%02x.%01x\n",
 		       edev->phb->global_number, pdn->busno,
 		       PCI_SLOT(pdn->devfn), PCI_FUNC(pdn->devfn));
-	pr_warn("EEH: of node=%04x:%02x:%02x:%01x\n",
+	pr_warn("EEH: of node=%04x:%02x:%02x.%01x\n",
 		edev->phb->global_number, pdn->busno,
 		PCI_SLOT(pdn->devfn), PCI_FUNC(pdn->devfn));
 
-- 
2.1.0

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log
  2016-07-22 17:05 [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log Guilherme G. Piccoli
@ 2016-07-25  0:17 ` Gavin Shan
  2016-07-25  0:47 ` Michael Ellerman
  2016-08-09 11:26 ` Michael Ellerman
  2 siblings, 0 replies; 8+ messages in thread
From: Gavin Shan @ 2016-07-25  0:17 UTC (permalink / raw)
  To: Guilherme G. Piccoli; +Cc: linuxppc-dev, ruscur, mpe, benh, paulus, gwshan

On Fri, Jul 22, 2016 at 02:05:29PM -0300, Guilherme G. Piccoli wrote:
>This is a very minor/trivial fix for the output of PCI address on EEH logs.
>The PCI address on "OF node" field currently is using ":" as a separator
>for the function, but the usual separator is ".". This patch changes the
>separator for dot, so the PCI address is printed as usual.
>
>No functional changes were introduced.
>
>Signed-off-by: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com>

Reviewed-by: Gavin Shan <gwshan@linux.vnet.ibm.com>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log
  2016-07-22 17:05 [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log Guilherme G. Piccoli
  2016-07-25  0:17 ` Gavin Shan
@ 2016-07-25  0:47 ` Michael Ellerman
  2016-07-25  1:46   ` Gavin Shan
  2016-07-25  1:50   ` Guilherme G. Piccoli
  2016-08-09 11:26 ` Michael Ellerman
  2 siblings, 2 replies; 8+ messages in thread
From: Michael Ellerman @ 2016-07-25  0:47 UTC (permalink / raw)
  To: Guilherme G. Piccoli, linuxppc-dev, ruscur; +Cc: benh, paulus, gwshan

"Guilherme G. Piccoli" <gpiccoli@linux.vnet.ibm.com> writes:

> This is a very minor/trivial fix for the output of PCI address on EEH logs.
> The PCI address on "OF node" field currently is using ":" as a separator
> for the function, but the usual separator is ".". This patch changes the
> separator for dot, so the PCI address is printed as usual.
>
> No functional changes were introduced.

What consumes the log? Can it cope with us changing the formatting?

cheers

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log
  2016-07-25  0:47 ` Michael Ellerman
@ 2016-07-25  1:46   ` Gavin Shan
  2016-07-25  1:54     ` Guilherme G. Piccoli
  2016-08-03 13:50     ` Guilherme G. Piccoli
  2016-07-25  1:50   ` Guilherme G. Piccoli
  1 sibling, 2 replies; 8+ messages in thread
From: Gavin Shan @ 2016-07-25  1:46 UTC (permalink / raw)
  To: Michael Ellerman
  Cc: Guilherme G. Piccoli, linuxppc-dev, ruscur, benh, paulus, gwshan

On Mon, Jul 25, 2016 at 10:47:13AM +1000, Michael Ellerman wrote:
>"Guilherme G. Piccoli" <gpiccoli@linux.vnet.ibm.com> writes:
>
>> This is a very minor/trivial fix for the output of PCI address on EEH logs.
>> The PCI address on "OF node" field currently is using ":" as a separator
>> for the function, but the usual separator is ".". This patch changes the
>> separator for dot, so the PCI address is printed as usual.
>>
>> No functional changes were introduced.
>
>What consumes the log? Can it cope with us changing the formatting?
>

The log is printed by pr_warn() as part of the EEH kernel log. Also,
it's argument passed to RTAS call "ibm,slot-error-detail" and it's
put into the user data section of the RTAS call's output, which is
used by RTAS daemon (rtasd) then. I don't see anyone expects fixed
format for it in the user data section.

The format was ever adjusted in commit 0ed352dddbfc ("powerpc/eeh:
Reduce lines of log dump") on Jul 17 2014. No complains received
against it so far. I guess nobody cares about the format or there
is a alarm isn't raised yet :)

Thanks,
Gavin

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log
  2016-07-25  0:47 ` Michael Ellerman
  2016-07-25  1:46   ` Gavin Shan
@ 2016-07-25  1:50   ` Guilherme G. Piccoli
  1 sibling, 0 replies; 8+ messages in thread
From: Guilherme G. Piccoli @ 2016-07-25  1:50 UTC (permalink / raw)
  To: Michael Ellerman, ruscur, gwshan; +Cc: linuxppc-dev, paulus

On 07/24/2016 09:47 PM, Michael Ellerman wrote:
> "Guilherme G. Piccoli" <gpiccoli@linux.vnet.ibm.com> writes:
>
>> This is a very minor/trivial fix for the output of PCI address on EEH logs.
>> The PCI address on "OF node" field currently is using ":" as a separator
>> for the function, but the usual separator is ".". This patch changes the
>> separator for dot, so the PCI address is printed as usual.
>>
>> No functional changes were introduced.
>
> What consumes the log? Can it cope with us changing the formatting?

Michael, as far as I understand (Russel and Gavin surely knows better 
and can correct me if I'm wrong) the only consumer that doesn't just 
output the error information to screen is pseries' get_log handler, 
which will pass this log information through a rtas_call 
(ibm_slot_error_detail).

Now, I imagine this information might be consumed in the end for the 
FSP, by reporting EEH errors there, but my testing in one LPAR showed me 
no errors in FSP after an EEH (without the patch applied). Maybe I'm 
missing a FSP configuration to be able to show the errors there?

Thanks,


Guilherme


>
> cheers
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev
>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log
  2016-07-25  1:46   ` Gavin Shan
@ 2016-07-25  1:54     ` Guilherme G. Piccoli
  2016-08-03 13:50     ` Guilherme G. Piccoli
  1 sibling, 0 replies; 8+ messages in thread
From: Guilherme G. Piccoli @ 2016-07-25  1:54 UTC (permalink / raw)
  To: Gavin Shan, Michael Ellerman; +Cc: paulus, linuxppc-dev

On 07/24/2016 10:46 PM, Gavin Shan wrote:
> On Mon, Jul 25, 2016 at 10:47:13AM +1000, Michael Ellerman wrote:
>> "Guilherme G. Piccoli" <gpiccoli@linux.vnet.ibm.com> writes:
>>
>>> This is a very minor/trivial fix for the output of PCI address on EEH logs.
>>> The PCI address on "OF node" field currently is using ":" as a separator
>>> for the function, but the usual separator is ".". This patch changes the
>>> separator for dot, so the PCI address is printed as usual.
>>>
>>> No functional changes were introduced.
>>
>> What consumes the log? Can it cope with us changing the formatting?
>>
>
> The log is printed by pr_warn() as part of the EEH kernel log. Also,
> it's argument passed to RTAS call "ibm,slot-error-detail" and it's
> put into the user data section of the RTAS call's output, which is
> used by RTAS daemon (rtasd) then. I don't see anyone expects fixed
> format for it in the user data section.
>
> The format was ever adjusted in commit 0ed352dddbfc ("powerpc/eeh:
> Reduce lines of log dump") on Jul 17 2014. No complains received
> against it so far. I guess nobody cares about the format or there
> is a alarm isn't raised yet :)

Thanks very much for the details Gavin.

You can "discard" my last reply then, since this explains the use of 
"ibm,slot-error-detail" correctly.

Cheers,


Guilherme


>
> Thanks,
> Gavin
>
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev
>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log
  2016-07-25  1:46   ` Gavin Shan
  2016-07-25  1:54     ` Guilherme G. Piccoli
@ 2016-08-03 13:50     ` Guilherme G. Piccoli
  1 sibling, 0 replies; 8+ messages in thread
From: Guilherme G. Piccoli @ 2016-08-03 13:50 UTC (permalink / raw)
  To: Gavin Shan, Michael Ellerman; +Cc: paulus, linuxppc-dev

On 07/24/2016 10:46 PM, Gavin Shan wrote:
> On Mon, Jul 25, 2016 at 10:47:13AM +1000, Michael Ellerman wrote:
>> "Guilherme G. Piccoli" <gpiccoli@linux.vnet.ibm.com> writes:
>>
>>> This is a very minor/trivial fix for the output of PCI address on EEH logs.
>>> The PCI address on "OF node" field currently is using ":" as a separator
>>> for the function, but the usual separator is ".". This patch changes the
>>> separator for dot, so the PCI address is printed as usual.
>>>
>>> No functional changes were introduced.
>>
>> What consumes the log? Can it cope with us changing the formatting?
>>
>
> The log is printed by pr_warn() as part of the EEH kernel log. Also,
> it's argument passed to RTAS call "ibm,slot-error-detail" and it's
> put into the user data section of the RTAS call's output, which is
> used by RTAS daemon (rtasd) then. I don't see anyone expects fixed
> format for it in the user data section.
>
> The format was ever adjusted in commit 0ed352dddbfc ("powerpc/eeh:
> Reduce lines of log dump") on Jul 17 2014. No complains received
> against it so far. I guess nobody cares about the format or there
> is a alarm isn't raised yet :)
>
> Thanks,
> Gavin

Quick follow-up on this: RTAS daemon stores the information captured via 
ibm,slot-error-detail in a log file, which can be accessed using the 
command "rtas_dump -f /var/log/platform". More information on this can 
be found in 
https://www.ibm.com/support/knowledgecenter/linuxonibm/liaau/liaau-diagnosing-rtas-events.htm 
.

I was able to check this log and the EEH PCI address output was there, 
in ascii text format.

Thanks,

Guilherme


>
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev
>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log
  2016-07-22 17:05 [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log Guilherme G. Piccoli
  2016-07-25  0:17 ` Gavin Shan
  2016-07-25  0:47 ` Michael Ellerman
@ 2016-08-09 11:26 ` Michael Ellerman
  2 siblings, 0 replies; 8+ messages in thread
From: Michael Ellerman @ 2016-08-09 11:26 UTC (permalink / raw)
  To: Guilherme G. Piccoli, linuxppc-dev, ruscur; +Cc: paulus, gwshan

On Fri, 2016-22-07 at 17:05:29 UTC, "Guilherme G. Piccoli" wrote:
> This is a very minor/trivial fix for the output of PCI address on EEH logs.
> The PCI address on "OF node" field currently is using ":" as a separator
> for the function, but the usual separator is ".". This patch changes the
> separator for dot, so the PCI address is printed as usual.
> 
> No functional changes were introduced.
> 
> Signed-off-by: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com>
> Reviewed-by: Gavin Shan <gwshan@linux.vnet.ibm.com>

Applied to powerpc fixes, thanks.

https://git.kernel.org/powerpc/c/10560b9afc8abf349843dff88c

cheers

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2016-08-09 11:26 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-22 17:05 [PATCH] powerpc/eeh: trivial fix to non-conventional PCI address output on EEH log Guilherme G. Piccoli
2016-07-25  0:17 ` Gavin Shan
2016-07-25  0:47 ` Michael Ellerman
2016-07-25  1:46   ` Gavin Shan
2016-07-25  1:54     ` Guilherme G. Piccoli
2016-08-03 13:50     ` Guilherme G. Piccoli
2016-07-25  1:50   ` Guilherme G. Piccoli
2016-08-09 11:26 ` Michael Ellerman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).