[PATCH] powerpc/powernv: Include VF PE in PELTV of PF PE

2015-06-21 Thread Gavin Shan
The PELTV of PF PE should include VF PE, which is missed by current code, so that the VF PE is frozen automatically when freezing PF PE. The patch fixes the PELTV of PF PE to include VF PE. Signed-off-by: Gavin Shan gws...@linux.vnet.ibm.com --- arch/powerpc/platforms/powernv/pci-ioda.c | 2 +-

powerpc,numa: Memory hotplug to memory-less nodes ?

2015-06-21 Thread Bharata B Rao
Hi, While developing memory hotplug support in QEMU for PoweKVM, I realized that guest kernel has specific checks to prevent hot addition of memory to a memory-less node. I am referring to arch/powerpc/mm/numa.c:hot_add_scn_to_nid() which has explicit checks to ensure that it returns a nid that

[PATCH 1/3] powerpc/iommu: Remove dma_data union

2015-06-21 Thread Benjamin Herrenschmidt
To support hybrid DMA ops in a subsequent patch, we will need both a direct DMA offset and an iommu pointer. Those are currently exclusive (a union), so change them to be separate fields. While there, also type iommu_table_base properly and make exist only on CONFIG_PPC64 since it's not

[PATCH 2/3] powerpc/iommu: Cleanup setting of DMA base/offset

2015-06-21 Thread Benjamin Herrenschmidt
Now that the table and the offset can co-exist, we no longer need to flip/flop, we can just establish both once at boot time. Signed-off-by: Benjamin Herrenschmidt b...@kernel.crashing.org --- arch/powerpc/platforms/powernv/pci-ioda.c | 50 +++

[PATCH 3/3] powerpc/iommu: Support hybrid iommu/direct DMA ops for coherent_mask dma_mask

2015-06-21 Thread Benjamin Herrenschmidt
This patch adds the ability to the DMA direct ops to fallback to the IOMMU ops for coherent alloc/free if the coherent mask of the device isn't suitable for accessing the direct DMA space and the device also happens to have an active IOMMU table. Signed-off-by: Benjamin Herrenschmidt

[PATCH] powerpc/powernv: Fix vma page prot flags in opal-prd driver

2015-06-21 Thread Vaidyanathan Srinivasan
opal-prd driver will mmap() firmware code/data area as private mapping to prd user space daemon. Write to this page will trigger COW faults. The new COW pages are normal kernel RAM pages accounted by the kernel and are not special. vma-vm_page_prot value will be used at page fault time for the