[PATCH 4/5] powerpc: Move sparse_init() into initmem_init

2014-09-16 Thread Anton Blanchard
We did part of sparse initialisation in setup_arch and part in initmem_init. Put them together. Signed-off-by: Anton Blanchard --- arch/powerpc/kernel/setup_64.c | 1 - arch/powerpc/mm/mem.c | 1 + arch/powerpc/mm/numa.c | 2 ++ 3 files changed, 3 insertions(+), 1 deletion(-) d

[PATCH 5/5] powerpc: make __ffs return unsigned long

2014-09-16 Thread Anton Blanchard
I'm seeing a build warning in mm/nobootmem.c after removing bootmem: mm/nobootmem.c: In function '__free_pages_memory': include/linux/kernel.h:713:17: warning: comparison of distinct pointer types lacks a cast [enabled by default] (void) (&_min1 == &_min2); \ ^ mm/nobootmem.c:

[PATCH 3/5] powerpc: Remove superfluous bootmem includes

2014-09-16 Thread Anton Blanchard
Lots of places included bootmem.h even when not using bootmem. Signed-off-by: Anton Blanchard --- arch/powerpc/kernel/crash_dump.c | 1 - arch/powerpc/kernel/irq.c | 1 - arch/powerpc/kernel/pci_64.c | 1 - arch/powerpc/kernel/rtas_pci.c

[PATCH 2/5] powerpc: Remove some old bootmem related comments

2014-09-16 Thread Anton Blanchard
Now bootmem is gone from powerpc we can remove comments mentioning it. Signed-off-by: Anton Blanchard --- arch/powerpc/kernel/prom.c | 5 + arch/powerpc/kernel/rtas.c | 4 ++-- arch/powerpc/kvm/book3s_hv_builtin.c | 2 +- arch/powerpc/mm/hugetlbpage.c| 4 ++-- arc

[PATCH 1/5] powerpc: Remove bootmem allocator

2014-09-16 Thread Anton Blanchard
At the moment we transition from the memblock alloctor to the bootmem allocator. Gitting rid of the bootmem allocator removes a bunch of complicated code (most of which I owe the dubious honour of being responsible for writing). Signed-off-by: Anton Blanchard --- arch/powerpc/Kconfig

[PATCH 6/6] powerpc: Add printk levels to powerpc code

2014-09-16 Thread Anton Blanchard
Add printk levels to some places in the powerpc port. Signed-off-by: Anton Blanchard --- arch/powerpc/include/asm/pgtable-ppc32.h| 4 ++-- arch/powerpc/include/asm/pgtable-ppc64-4k.h | 2 +- arch/powerpc/include/asm/pgtable-ppc64.h| 6 +++--- arch/powerpc/kernel/irq.c

[PATCH 5/6] powerpc: Add printk levels to powernv platform code

2014-09-16 Thread Anton Blanchard
Add printk levels to powernv platform code, and convert to pr_err() etc while here. Signed-off-by: Anton Blanchard --- arch/powerpc/platforms/powernv/opal-nvram.c | 2 +- arch/powerpc/platforms/powernv/opal.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/p

[PATCH 3/6] powerpc: Remove powerpc specific cmd_line

2014-09-16 Thread Anton Blanchard
There is no need for yet another copy of the command line, just use boot_command_line like everyone else. Signed-off-by: Anton Blanchard --- arch/powerpc/include/asm/machdep.h | 2 -- arch/powerpc/kernel/prom.c | 4 +--- arch/powerpc/kernel/setup-common.c | 2 -- arch/powe

[PATCH 4/6] powerpc: Remove ppc_md.remove_memory

2014-09-16 Thread Anton Blanchard
We have an extra level of indirection on memory hot remove which is not matched on memory hot add. Memory hotplug is book3s only, so there is no need for it. This also enables means remove_memory() (ie memory hot unplug) works on powernv. Signed-off-by: Anton Blanchard --- arch/powerpc/include/

[PATCH 2/6] powerpc: Use pr_fmt in module loader code

2014-09-16 Thread Anton Blanchard
Use pr_fmt to give some context to the error messages in the module code, and convert open coded debug printk to pr_debug. Use pr_err for error messages. Signed-off-by: Anton Blanchard --- arch/powerpc/kernel/module_32.c | 31 ++- arch/powerpc/kernel/module_64.c | 36

[PATCH 1/6] powerpc: Speed up clear_page by unrolling it

