RE: [PATCH V2] QorIQ/TMU: add TMU node to device tree for QorIQ T104x

2015-05-25 Thread Hongtao Jia
Hi Scott, Eduardo indicated that "calibration" property should add "fsl" prefix. I updated the patch. Any other comments? If not I will send V3 soon. Thanks. --- Best Regards, Hongtao > -Original Message- > From: Jia Hongtao [mailto:hongtao@freescale.com] > Sent: Wednesday, April 1

[PATCH 2/2] powerpc: Non relocatable system call doesn't need a trampoline

2015-05-25 Thread Anton Blanchard
We need to use a trampoline when using LOAD_HANDLER(), because the destination needs to be in the first 64kB. An absolute branch has no such limitations, so just jump there. Signed-off-by: Anton Blanchard --- arch/powerpc/kernel/exceptions-64s.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion

[PATCH 1/2] powerpc: Relocatable system call no longer uses the LR

2015-05-25 Thread Anton Blanchard
We had some code to restore the LR in the relocatable system call path back when we used the LR to do an indirect branch. Commit 6a404806dfce ("powerpc: Avoid link stack corruption in MMU on syscall entry path") changed this to use the CTR which is volatile across system calls so does not need res

[PATCH] powerpc/perf: Fix book3s kernel to userspace backtraces

2015-05-25 Thread Anton Blanchard
When we take a PMU exception or a software event we call perf_read_regs(). This overloads regs->result with a boolean that describes if we should use the sampled instruction address register (SIAR) or the regs. If the exception is in kernel, we start with the kernel regs and backtrace through the

Re: [PATCH V2 2/2] powerpc/configs: Replace pseries_le_defconfig with a Makefile target using merge_config

2015-05-25 Thread Samuel Mendoza-Jonas
Reviewed-by: Samuel Mendoza-Jonas On 26/05/15 11:36, Cyril Bur wrote: > Rather than continuing to maintain a copy of pseries_defconfig with enabled > CONFIG_CPU_LITTLE_ENDIAN, use the generic merge_config script and use an > le.config to enable little endian on top of pseries_defconfig without th

[PATCH V2 1/2] powerpc/configs: Merge pseries_defconfig and pseries_le_defconfig

2015-05-25 Thread Cyril Bur
These two configs should be identical with the exception of big or little endian. The big endian version has XMON_DEFAULT turned on while the little endian has XMON_DEFAULT not set. It makes the most sense for defconfigs not to use xmon by default, production systems should get back up as quickly

[PATCH V2 2/2] powerpc/configs: Replace pseries_le_defconfig with a Makefile target using merge_config

2015-05-25 Thread Cyril Bur
Rather than continuing to maintain a copy of pseries_defconfig with enabled CONFIG_CPU_LITTLE_ENDIAN, use the generic merge_config script and use an le.config to enable little endian on top of pseries_defconfig without the need for a duplicated _defconfig file. This method will require less mainte

Re: [PATCH 12/19] cxl: Export some symbols

2015-05-25 Thread Michael Neuling
On Thu, 2015-05-21 at 19:16 +1000, Ian Munsie wrote: > > +void assign_psn_space(struct cxl_context *ctx); > > Should we consider renaming this to cxl_assign_psn_space to namespace it > now that it's potentially callable from elsewhere in the kernel? > > > +int afu_check_and_enable(struct cxl_afu

[PATCH v2 1/1] KVM: PPC: Book3S: correct width in XER handling

2015-05-25 Thread Sam Bobroff
In 64 bit kernels, the Fixed Point Exception Register (XER) is a 64 bit field (e.g. in kvm_regs and kvm_vcpu_arch) and in most places it is accessed as such. This patch corrects places where it is accessed as a 32 bit field by a 64 bit kernel. In some cases this is via a 32 bit load or store inst

[PATCH v2 21/21] cxl: Add AFU virtual PHB and kernel API

