Re: [PATCH v2] powerpc/powernv: hwmon driver for power values, fan rpm and temperature

2014-05-28 Thread Guenter Roeck
On 05/19/2014 07:26 AM, Neelesh Gupta wrote: This patch adds basic kernel enablement for reading power values, fan speed rpm and temperature values on powernv platforms which will be exported to user space through sysfs interface. Test results: - [root@tul163p1 ~]# sensors ibmpowernv

Re: [PATCH v2] powerpc/powernv: hwmon driver for power values, fan rpm and temperature

2014-05-28 Thread Benjamin Herrenschmidt
On Wed, 2014-05-28 at 00:23 -0700, Guenter Roeck wrote: > Consider using of_property_read_u32(). > > > + sdata[count].id = *sensor_id; > > + sdata[count].type = type; Especially since this is broken for Little Endian ! Neelesh, please make sure you test your patch on LE.

Re: [V6 00/11] perf: New conditional branch filter

2014-05-28 Thread Anshuman Khandual
On 05/27/2014 05:39 PM, Stephane Eranian wrote: > I have been looking at those patches and ran some tests. > And I found a few issues so far. > > I am running: > $ perf record -j any_ret -e cycles:u test_program > $ perf report -D > > Most entries are okay and match the filter, however some do no

[PATCH 2/2] selftests/powerpc: Test the THP bug we fixed in the previous commit

2014-05-28 Thread Michael Ellerman
Signed-off-by: Michael Ellerman --- tools/testing/selftests/powerpc/Makefile | 2 +- tools/testing/selftests/powerpc/mm/Makefile| 18 ++ .../selftests/powerpc/mm/hugetlb_vs_thp_test.c | 72 ++ 3 files changed, 91 insertions(+), 1 deletion(-) create

[PATCH 1/2] powerpc/mm: Check paca psize is up to date for huge mappings

2014-05-28 Thread Michael Ellerman
We have a bug in our hugepage handling which exhibits as an infinite loop of hash faults. If the fault is being taken in the kernel it will typically trigger the softlockup detector, or the RCU stall detector. The bug is as follows: 1. mmap(0xa000, ..., MAP_FIXED | MAP_HUGE_TLB | MAP_ANONYMO

[PATCH] powerpc/85xx: Add T4240RDB board support

2014-05-28 Thread Chunhe Lan
T4240RDB board Specification Memory subsystem: 6GB DDR3 128MB NOR flash 2GB NAND flash Ethernet: Eight 1G SGMII ports Four 10Gbps SFP+ ports PCIe: Two PCIe slots USB: Two USB2.0 Type A ports SDHC: One SD-card port SATA: One S

[PATCH] t4240/dts: Enable third elo3 DMA engine support

2014-05-28 Thread Chunhe Lan
T4240QDS and T4240RDB have the third DMA engine controller. So add corresponding DMA node into dts file. Signed-off-by: Chunhe Lan Cc: Scott Wood --- arch/powerpc/boot/dts/fsl/t4240si-post.dtsi |1 + arch/powerpc/boot/dts/fsl/t4240si-pre.dtsi |1 + 2 files changed, 2 insertions(+), 0 d

RE: [PATCH 11/16] byteorder: provide a linux/byteorder.h with {be, le}_to_cpu() and cpu_to_{be, le}() macros

2014-05-28 Thread David Laight
From: Cody P Schafer > Rather manually specifying the size of the integer to be converted, key > off of the type size. Reduces duplicate size info and the occurance of > certain types of bugs (using the wrong sized conversion). ... > +#define be_to_cpu(v) \ > + __builtin_choose_expr(sizeof(v) =

Kernel 3.15: Boot problems with a PA6T board

2014-05-28 Thread Christian Zigotzky
Hi Michael, Thank you for your answer and thank you for your help. :-) On 28.05.2014 06:23, Michael Ellerman wrote: On Wed, 2014-05-28 at 01:08 +0200, Christian Zigotzky wrote: Hi Michael, Thanks a lot for your answer. ... 18a1a7a1d862ae0794a0179473d08a414dd49234 <- It doesn't boot. Error m

Re: [PATCH 1/2] powerpc/mm: Check paca psize is up to date for huge mappings