2014-09-16 Thread Anton Blanchard
Unroll clear_page 8 times. A simple microbenchmark which allocates and frees a zeroed page: for (i = 0; i < iterations; i++) { unsigned long p = __get_free_page(GFP_KERNEL | __GFP_ZERO); free_page(p); } improves 20% on POWER8. This assumes cacheline sizes won't grow beyond 512 by

RE: [PATCH] fsl-rio: add support for mapping inbound windows

2014-09-16 Thread gang....@freescale.com
It looks good for me. Liu Gang > -Original Message- > From: Martijn de Gouw [mailto:martijn.de.g...@prodrive-technologies.com] > Sent: Tuesday, August 12, 2014 4:48 PM > To: Wood Scott-B07421 > Cc: linuxppc-dev@lists.ozlabs.org; alexandre.boun...@idt.com; > stef.van...@prodrive-technologi

Re: [RFC PATCH] powerpc/numa: add ability to disable and debug topology updates

2014-09-16 Thread Michael Ellerman
On Mon, 2014-09-15 at 16:54 -0700, Nishanth Aravamudan wrote: > On 15.09.2014 [15:05:36 +1000], Michael Ellerman wrote: > > On Tue, 2014-09-09 at 13:09 -0700, Nishanth Aravamudan wrote: > > > Does it really need to be a boot param, or could it be a debugfs or > > sysctl flag? ie. do we need to dis

Re: [PATCH 1/4] powerpc: Make a bunch of things static

2014-09-16 Thread Michael Ellerman
On Tue, 2014-09-16 at 07:56 -0500, Nathan Fontenot wrote: > On 08/19/2014 05:55 PM, Anton Blanchard wrote: > > diff --git a/arch/powerpc/platforms/pseries/dlpar.c > > b/arch/powerpc/platforms/pseries/dlpar.c > > index a2450b8..d37ba4f 100644 > > --- a/arch/powerpc/platforms/pseries/dlpar.c > > +++

Re: [PATCH] ASoC: fsl_spdif: don't change the root clock rate of spdif in driver

2014-09-16 Thread Shawn Guo
On Tue, Sep 16, 2014 at 11:19:28AM -0700, Nicolin Chen wrote: > On Tue, Sep 16, 2014 at 07:46:34PM +0800, Shengjiu Wang wrote: > > The spdif root clock may be used by other module or defined with > > CLK_SET_RATE_GATE, so we can't change the clock rate in driver. > > In this patch remove the clk_se

Re: [PATCH] ASoC: fsl_spdif: don't change the root clock rate of spdif in driver

2014-09-16 Thread Nicolin Chen
On Wed, Sep 17, 2014 at 10:31:28AM +0800, Shawn Guo wrote: > On Tue, Sep 16, 2014 at 07:24:40PM -0700, Nicolin Chen wrote: > > It's not supported in the clock API or just not implemented in our > > code? Can we just register a clock without CLK_SET_RATE_PARENT to > > achieve the purpose? (We are ju

[PATCH V4] powerpc/eeh: Fix kernel crash when passing through VF