2015-05-25 Thread Michael Neuling
This patch does two things. Firstly it presents the Accelerator Function Unit (AFUs) behind the POWER Service Layer (PSL) as PCI devices on a virtual PCI Host Bridge (vPHB). This in in addition to the PSL being a PCI device itself. As part of the Coherent Accelerator Interface Architecture (CAIA

[PATCH v2 20/21] cxl: Export file ops for use by API

2015-05-25 Thread Michael Neuling
The cxl kernel API will allow drivers other than cxl to export a file descriptor which has the same userspace API. These file descriptors will be able to be used against libcxl. This exports those file ops for use by other drivers. Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- drive

Re: [PATCH 1/1] KVM: PPC: Book3S: correct width in XER handling

2015-05-25 Thread Alexander Graf
On 26.05.15 02:14, Sam Bobroff wrote: > On Mon, May 25, 2015 at 11:08:08PM +0200, Alexander Graf wrote: >> >> >> On 20.05.15 07:26, Sam Bobroff wrote: >>> In 64 bit kernels, the Fixed Point Exception Register (XER) is a 64 >>> bit field (e.g. in kvm_regs and kvm_vcpu_arch) and in most places it i

[PATCH v2 19/21] cxl: Move include file cxl.h -> cxl-base.h

2015-05-25 Thread Michael Neuling
This moves the current include file from cxl.h -> cxl-base.h. This current include file is used only to pass information between the base driver that needs to be built into the kernel and the cxl module. This is to make way for a new include/misc/cxl.h which will contain just the kernel API for o

[PATCH v2 18/21] cxl: Cleanup Makefile

2015-05-25 Thread Michael Neuling
Cleanup Makefile by fixing line wrapping. Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- drivers/misc/cxl/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/misc/cxl/Makefile b/drivers/misc/cxl/Makefile index edb494d..f9f5514 100644 --- a/drivers/mis

[PATCH v2 17/21] cxl: Rework context lifetimes

2015-05-25 Thread Michael Neuling
This reworks contexts lifetimes a bit to enable the kernel API where we may want to reuse contexts. Here we will want to start and stop contexts without freeing them. Start context does the get pid & ctx so stop context will need to do the puts. Here we move put pid & ctx to the detach context pat

[PATCH v2 16/21] cxl: Configure PSL for kernel contexts and merge code

2015-05-25 Thread Michael Neuling
This updates AFU directed and dedicated modes for contexts attached to the kernel. The SR (similar to the MSR in the core) calculation is getting quite complex and is duplicated in AFU directed and dedicated modes. This patch also merges this SR calculation for these modes. Signed-off-by: Michae

[PATCH v2 15/21] cxl: Split afu_register_irqs() function

2015-05-25 Thread Michael Neuling
Split the afu_register_irqs() function so that different parts can be useful elsewhere. Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- drivers/misc/cxl/cxl.h | 1 + drivers/misc/cxl/irq.c | 31 --- 2 files changed, 25 insertions(+), 7 deletions(-) diff --g

[PATCH v2 14/21] cxl: Only check pid for userspace contexts

2015-05-25 Thread Michael Neuling
We only need to check the pid attached to this context for userspace contexts. Kernel contexts can skip this check. Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- drivers/misc/cxl/fault.c | 34 +++--- 1 file changed, 19 insertions(+), 15 deletions(-) diff -

[PATCH v2 13/21] cxl: Export some symbols

2015-05-25 Thread Michael Neuling
Export some symbols which will soon be used elsewhere in this driver. Now they are global we rename them so to avoid collisions. Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- drivers/misc/cxl/cxl.h| 5 + drivers/misc/cxl/native.c | 10 +- 2 files changed, 10 insertio

[PATCH v2 12/21] cxl: cxl_afu_reset() -> __cxl_afu_reset()

2015-05-25 Thread Michael Neuling
Rename cxl_afu_reset() to __cxl_afu_reset() to we can reuse this function name in the API. Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- drivers/misc/cxl/cxl.h| 2 +- drivers/misc/cxl/native.c | 8 drivers/misc/cxl/pci.c| 4 ++-- drivers/misc/cxl/sysfs.c | 2 +- 4 fi

[PATCH v2 11/21] cxl: Rework detach context functions

2015-05-25 Thread Michael Neuling
Rework __detach_context() and cxl_context_detach() so we can reuse them in the kernel API. Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- drivers/misc/cxl/context.c | 20 +--- drivers/misc/cxl/cxl.h | 1 + 2 files changed, 14 insertions(+), 7 deletions(-) diff --g

[PATCH v2 10/21] cxl: Add cookie parameter to afu_release_irqs()

2015-05-25 Thread Michael Neuling
Add cookie parameter to afu_release_irqs() so that we can pass in a different cookie than the context structure. This will be useful for other kernel drivers that want to call this but get their own cookie back in the interrupt handler. Update all existing call sites. Signed-off-by: Michael Neul

[PATCH v2 09/21] cxl: Dump debug info on the AFU configuration record

2015-05-25 Thread Michael Neuling
Now that we parse the AFU Configuration record, dump some info on it when in debug mode. Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- drivers/misc/cxl/pci.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/drivers/misc/cxl/pci.c b/drivers/misc/cxl/pci.

[PATCH v2 08/21] cxl: Re-order card init to check the VSEC earlier

2015-05-25 Thread Michael Neuling
From: Ian Munsie When we expose AFUs as virtual PCI devices, they may look like the physical CAPI PCI card. ie they may have the same vendor/device IDs. We want to avoid these AFUs binding to this driver and any init this driver may do. Re-order card init to check the VSEC earlier before assig

[PATCH v2 07/21] cxl: Add shutdown hook

2015-05-25 Thread Michael Neuling
Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- drivers/misc/cxl/pci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/misc/cxl/pci.c b/drivers/misc/cxl/pci.c index b80f867..a9c90d2 100644 --- a/drivers/misc/cxl/pci.c +++ b/drivers/misc/cxl/pci.c @@ -1135,4 +1135,5 @@ struct

[PATCH v2 06/21] cxl: Document external user of existing API

2015-05-25 Thread Michael Neuling
Now that libcxl is public, let's document it. Signed-off-by: Michael Neuling Acked-by: Ian Munsie --- Documentation/ABI/testing/sysfs-class-cxl | 22 ++ Documentation/powerpc/cxl.txt | 4 2 files changed, 26 insertions(+) diff --git a/Documentation/ABI/tes

[PATCH v2 05/21] powerpc/pci: Add shutdown hook to pci_controller_ops

2015-05-25 Thread Michael Neuling
Currently pnv_pci_shutdown() calls the PHB shutdown code for all PHBs in the system. It dereferences the private_data assuming it's a powernv PHB, which won't be the case when we have different PHB in the systems (like when we add vPHBs for CXL). This moves the shutdown hook to the pci_controller

[PATCH v2 04/21] powerpc: Add cxl context to device archdata

2015-05-25 Thread Michael Neuling
Add cxl context pointer to archdata. We'll want to create one of these for cxl PCI devices. Put them here until we can get a pci_dev specific private data. This location was suggested by benh. Signed-off-by: Michael Neuling --- arch/powerpc/include/asm/device.h | 3 +++ 1 file changed, 3 inse

[PATCH v2 03/21] powerpc/pci: Add release_device() hook to phb ops

2015-05-25 Thread Michael Neuling
Add release_device() hook to phb ops so we can clean up for specific phbs. Signed-off-by: Michael Neuling --- arch/powerpc/include/asm/pci-bridge.h | 2 ++ arch/powerpc/kernel/pci-hotplug.c | 5 + 2 files changed, 7 insertions(+) diff --git a/arch/powerpc/include/asm/pci-bridge.h b/arc

[PATCH v2 02/21] powerpc/pci: Export symbols for CXL

2015-05-25 Thread Michael Neuling
From: Daniel Axtens Export pcibios_claim_one_bus, pcibios_scan_phb and pcibios_alloc_controller. These will be used by the CXL driver. Signed-off-by: Daniel Axtens --- arch/powerpc/kernel/pci-common.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/powerpc/kernel/pci-common.c b/ar

[PATCH v2 01/21] powerpc/copro: Fix faulting kernel segments

2015-05-25 Thread Michael Neuling
This fixes calculating the key bits (KP and KS) in the SLB VSID for kernel mappings. I'm not CCing this to stable as there are no uses of this currently. Signed-off-by: Michael Neuling --- arch/powerpc/mm/copro_fault.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/a

[PATCH v2 00/21] cxl: Add AFU virtual PHB and in kernel API

2015-05-25 Thread Michael Neuling
This patch series adds the ability to present AFUs as PCI devices on a virtual PHB. It also adds an in kernel API (to the existing userspace API) so AFU drivers can be written as kernel drivers. This series is dependant on Daniel DMA set mask and MSI PCI controller ops patch series. v2: - Addre

Re: [PATCH 1/1] KVM: PPC: Book3S: correct width in XER handling

2015-05-25 Thread Sam Bobroff
On Mon, May 25, 2015 at 11:08:08PM +0200, Alexander Graf wrote: > > > On 20.05.15 07:26, Sam Bobroff wrote: > > In 64 bit kernels, the Fixed Point Exception Register (XER) is a 64 > > bit field (e.g. in kvm_regs and kvm_vcpu_arch) and in most places it is > > accessed as such. > > > > This patch

[PATCH 6/6] llvm: A few Makefile hacks

2015-05-25 Thread Anton Blanchard
llvm accepts -fno-delete-null-pointer-checks but complains about it. Wrap it to avoid getting enormous numbers of warnings. Also add -no-integrated-as to disable the llvm integrated assembler, lots of stuff currently relies on gas. --- Makefile | 5 + 1 file changed, 5 insertions(+) diff --g

[PATCH 5/6] powerpc: Don't use gcc specific options on clang

2015-05-25 Thread Anton Blanchard
Add a conditional around the code to select various gcc only options: -mabi=elfv2 vs -mcall-aixdesc, and -mcmodel=medium vs -mminimal-toc. Signed-off-by: Anton Blanchard --- arch/powerpc/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile

[PATCH 4/6] powerpc: Don't use -mno-strict-align on clang

2015-05-25 Thread Anton Blanchard
We added -mno-strict-align in commit f036b3681962 (powerpc: Work around little endian gcc bug) to fix gcc bug http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57134 Clang doesn't understand it. We need to use a conditional because we can't use the simpler call cc-option here. Signed-off-by: Anton Bla

[PATCH 3/6] powerpc: Only use -mtraceback=no, -mno-string and -msoft-float if toolchain supports it

2015-05-25 Thread Anton Blanchard
These options are not recognised on LLVM, so use call cc-option to check for support. Signed-off-by: Anton Blanchard --- arch/powerpc/Makefile | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile index 7a0daad..7c08b4e 100644 --

[PATCH 2/6] powerpc: Only use -mabi=altivec if toolchain supports it

2015-05-25 Thread Anton Blanchard
The -mabi=altivec option is not recognised on LLVM, so use call cc-option to check for support. Signed-off-by: Anton Blanchard --- arch/powerpc/lib/Makefile | 2 +- lib/raid6/Makefile| 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/lib/Makefile b/arch/p

[PATCH 1/6] powerpc: Fix duplicate const clang warning in user access code

2015-05-25 Thread Anton Blanchard
Signed-off-by: Anton Blanchard --- arch/powerpc/include/asm/uaccess.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/powerpc/include/asm/uaccess.h b/arch/powerpc/include/asm/uaccess.h index a0c071d..2a8ebae 100644 --- a/arch/powerpc/include/asm/uaccess.h +++ b/a

[PATCH 0/6] Build ppc64le kernel with llvm/clang

2015-05-25 Thread Anton Blanchard
Now that Michael has fixed the 32 bit VDSO issue in his next branch, there are only a few remaining things left to get the ppc64le kernel building with clang. The last patch is a hack to workaround some generic Makefile issues. Hopefully the relevant bits of the LLVMLinux tree will get merged up

Re: [PATCH 1/1] KVM: PPC: Book3S: correct width in XER handling

2015-05-25 Thread Alexander Graf
On 20.05.15 07:26, Sam Bobroff wrote: > In 64 bit kernels, the Fixed Point Exception Register (XER) is a 64 > bit field (e.g. in kvm_regs and kvm_vcpu_arch) and in most places it is > accessed as such. > > This patch corrects places where it is accessed as a 32 bit field by a > 64 bit kernel. I

[PATCH] powerpc/fsl: Add FMan Port 10G compatibles

2015-05-25 Thread Igal . Liberman
From: Igal Liberman This patch adds two boolean properties to FMan Port. FMan has 3 types of ports: - 1G ports By default, all ports support 1G rate - 10G Ports Port which use 10G hardware, and configured as 10G - 10G Best effort ports

Re: [alsa-devel] [PATCH] ASoC: fsl_spdif: Don't try to round-up for clock divisor calculation

2015-05-25 Thread Nicolin Chen
On Mon, May 25, 2015 at 12:13:45PM -0300, Fabio Estevam wrote: > Hi Nicolin, > > On Mon, May 25, 2015 at 12:11 PM, Nicolin Chen wrote: > > > Hi Mark, > > > > Is that possible for you to provisionally revert this patch? > > I wanted to wait for the test result from Fabio or Zidan in > > the Cc li

Re: [alsa-devel] [PATCH] ASoC: fsl_spdif: Don't try to round-up for clock divisor calculation

2015-05-25 Thread Fabio Estevam
Hi Nicolin, On Mon, May 25, 2015 at 12:11 PM, Nicolin Chen wrote: > Hi Mark, > > Is that possible for you to provisionally revert this patch? > I wanted to wait for the test result from Fabio or Zidan in > the Cc list because I don't have a test environment for SPDIF > even though this change se

Re: [PATCH] ASoC: fsl_spdif: Don't try to round-up for clock divisor calculation

2015-05-25 Thread Nicolin Chen
On Mon, May 25, 2015 at 12:58:12PM +0100, Mark Brown wrote: > On Sun, May 24, 2015 at 01:12:41AM -0700, Nicolin Chen wrote: > > As commit 6c8ca30eec7b ("ASoC: fsl_ssi: Don't try to round-up for PM > > divisor calculation") mentioned that there's no more need to use a > > round up work around to get

Re: [PATCH] ASoC: fsl_spdif: Don't try to round-up for clock divisor calculation

2015-05-25 Thread Mark Brown
On Sun, May 24, 2015 at 01:12:41AM -0700, Nicolin Chen wrote: > As commit 6c8ca30eec7b ("ASoC: fsl_ssi: Don't try to round-up for PM > divisor calculation") mentioned that there's no more need to use a > round up work around to get a better divisor since the clk-divider > driver has been refined a

Re: [PATCH V8 00/28] Add new powerpc specific ELF core notes

2015-05-25 Thread Anshuman Khandual
On 05/19/2015 08:37 PM, Anshuman Khandual wrote: > From: Anshuman Khandual > > This patch series adds twelve new ELF core note sections which can > be used with existing ptrace request PTRACE_GETREGSET-SETREGSET for accessing > various transactional memory and other miscellaneous debug regi

Re: [PATCH V5 00/13] POWER DSCR fixes, improvements, docs and tests

2015-05-25 Thread Anshuman Khandual
On 05/21/2015 12:13 PM, Anshuman Khandual wrote: > This patch series has patches for POWER DSCR fixes, improvements, > in code documentaion, kernel support user documentation and selftest based > test cases. It has got five test cases which are derived from Anton's DSCR > test bucket which ca