2014-05-28 Thread Aneesh Kumar K.V
Michael Ellerman writes: > We have a bug in our hugepage handling which exhibits as an infinite > loop of hash faults. If the fault is being taken in the kernel it will > typically trigger the softlockup detector, or the RCU stall detector. > > The bug is as follows: > > 1. mmap(0xa000, ...,

Re: [PATCH 2/2] selftests/powerpc: Test the THP bug we fixed in the previous commit

2014-05-28 Thread Aneesh Kumar K.V
Michael Ellerman writes: > Signed-off-by: Michael Ellerman Reviewed-by: Aneesh Kumar K.V > --- > tools/testing/selftests/powerpc/Makefile | 2 +- > tools/testing/selftests/powerpc/mm/Makefile| 18 ++ > .../selftests/powerpc/mm/hugetlb_vs_thp_test.c | 72 >

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Alexander Graf
On 28.05.14 02:57, Alex Williamson wrote: On Wed, 2014-05-28 at 02:44 +0200, Alexander Graf wrote: On 28.05.14 02:39, Alex Williamson wrote: On Wed, 2014-05-28 at 00:49 +0200, Alexander Graf wrote: On 27.05.14 20:15, Alex Williamson wrote: On Tue, 2014-05-27 at 18:40 +1000, Gavin Shan wrote:

Kernel 3.15: Boot problems with a PA6T board

2014-05-28 Thread Christian Zigotzky
On 28.05.2014 10:53, Christian Zigotzky wrote: Hi Michael, Thank you for your answer and thank you for your help. :-) On 28.05.2014 06:23, Michael Ellerman wrote: On Wed, 2014-05-28 at 01:08 +0200, Christian Zigotzky wrote: Hi Michael, Thanks a lot for your answer. ... 18a1a7a1d862ae0794a0

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Alexander Graf
On 28.05.14 02:55, Gavin Shan wrote: On Tue, May 27, 2014 at 12:15:27PM -0600, Alex Williamson wrote: On Tue, 2014-05-27 at 18:40 +1000, Gavin Shan wrote: The patch adds new IOCTL commands for sPAPR VFIO container device to support EEH functionality for PCI devices, which have been passed thro

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Gavin Shan
On Wed, May 28, 2014 at 01:41:35PM +0200, Alexander Graf wrote: > >On 28.05.14 02:55, Gavin Shan wrote: >>On Tue, May 27, 2014 at 12:15:27PM -0600, Alex Williamson wrote: >>>On Tue, 2014-05-27 at 18:40 +1000, Gavin Shan wrote: The patch adds new IOCTL commands for sPAPR VFIO container device >>

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Alexander Graf
On 28.05.14 14:49, Gavin Shan wrote: On Wed, May 28, 2014 at 01:41:35PM +0200, Alexander Graf wrote: On 28.05.14 02:55, Gavin Shan wrote: On Tue, May 27, 2014 at 12:15:27PM -0600, Alex Williamson wrote: On Tue, 2014-05-27 at 18:40 +1000, Gavin Shan wrote: The patch adds new IOCTL commands fo

Re: [PATCH] powerpc, kexec: Fix "Processor X is stuck" issue during kexec from ST mode

2014-05-28 Thread Vivek Goyal
On Tue, May 27, 2014 at 04:25:34PM +0530, Srivatsa S. Bhat wrote: > If we try to perform a kexec when the machine is in ST (Single-Threaded) mode > (ppc64_cpu --smt=off), the kexec operation doesn't succeed properly, and we > get the following messages during boot: > > [0.089866] POWER8 perfor

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Alex Williamson
On Wed, 2014-05-28 at 13:37 +0200, Alexander Graf wrote: > On 28.05.14 02:57, Alex Williamson wrote: > > On Wed, 2014-05-28 at 02:44 +0200, Alexander Graf wrote: > >> On 28.05.14 02:39, Alex Williamson wrote: > >>> On Wed, 2014-05-28 at 00:49 +0200, Alexander Graf wrote: > On 27.05.14 20:15, A

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Alex Williamson
On Wed, 2014-05-28 at 10:55 +1000, Gavin Shan wrote: > On Tue, May 27, 2014 at 12:15:27PM -0600, Alex Williamson wrote: > >On Tue, 2014-05-27 at 18:40 +1000, Gavin Shan wrote: > >> The patch adds new IOCTL commands for sPAPR VFIO container device > >> to support EEH functionality for PCI devices, w

Re: [PATCH] tty/hvc/hvc_console: Fix wakeup of HVC thread on hvc_kick()

2014-05-28 Thread Greg Kroah-Hartman
On Wed, May 28, 2014 at 10:01:30AM +1000, Benjamin Herrenschmidt wrote: > On Fri, 2014-05-23 at 19:41 +1000, Benjamin Herrenschmidt wrote: > > Some backends call hvc_kick() to wakeup the HVC thread from its > > slumber upon incoming characters. This however doesn't work > > properly because it uses

Re: NUMA topology question wrt. d4edc5b6