2014-09-16 Thread Wei Yang
When doing vfio passthrough a VF, the kernel will crash with following message: [ 442.656459] Unable to handle kernel paging request for data at address 0x0060 [ 442.656593] Faulting instruction address: 0xc0038b88 [ 442.656706] Oops: Kernel access of bad area, sig: 11 [#1] [ 442.

Re: [PATCH] ASoC: fsl_spdif: don't change the root clock rate of spdif in driver

2014-09-16 Thread Shawn Guo
On Tue, Sep 16, 2014 at 07:24:40PM -0700, Nicolin Chen wrote: > It's not supported in the clock API or just not implemented in our > code? Can we just register a clock without CLK_SET_RATE_PARENT to > achieve the purpose? (We are just trying to fix those PRED and PODF > dividers when the driver cal

Re: [PATCH] ASoC: fsl_spdif: don't change the root clock rate of spdif in driver

2014-09-16 Thread Nicolin Chen
On Wed, Sep 17, 2014 at 09:32:52AM +0800, Shawn Guo wrote: > On Tue, Sep 16, 2014 at 11:19:28AM -0700, Nicolin Chen wrote: > > On Tue, Sep 16, 2014 at 07:46:34PM +0800, Shengjiu Wang wrote: > > > The spdif root clock may be used by other module or defined with > > > CLK_SET_RATE_GATE, so we can't c

Re: [PATCH v1 16/21] s390/MSI: Use MSI chip framework to configure MSI/MSI-X irq

2014-09-16 Thread Yijing Wang
On 2014/9/16 19:35, Sebastian Ott wrote: > Hello, > > On Fri, 5 Sep 2014, Yijing Wang wrote: >> Use MSI chip framework instead of arch MSI functions to configure >> MSI/MSI-X irq. So we can manage MSI/MSI-X irq in a unified framework. >> >> Signed-off-by: Yijing Wang >> --- >> arch/s390/pci/pci.

[PATCH] powerpc/85xx/defconfig: Remove duplicate CONFIG_RTC_DRV_DS1307

2014-09-16 Thread Scott Wood
Commit a95e8c28b3dc "powerpc/defconfig: update RTC support" duplicated the CONFIG_RTC_DRV_DS1307 symbol in mpc85xx_defconfig and mpc85xx_smp_defconfig, resulting in this: arch/powerpc/configs/mpc85xx_smp_defconfig:217:warning: override: reassigning to symbol RTC_DRV_DS1307 Fixes: a95e8c28b3dc "p

[PATCH 1/2] powerpc/via-pmu: fix error path in find_via_pmu()

2014-09-16 Thread Aaro Koskinen
From: Phil Carmody Cleanup was not in the reverse order from the set-up, so not all the gotos made sense, and also it was being avoided completely upon failure of init_pmu(). Signed-off-by: Phil Carmody Signed-off-by: Aaro Koskinen --- drivers/macintosh/via-pmu.c | 20 +++- 1

[PATCH 2/2] powerpc/via-pmu: fix OF node leak in Keylargo init

2014-09-16 Thread Aaro Koskinen
From: Phil Carmody If we of_find_node_by_name() then we must of_node_put() too. Signed-off-by: Phil Carmody Signed-off-by: Aaro Koskinen --- drivers/macintosh/via-pmu.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/macintosh/via-pmu.c b/drivers/macintosh/via-pmu.c index 6221235.

[PATCH v3 3/3] pseries: Fix endian issues in cpu hot-removal

2014-09-16 Thread Thomas Falcon
When removing a cpu, this patch makes sure that values gotten from or passed to firmware are in the correct endian format. Signed-off-by: Thomas Falcon --- Changes in v3: drc_index in dlpar_cpu_release is no longer const to fix compilation error found by Bharata Rao --- arch/powerpc/platforms

[PATCH v2 2/3] pseries: Fix endian issues in onlining cpu threads

2014-09-16 Thread Thomas Falcon
The ibm,ppc-interrupt-server#s property is in big endian format. These values need to be converted when used by little endian architectures. Signed-off-by: Thomas Falcon --- Changes in v2: Followed suggestions from Michael Ellerman conversion of intserv values occur once --- arch/powerpc/pl

[PATCH v2 1/3] pseries: Make CPU hotplug path endian safe

2014-09-16 Thread Thomas Falcon
From: Bharata B Rao - ibm,rtas-configure-connector should treat the RTAS data as big endian. - Treat ibm,ppc-interrupt-server#s as big-endian when setting smp_processor_id during hotplug. Signed-off-by: Bharata B Rao Signed-off-by: Thomas Falcon --- Changes in v2: - Don't convert drc_index

[PATCH 0/3] pseries: Make CPU hotplug and hotremove endian safe

2014-09-16 Thread Thomas Falcon
This patchset ensures that cpu hotplugging and hotremoval are compatible with both big and little endian architectures. Bharata B Rao (1): pseries: Make CPU hotplug path endian safe Thomas Falcon (2): pseries: Fix endian issues in onlining cpu threads pseries: Fix endian issues in cpu ho

Re: [RFC PATCH] powerpc/numa: add ability to disable and debug topology updates

2014-09-16 Thread Nishanth Aravamudan
On 16.09.2014 [14:42:20 -0500], Nathan Fontenot wrote: > > > On 09/09/2014 03:09 PM, Nishanth Aravamudan wrote: > > We have hit a few customer issues with the topology update code (VPHN > > and PRRN). It would be nice to be able to debug the notifications coming > > from the hypervisor in both ca

Re: [RFC PATCH] powerpc/numa: add ability to disable and debug topology updates

2014-09-16 Thread Nathan Fontenot
On 09/09/2014 03:09 PM, Nishanth Aravamudan wrote: > We have hit a few customer issues with the topology update code (VPHN > and PRRN). It would be nice to be able to debug the notifications coming > from the hypervisor in both cases to the LPAR, as well as to disable > reacting to the notificati

Re: [PATCH] ASoC: fsl_spdif: don't change the root clock rate of spdif in driver

2014-09-16 Thread Mark Brown
On Tue, Sep 16, 2014 at 11:19:28AM -0700, Nicolin Chen wrote: > So I think, if it's a shared clock, we should not define it as a > rate-changeable one in the SoC level, as we might still have some > SoCs provide a dedicated clock to S/PDIF so as to get the maximum > range of clock support for user

Re: [PATCH] ASoC: fsl_spdif: don't change the root clock rate of spdif in driver

2014-09-16 Thread Nicolin Chen
On Tue, Sep 16, 2014 at 07:46:34PM +0800, Shengjiu Wang wrote: > The spdif root clock may be used by other module or defined with > CLK_SET_RATE_GATE, so we can't change the clock rate in driver. > In this patch remove the clk_set_rate and clk_round_rate to protect the > clock. It's a quite conven

Re: [PATCH 1/4] powerpc: Make a bunch of things static

2014-09-16 Thread Nathan Fontenot
On 08/19/2014 05:55 PM, Anton Blanchard wrote: > Signed-off-by: Anton Blanchard > --- > arch/powerpc/kernel/hw_breakpoint.c | 2 +- > arch/powerpc/kernel/nvram_64.c| 2 +- > arch/powerpc/kernel/pci-common.c | 2 +- > arch/powerpc/kernel/pci_of_scan.c | 2 +-

Re: [PATCH v1 16/21] s390/MSI: Use MSI chip framework to configure MSI/MSI-X irq

2014-09-16 Thread Sebastian Ott
Hello, On Fri, 5 Sep 2014, Yijing Wang wrote: > Use MSI chip framework instead of arch MSI functions to configure > MSI/MSI-X irq. So we can manage MSI/MSI-X irq in a unified framework. > > Signed-off-by: Yijing Wang > --- > arch/s390/pci/pci.c | 18 ++ > 1 files changed, 14 i

[PATCH] ASoC: fsl_spdif: don't change the root clock rate of spdif in driver

2014-09-16 Thread Shengjiu Wang
The spdif root clock may be used by other module or defined with CLK_SET_RATE_GATE, so we can't change the clock rate in driver. In this patch remove the clk_set_rate and clk_round_rate to protect the clock. Signed-off-by: Shengjiu Wang --- sound/soc/fsl/fsl_spdif.c | 24 ++

Re: [PATCH v1 03/21] MSI: Remove the redundant irq_set_chip_data()

2014-09-16 Thread Yijing Wang
>>> arch_teardown_msi_irq() expects to find the msi_chip in the irq >>> chip_data field. As this means drivers don't have any reasonable other >>> possibility to stuff things into this field, I think it would make sense >>> to do the cleanup the other way around: keep the irq_set_chip_data >>> arch

Re: [PATCH v1 03/21] MSI: Remove the redundant irq_set_chip_data()

2014-09-16 Thread Lucas Stach
Am Dienstag, den 16.09.2014, 09:30 +0800 schrieb Yijing Wang: > On 2014/9/15 22:00, Lucas Stach wrote: > > Am Freitag, den 05.09.2014, 18:09 +0800 schrieb Yijing Wang: > >> Currently, pcie-designware, pcie-rcar, pci-tegra drivers > >> use irq chip_data to save the msi_chip pointer. They > >> alread

Re: [PATCH] powerpc/eeh: Fix kernel crash when passing through VF

2014-09-16 Thread Gavin Shan
On Tue, Sep 16, 2014 at 02:02:18PM +0800, Wei Yang wrote: >On Tue, Sep 16, 2014 at 02:03:56PM +1000, Michael Ellerman wrote: >>On Mon, 2014-09-15 at 16:08 +0800, Wei Yang wrote: >>> This patch introduces a marco to convert eeh_dev to eeh_pe. By doing so, it >>> will prevent converting with NULL poi

Re: [PATCH v2 2/2] pseries: Fix endian issues in cpu hot-removal

2014-09-16 Thread Michael Ellerman
On Mon, 2014-09-15 at 12:16 +0530, Bharata B Rao wrote: > On Sat, Sep 13, 2014 at 12:41 AM, Thomas Falcon > wrote: > > > > diff --git a/arch/powerpc/platforms/pseries/dlpar.c > > b/arch/powerpc/platforms/pseries/dlpar.c > > index 9e9f30b2..343dfdf 100644 > > --- a/arch/powerpc/platforms/pseries/d