Re: [v3, 00/10] Support DPAA PTP clock and timestamping

2018-06-07 Thread Richard Cochran
On Thu, Jun 07, 2018 at 05:20:40PM +0800, Yangbo Lu wrote: > This patchset is to support DPAA FMAN PTP clock and HW timestamping. > It had been verified on both ARM platform and PPC platform. > - The patch #1 to patch #5 are to support DPAA FMAN 1588 timer in > ptp_qoriq driver. > - The patch #6

Re: [RFC PATCH kernel 5/5] vfio_pci: Add NVIDIA GV100GL [Tesla V100 SXM2] [10de:1db1] subdriver

2018-06-07 Thread Alex Williamson
On Fri, 8 Jun 2018 13:52:05 +1000 Alexey Kardashevskiy wrote: > On 8/6/18 1:35 pm, Alex Williamson wrote: > > On Fri, 8 Jun 2018 13:09:13 +1000 > > Alexey Kardashevskiy wrote: > >> On 8/6/18 3:04 am, Alex Williamson wrote: > >>> On Thu, 7 Jun 2018 18:44:20 +1000 > >>> Alexey Kardashevskiy

RE: [v3, 00/10] Support DPAA PTP clock and timestamping

2018-06-07 Thread Y.b. Lu
> -Original Message- > From: Richard Cochran [mailto:richardcoch...@gmail.com] > Sent: Friday, June 8, 2018 12:27 PM > To: Y.b. Lu > Cc: net...@vger.kernel.org; Madalin-cristian Bucur > ; Rob Herring ; Shawn Guo > ; David S . Miller ; > devicet...@vger.kernel.org; linuxppc-dev@lists.ozlabs

Re: [RFC PATCH kernel 0/5] powerpc/P9/vfio: Pass through NVIDIA Tesla V100

2018-06-07 Thread Alex Williamson
On Fri, 8 Jun 2018 14:14:23 +1000 Alexey Kardashevskiy wrote: > On 8/6/18 1:44 pm, Alex Williamson wrote: > > On Fri, 8 Jun 2018 13:08:54 +1000 > > Alexey Kardashevskiy wrote: > > > >> On 8/6/18 8:15 am, Alex Williamson wrote: > >>> On Fri, 08 Jun 2018 07:54:02 +1000 > >>> Benjamin Herrensc

[PATCH kernel 1/6] powerpc/powernv: Remove useless wrapper

2018-06-07 Thread Alexey Kardashevskiy
This gets rid of a useless wrapper around pnv_pci_ioda2_table_free_pages(). Signed-off-by: Alexey Kardashevskiy --- arch/powerpc/platforms/powernv/pci-ioda.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/arch/powerpc/platforms/powernv/pci-ioda.c b/arch/powerpc/platfo

[PATCH kernel 2/6] powerpc/powernv: Move TCE manupulation code to its own file

2018-06-07 Thread Alexey Kardashevskiy
Right now we have allocation code in pci-ioda.c and traversing code in pci.c, let's keep them toghether. However both files are big enough already so let's move this business to a new file. While we at it, move the code which links IOMMU table groups to IOMMU tables as it is not specific to any PN

[PATCH kernel 3/6] KVM: PPC: Make iommu_table::it_userspace big endian

2018-06-07 Thread Alexey Kardashevskiy
We are going to reuse multilevel TCE code for the userspace copy of the TCE table and since it is big endian, let's make the copy big endian too. Signed-off-by: Alexey Kardashevskiy --- arch/powerpc/include/asm/iommu.h| 2 +- arch/powerpc/kvm/book3s_64_vio.c| 11 ++- arch/powerp

[PATCH kernel 4/6] powerpc/powernv: Add indirect levels to it_userspace

2018-06-07 Thread Alexey Kardashevskiy
We want to support sparse memory and therefore huge chunks of DMA windows do not need to be mapped. If a DMA window big enough to require 2 or more indirect levels, and a DMA window is used to map all RAM (which is a default case for 64bit window), we can actually save some memory by not allocation

[PATCH kernel 5/6] powerpc/powernv: Rework TCE level allocation

2018-06-07 Thread Alexey Kardashevskiy
This moves actual pages allocation to a separate function which is going to be reused later in on-demand TCE allocation. While we are at it, remove unnecessary level size round up as the caller does this already. Signed-off-by: Alexey Kardashevskiy --- arch/powerpc/platforms/powernv/pci-ioda-tc

