From: Gavin Shan Date: Wed, 1 Oct 2014 04:34:51 +0000 (+1000) Subject: powerpc/eeh: Show hex prefix for PE state sysfs X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=2013add4ce73c93ae2148969a9ec3ecc8b1e26fa;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git powerpc/eeh: Show hex prefix for PE state sysfs As Michael suggested, the hex prefix for the output of EEH PE state sysfs entry (/sys/bus/pci/devices/xxx/eeh_pe_state) is always informative to users. Suggested-by: Michael Ellerman Signed-off-by: Gavin Shan Signed-off-by: Michael Ellerman --- diff --git a/arch/powerpc/kernel/eeh_sysfs.c b/arch/powerpc/kernel/eeh_sysfs.c index 9a44010bd4b5..f19b1e5cb060 100644 --- a/arch/powerpc/kernel/eeh_sysfs.c +++ b/arch/powerpc/kernel/eeh_sysfs.c @@ -65,7 +65,7 @@ static ssize_t eeh_pe_state_show(struct device *dev, return -ENODEV; state = eeh_ops->get_state(edev->pe, NULL); - return sprintf(buf, "%08x %08x\n", + return sprintf(buf, "%0x08x %0x08x\n", state, edev->pe->state); }