2014-05-28 Thread Nishanth Aravamudan
On 23.05.2014 [02:18:05 +0530], Srivatsa S. Bhat wrote: > > [ Adding a few more CC's ] > > On 05/22/2014 01:34 AM, Nishanth Aravamudan wrote: > > Hi Srivatsa, > > > > After d4edc5b6 ("powerpc: Fix the setup of CPU-to-Node mappings during > > CPU online"), cpu_to_node() looks like: > > > > stati

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Benjamin Herrenschmidt
On Wed, 2014-05-28 at 22:49 +1000, Gavin Shan wrote: > > I will remove those "address" related macros in next revision because it's > user-level bussiness, not related to host kernel any more. > > If the user is QEMU + guest, we need the address to identify the PE though PHB > BUID could be used

Re: [PATCH 11/16] byteorder: provide a linux/byteorder.h with {be, le}_to_cpu() and cpu_to_{be, le}() macros

2014-05-28 Thread Cody P Schafer
On Wed, May 28, 2014 at 3:45 AM, David Laight wrote: > From: Cody P Schafer >> Rather manually specifying the size of the integer to be converted, key >> off of the type size. Reduces duplicate size info and the occurance of >> certain types of bugs (using the wrong sized conversion). > ... >> +#d

Re: [PATCH 11/16] byteorder: provide a linux/byteorder.h with {be,le}_to_cpu() and cpu_to_{be,le}() macros

2014-05-28 Thread Cody P Schafer
On Tue, May 27, 2014 at 7:44 PM, Joe Perches wrote: > On Tue, 2014-05-27 at 17:22 -0700, Cody P Schafer wrote: >> Rather manually specifying the size of the integer to be converted, key >> off of the type size. Reduces duplicate size info and the occurance of >> certain types of bugs (using the wr

Re: [PATCH 11/16] byteorder: provide a linux/byteorder.h with {be, le}_to_cpu() and cpu_to_{be, le}() macros

2014-05-28 Thread Cody P Schafer
On Wed, May 28, 2014 at 5:05 PM, Cody P Schafer wrote: > On Wed, May 28, 2014 at 3:45 AM, David Laight wrote: >> From: Cody P Schafer >>> Rather manually specifying the size of the integer to be converted, key >>> off of the type size. Reduces duplicate size info and the occurance of >>> certain

[PATCH] powerpc/perf: Never program book3s PMCs with values >= 0x80000000

2014-05-28 Thread Anton Blanchard
We are seeing a lot of PMU warnings on POWER8: Can't find PMC that caused IRQ Looking closer, the active PMC is 0 at this point and we took a PMU exception on the transition from negative to 0. Some versions of POWER8 have an issue where they edge detect and not level detect PMC overflows. A

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Alexander Graf
On 28.05.14 18:17, Alex Williamson wrote: On Wed, 2014-05-28 at 13:37 +0200, Alexander Graf wrote: On 28.05.14 02:57, Alex Williamson wrote: On Wed, 2014-05-28 at 02:44 +0200, Alexander Graf wrote: On 28.05.14 02:39, Alex Williamson wrote: On Wed, 2014-05-28 at 00:49 +0200, Alexander Graf wr

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Alexander Graf
On 28.05.14 23:58, Benjamin Herrenschmidt wrote: On Wed, 2014-05-28 at 22:49 +1000, Gavin Shan wrote: I will remove those "address" related macros in next revision because it's user-level bussiness, not related to host kernel any more. If the user is QEMU + guest, we need the address to identi

Re: [PATCH 11/16] byteorder: provide a linux/byteorder.h with {be, le}_to_cpu() and cpu_to_{be, le}() macros

2014-05-28 Thread Joe Perches
On Wed, 2014-05-28 at 17:11 -0500, Cody P Schafer wrote: > On Wed, May 28, 2014 at 5:05 PM, Cody P Schafer wrote: > > On Wed, May 28, 2014 at 3:45 AM, David Laight > > wrote: > >> From: Cody P Schafer > >>> Rather manually specifying the size of the integer to be converted, key > >>> off of the

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Gavin Shan
On Wed, May 28, 2014 at 03:12:35PM +0200, Alexander Graf wrote: > >On 28.05.14 14:49, Gavin Shan wrote: >>On Wed, May 28, 2014 at 01:41:35PM +0200, Alexander Graf wrote: >>>On 28.05.14 02:55, Gavin Shan wrote: On Tue, May 27, 2014 at 12:15:27PM -0600, Alex Williamson wrote: >On Tue, 2014-05

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Benjamin Herrenschmidt
On Thu, 2014-05-29 at 00:46 +0200, Alexander Graf wrote: > I don't think so :). In QEMU the PHB emulation would have to notify the > "container" (IOMMU emulation layer -> PE) that a PE operation happened. > It's that emulation code's responsibility to broadcast operations across > its own emulat

Re: [PATCH 11/16] byteorder: provide a linux/byteorder.h with {be, le}_to_cpu() and cpu_to_{be, le}() macros

2014-05-28 Thread Cody P Schafer
On Wed, May 28, 2014 at 6:00 PM, Joe Perches wrote: > On Wed, 2014-05-28 at 17:11 -0500, Cody P Schafer wrote: >> On Wed, May 28, 2014 at 5:05 PM, Cody P Schafer wrote: >> > On Wed, May 28, 2014 at 3:45 AM, David Laight >> > wrote: >> >> From: Cody P Schafer >> >>> Rather manually specifying th

Re: [RFC PATCH v2 1/2] powerpc: numa: enable USE_PERCPU_NUMA_NODE_ID

2014-05-28 Thread Andrew Morton
On Tue, 27 May 2014 17:09:58 -0700 Nishanth Aravamudan wrote: > On 28.05.2014 [09:56:14 +1000], Benjamin Herrenschmidt wrote: > > On Tue, 2014-05-27 at 16:44 -0700, Nishanth Aravamudan wrote: > > > > Signed-off-by: Nishanth Aravamudan > > > > > > Ping on this and patch 2/2. Ben, would you be w

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Gavin Shan
On Thu, May 29, 2014 at 12:40:26AM +0200, Alexander Graf wrote: >On 28.05.14 18:17, Alex Williamson wrote: >>On Wed, 2014-05-28 at 13:37 +0200, Alexander Graf wrote: >>>On 28.05.14 02:57, Alex Williamson wrote: On Wed, 2014-05-28 at 02:44 +0200, Alexander Graf wrote: >On 28.05.14 02:39, Ale

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Alexander Graf
On 29.05.14 01:37, Gavin Shan wrote: On Thu, May 29, 2014 at 12:40:26AM +0200, Alexander Graf wrote: On 28.05.14 18:17, Alex Williamson wrote: On Wed, 2014-05-28 at 13:37 +0200, Alexander Graf wrote: On 28.05.14 02:57, Alex Williamson wrote: On Wed, 2014-05-28 at 02:44 +0200, Alexander Graf

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Gavin Shan
On Thu, May 29, 2014 at 01:38:46AM +0200, Alexander Graf wrote: >On 29.05.14 01:37, Gavin Shan wrote: >>On Thu, May 29, 2014 at 12:40:26AM +0200, Alexander Graf wrote: >>>On 28.05.14 18:17, Alex Williamson wrote: On Wed, 2014-05-28 at 13:37 +0200, Alexander Graf wrote: >On 28.05.14 02:57, A

Re: [RFC PATCH v2 1/2] powerpc: numa: enable USE_PERCPU_NUMA_NODE_ID

2014-05-28 Thread Nishanth Aravamudan
On 28.05.2014 [16:36:07 -0700], Andrew Morton wrote: > On Tue, 27 May 2014 17:09:58 -0700 Nishanth Aravamudan > wrote: > > > On 28.05.2014 [09:56:14 +1000], Benjamin Herrenschmidt wrote: > > > On Tue, 2014-05-27 at 16:44 -0700, Nishanth Aravamudan wrote: > > > > > Signed-off-by: Nishanth Aravamu

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Gavin Shan
On Wed, May 28, 2014 at 10:32:11AM -0600, Alex Williamson wrote: >On Wed, 2014-05-28 at 10:55 +1000, Gavin Shan wrote: >> On Tue, May 27, 2014 at 12:15:27PM -0600, Alex Williamson wrote: >> >On Tue, 2014-05-27 at 18:40 +1000, Gavin Shan wrote: >> >> The patch adds new IOCTL commands for sPAPR VFIO

Re: [PATCH v7 3/3] drivers/vfio: EEH support for VFIO PCI device

2014-05-28 Thread Benjamin Herrenschmidt
On Thu, 2014-05-29 at 10:05 +1000, Gavin Shan wrote: > The log stuff is TBD and I'll figure it out later. > > About to what are the errors, there are a lot. Most of them are related > to hardware level, for example unstable PCI link. Usually, those error > bits defined in AER fatal error state reg

linux-next: manual merge of the powerpc tree with Linus' tree

2014-05-28 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the powerpc tree got a conflict in arch/powerpc/include/asm/sections.h between commit b18db0b80867 ("KVM guest: Make pv trampoline code executable") from the tree and commit 07de8377f748 ("powerpc: Fix ABIv2 issue with dereference_function_descriptor") from the

Re: Kernel 3.15: Boot problems with a PA6T board

2014-05-28 Thread Michael Ellerman
On Wed, 2014-05-28 at 13:25 +0200, Christian Zigotzky wrote: > On 28.05.2014 10:53, Christian Zigotzky wrote: > > Hi Michael, > > > > Thank you for your answer and thank you for your help. :-) > > > > On 28.05.2014 06:23, Michael Ellerman wrote: > >> On Wed, 2014-05-28 at 01:08 +0200, Christian Zig