[PATCH kernel 0/6] powerpc/powernv/iommu: Optimize memory use

2018-06-07 Thread Alexey Kardashevskiy
This patchset aims to reduce actual memory use for guests with sparse memory. The pseries guest uses dynamic DMA windows to map the entire guest RAM but it only actually maps onlined memory which may be not be contiguous. I hit this when tried passing through NVLink2-connected GPU RAM of NVIDIA V10

[PATCH kernel 6/6] powerpc/powernv/ioda: Allocate indirect TCE levels on demand

2018-06-07 Thread Alexey Kardashevskiy
At the moment we allocate the entire TCE table, twice (hardware part and userspace translation cache). This normally works as we normally have contigous memory and the guest will map entire RAM for 64bit DMA. However if we have sparse RAM (one example is a memory device), then we will allocate TCE

Re: pkeys on POWER: Access rights not reset on execve

2018-06-07 Thread Florian Weimer
On 06/08/2018 04:34 AM, Ram Pai wrote: So the remaining question at this point is whether the Intel behavior (default-deny instead of default-allow) is preferable. Florian, remind me what behavior needs to fixed? See the other thread. The Intel register equivalent to the AMR by default dis

Re: [v3 PATCH 1/5] powerpc/pseries: convert rtas_log_buf to linear allocation.

2018-06-07 Thread Mahesh Jagannath Salgaonkar
On 06/08/2018 07:01 AM, Nicholas Piggin wrote: > On Thu, 07 Jun 2018 22:58:11 +0530 > Mahesh J Salgaonkar wrote: > >> From: Mahesh Salgaonkar >> >> rtas_log_buf is a buffer to hold RTAS event data that are communicated >> to kernel by hypervisor. This buffer is then used to pass RTAS event >> da

Re: [v3 PATCH 4/5] powerpc/pseries: Dump and flush SLB contents on SLB MCE errors.

2018-06-07 Thread Mahesh Jagannath Salgaonkar
On 06/08/2018 07:18 AM, Nicholas Piggin wrote: > On Thu, 07 Jun 2018 22:58:55 +0530 > Mahesh J Salgaonkar wrote: > >> From: Mahesh Salgaonkar >> >> If we get a machine check exceptions due to SLB errors then dump the >> current SLB contents which will be very much helpful in debugging the >> roo

Re: [v3 PATCH 5/5] powerpc/pseries: Display machine check error details.

2018-06-07 Thread Mahesh Jagannath Salgaonkar
On 06/08/2018 07:21 AM, Nicholas Piggin wrote: > On Thu, 07 Jun 2018 22:59:04 +0530 > Mahesh J Salgaonkar wrote: > >> From: Mahesh Salgaonkar >> >> Extract the MCE error details from RTAS extended log and display it to >> console. >> >> With this patch you should now see mce logs like below: >>

Re: [v3 PATCH 2/5] powerpc/pseries: Fix endainness while restoring of r3 in MCE handler.

2018-06-07 Thread Michael Ellerman
Mahesh J Salgaonkar writes: > From: Mahesh Salgaonkar > > During Machine Check interrupt on pseries platform, register r3 points > RTAS extended event log passed by hypervisor. Since hypervisor uses r3 > to pass pointer to rtas log, it stores the original r3 value at the > start of the memory (fi

Re: [PATCH v3] powerpc: Add support for function error injection

2018-06-07 Thread Samuel Mendoza-Jonas
On Thu, 2018-06-07 at 15:22 +0530, Naveen N. Rao wrote: > We implement regs_set_return_value() and override_function_with_return() > for this purpose. > > On powerpc, a return from a function (blr) just branches to the location > contained in the link register. So, we can just update pt_regs rathe

Re: [RFC V2] virtio: Add platform specific DMA API translation for virito devices

2018-06-07 Thread Christoph Hellwig
On Thu, Jun 07, 2018 at 07:28:35PM +0300, Michael S. Tsirkin wrote: > Let me restate it: DMA API has support for a wide range of hardware, and > hardware based virtio implementations likely won't benefit from all of > it. That is completely wrong. All aspects of the DMA API are about the system t

<    1   2