Re: [PATCH] powerpc: Add support for OpenBlockS 600

2011-12-02 Thread Benjamin Herrenschmidt
On Thu, 2011-12-01 at 22:40 -0800, Olof Johansson wrote: > Hi, > > On Thu, Dec 1, 2011 at 9:35 PM, Benjamin Herrenschmidt > wrote: > > > arch/powerpc/boot/dts/obs600.dts | 314 > > > > It'd be nice to have dtsi files for the SoCs, there's a lot of boiler

Re: [PATCH 3/3] 8250: add workaround for MPC8[356]xx UART break IRQ storm

2011-12-02 Thread Alan Cox
> > OK, I'll simply change the above to CONFIG_PPC then. > > It does, the bug is in the uart IP which I don't think we ever plan on > fixing, so 32 or 64-bit parts will have it for ever and ever ;) It should be runtime selected, there should be no ifdefs here. __

Re: [PATCH 1/3] serial: make bugs field not specific to 8250 type uarts.

2011-12-02 Thread Alan Cox
> If you have an idea in mind how arch/platform code should cleanly > pass data about known uart bugs to the uart driver, then let me know > what you have in mind. I've no real attachment to what I proposed > here -- it just happened to be the solution I thought would be the least > offensive. If

Re: [PATCH] powerpc: Add support for OpenBlockS 600

2011-12-02 Thread Josh Boyer
On Fri, Dec 2, 2011 at 1:40 AM, Olof Johansson wrote: > Hi, > > On Thu, Dec 1, 2011 at 9:35 PM, Benjamin Herrenschmidt > wrote: > >>  arch/powerpc/boot/dts/obs600.dts           |  314 >> > > It'd be nice to have dtsi files for the SoCs, there's a lot of boiler > plat

Re: sam460ex, sm501 incorrect device id with kernel >=linux-2.6.39

2011-12-02 Thread acrux
On Mon, 28 Nov 2011 21:22:24 +0100 Anatolij Gustschin wrote: > On Mon, 28 Nov 2011 20:56:55 +0100 > acrux wrote: > ... > > it seems to be an endianess issue but i didn't find when it was > > introduced. Really strange this kind of issue was never noticed > > bumping from 2.6.38.x to 2.6.39.x .

Re: sam460ex, sm501 incorrect device id with kernel >=linux-2.6.39

2011-12-02 Thread Anatolij Gustschin
Hi, On Fri, 2 Dec 2011 15:48:33 +0100 acrux wrote: ... > This little hack fix my problem: > --- a/inlcude/linux/sm501.h 2011-12-02 01:11:04.0 +0100 > +++ b/include/linux/sm501.h 2011-12-02 01:11:09.0 +0100 > @@ -174,8 +174,8 @@ > }; > > #if defined(CONFIG_PPC32) > -#define

[PATCH v3 00/10] powerpc/mpic: General cleanup patch series

2011-12-02 Thread Kyle Moffett
Hello, This is version 3 of the MPIC cleanup patches. A few minor bugfixes have been rolled into patches 2, 7, and 10, kudos to Paul Mackerras and Michael Ellerman for reporting them. Additionally, the series has been rebased onto Ben's "next" branch for easier merging: git://git.kernel.org/pu

[PATCH v3 01/10] powerpc/85xx: Move mpc85xx_smp_init() decl to a new "smp.h"

2011-12-02 Thread Kyle Moffett
This removes a bunch of "extern" declarations and CONFIG_SMP ifdefs. Signed-off-by: Kyle Moffett Cc: Benjamin Herrenschmidt Cc: Paul Mackerras Cc: Kumar Gala --- arch/powerpc/platforms/85xx/corenet_ds.c |7 +-- arch/powerpc/platforms/85xx/mpc85xx_ds.c |6 +- arch/powerpc/pla

[PATCH v3 02/10] powerpc: Consolidate mpic_alloc() OF address translation

2011-12-02 Thread Kyle Moffett
Instead of using the open-coded "reg" property lookup and address translation in mpic_alloc(), directly call of_address_to_resource(). This includes various workarounds for special cases which the naive of_address_translate() does not. Afterwards it is possible to remove the copiously copy-pasted

[PATCH v3 03/10] powerpc/mpic: Assume a device-node was passed in mpic_alloc()

2011-12-02 Thread Kyle Moffett
All of the existing callers of mpic_alloc() pass in a non-NULL device-node pointer, so the checks for a NULL device-node may be removed. Signed-off-by: Kyle Moffett --- arch/powerpc/sysdev/mpic.c | 50 ++- 1 files changed, 21 insertions(+), 29 deletions(

[PATCH v3 04/10] powerpc/mpic: Save computed phys_addr for board-specific code

2011-12-02 Thread Kyle Moffett
The MPIC code can already perform an automatic OF address translation step as part of mpic_alloc(), but several boards need to use that base address when they perform mpic_assign_isu(). The easiest solution is to save the computed physical address into the "struct mpic" for later use by the board

[PATCH v3 05/10] powerpc/mpic: Search for open-pic device-tree node if NULL

2011-12-02 Thread Kyle Moffett
Almost all PowerPC platforms use a standard "open-pic" device node so the mpic_alloc() function now accepts NULL for the device-node. This will cause it to perform a default search with of_find_matching_node(). Signed-off-by: Kyle Moffett --- arch/powerpc/platforms/85xx/corenet_ds.c |

[PATCH v3 06/10] powerpc/mpic: Invert the meaning of MPIC_PRIMARY

2011-12-02 Thread Kyle Moffett
It turns out that there are only 2 in-tree platforms which use MPICs which are not "primary": IBM Cell and PowerMac. To reduce the complexity of the typical board setup code, invert the MPIC_PRIMARY bit into MPIC_SECONDARY. Signed-off-by: Kyle Moffett --- arch/powerpc/include/asm/mpic.h

[PATCH v3 07/10] powerpc/mpic: Don't open-code dcr_resource_start

2011-12-02 Thread Kyle Moffett
Don't open-code the OpenFirmware "dcr-reg" property lookup trying to map DCR resources. This makes the code a bit easier to read. Signed-off-by: Kyle Moffett --- arch/powerpc/sysdev/mpic.c |7 ++- 1 files changed, 2 insertions(+), 5 deletions(-) diff --git a/arch/powerpc/sysdev/mpic.c

[PATCH v3 08/10] powerpc/mpic: Put "pic-no-reset" test back into the MPIC code

2011-12-02 Thread Kyle Moffett
There's not really any reason to have this one-liner in a separate static inline function, given that all the other similar tests are already in the alloc_mpic() code. Signed-off-by: Kyle Moffett --- arch/powerpc/sysdev/mpic.c |7 +-- 1 files changed, 1 insertions(+), 6 deletions(-) dif

[PATCH v3 09/10] powerpc/mpic: Cache the device-tree node in "struct mpic"

2011-12-02 Thread Kyle Moffett
Store the node pointer in the MPIC during initialization so that all of the later operational code can just reuse the cached pointer. Signed-off-by: Kyle Moffett --- arch/powerpc/include/asm/mpic.h |3 +++ arch/powerpc/sysdev/mpic.c | 33 - 2 files chan

[PATCH v3 10/10] powerpc/mpic: Add in-core support for cascaded MPICs

2011-12-02 Thread Kyle Moffett
The Cell and PowerMac platforms use virtually identical cascaded-IRQ setup code, so just merge it into the core. Ideally this code would trigger automatically when an MPIC device-node specifies an "interrupts" property, perhaps even enabling MPIC_SECONDARY along the way. Unfortunately, Benjamin H

Re: [PATCH 3/3] 8250: add workaround for MPC8[356]xx UART break IRQ storm

2011-12-02 Thread Paul Gortmaker
On 11-12-02 06:30 AM, Alan Cox wrote: >>> OK, I'll simply change the above to CONFIG_PPC then. >> >> It does, the bug is in the uart IP which I don't think we ever plan on >> fixing, so 32 or 64-bit parts will have it for ever and ever ;) > > It should be runtime selected, there should be no ifde

Re: [PATCH][RFC] fsldma: fix performance degradation by optimizing spinlock use.

2011-12-02 Thread Ira W. Snyder
On Fri, Dec 02, 2011 at 03:47:27AM +, Shi Xuelin-B29237 wrote: > Hi Iris, > > >I'm convinced that "smp_rmb()" is needed when removing the spinlock. As > >noted, Documentation/memory-barriers.txt says that stores on one CPU can be > >observed by another CPU in a different order. > >Previously,

Re: [PATCH 3/3] 8250: add workaround for MPC8[356]xx UART break IRQ storm

2011-12-02 Thread Scott Wood
On 12/02/2011 10:34 AM, Paul Gortmaker wrote: > On 11-12-02 06:30 AM, Alan Cox wrote: OK, I'll simply change the above to CONFIG_PPC then. >>> >>> It does, the bug is in the uart IP which I don't think we ever plan on >>> fixing, so 32 or 64-bit parts will have it for ever and ever ;) >> >> I

Re: [PATCH 2/8] 44x/pci: Add a want_sdr flag into ppc4xx_pciex_hwops

2011-12-02 Thread Benjamin Herrenschmidt
On Thu, 2011-12-01 at 18:39 +1100, Tony Breeds wrote: > + if (ppc4xx_pciex_hwops->want_sdr == true) { if (ppc4xx_pciex_hwops->want_sdr) { Please ! This is a boolean after all :-) Cheers, Ben. ___ Linuxppc-dev mailing list Linuxppc-dev@l

Re: [PATCH 7/8] 44x/476fpe: Add 476fpe SoC code

2011-12-02 Thread Benjamin Herrenschmidt
On Thu, 2011-12-01 at 18:39 +1100, Tony Breeds wrote: > Based on original work by David 'Shaggy' Kliekamp. Typo in Shaggy's last name :-) Cheers, Ben. ___ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.org/listinfo/linuxp

[PATCH 1/2] powerpc/85xx: fix localbus and PCI addresses in the P1022DS 36-bit device tree

2011-12-02 Thread Timur Tabi
Fix the PCI buses in the 36-bit device tree for the P1022DS. It was using values copy-pasted from another device tree. Also fix the NAND localbus bus address from ffa0 to ff80, which is what U-boot sets it to. Signed-off-by: Timur Tabi --- arch/powerpc/boot/dts/p1022ds.dts |8 -

[PATCH 2/2] powerpc/85xx: add a 32-bit P1022DS device tree

2011-12-02 Thread Timur Tabi
Add a 32-bit version of the device tree for the Freescale P1022DS reference board. Signed-off-by: Timur Tabi --- arch/powerpc/boot/dts/p1022ds_32b.dts | 270 + 1 files changed, 270 insertions(+), 0 deletions(-) create mode 100644 arch/powerpc/boot/dts/p1022ds_32

Re: [PATCH 2/2] powerpc/85xx: add a 32-bit P1022DS device tree

2011-12-02 Thread Scott Wood
On 12/02/2011 04:08 PM, Timur Tabi wrote: > + lbc: localbus@ffe05000 { > + reg = <0x0 0xffe05000 0 0x1000>; > + ranges = <0x0 0x0 0x0 0xe800 0x0800 > + 0x1 0x0 0x0 0xe000 0x0800 > + 0x2 0x0 0x0 0xff80 0x0004

Re: [PATCH 2/2] powerpc/85xx: add a 32-bit P1022DS device tree

2011-12-02 Thread Timur Tabi
Scott Wood wrote: > Please add something after post to strip simple-bus off of the localbus > node's compatible. Either you have board-control@0,0, or you have the > other stuff (did you ever find out what the situation with NAND is?) -- > not both at the same time. Or do you have U-Boot patchin

[PATCH 1/1] Punch a hole in /dev/mem for librtas

2011-12-02 Thread Sukadev Bhattiprolu
Subject: [PATCH 1/1] Punch a hole in /dev/mem for librtas With CONFIG_STRICT_DEVMEM=y, user space cannot read any part of /dev/mem. Since this breaks librtas, punch a hole in /dev/mem to allow access to the rmo_buffer that librtas needs. Anton Blanchard reported the problem and helped with the f

Re: [PATCH 2/2] powerpc/85xx: add a 32-bit P1022DS device tree

2011-12-02 Thread Scott Wood
On 12/02/2011 04:24 PM, Timur Tabi wrote: > Scott Wood wrote: > >> Please add something after post to strip simple-bus off of the localbus >> node's compatible. Either you have board-control@0,0, or you have the >> other stuff (did you ever find out what the situation with NAND is?) -- >> not bot

Re: [PATCH 2/2] powerpc/85xx: add a 32-bit P1022DS device tree

2011-12-02 Thread Kumar Gala
On Dec 2, 2011, at 4:08 PM, Timur Tabi wrote: > Add a 32-bit version of the device tree for the Freescale P1022DS reference > board. > > Signed-off-by: Timur Tabi > --- > arch/powerpc/boot/dts/p1022ds_32b.dts | 270 + > 1 files changed, 270 insertions(+), 0 delet

Re: [PATCH 2/2] powerpc/85xx: add a 32-bit P1022DS device tree

2011-12-02 Thread Timur Tabi
Scott Wood wrote: > Nothing that happens in Linux excuses handing Linux a device tree that > is wrong. That you need special handling in Linux indicates that this > is not a simple-bus. How about this: diff --git a/arch/powerpc/boot/dts/fsl/p1022si-post.dtsi b/arch/powerpc/boot/dts index 16239b

Re: [PATCH 2/2] powerpc/85xx: add a 32-bit P1022DS device tree

2011-12-02 Thread Scott Wood
On 12/02/2011 05:41 PM, Timur Tabi wrote: > Scott Wood wrote: > >> Nothing that happens in Linux excuses handing Linux a device tree that >> is wrong. That you need special handling in Linux indicates that this >> is not a simple-bus. > > How about this: > > diff --git a/arch/powerpc/boot/dts/f

Re: [PATCH 1/1] Punch a hole in /dev/mem for librtas

2011-12-02 Thread Segher Boessenkool
+static inline int page_is_rtas_user_buf(unsigned long pfn) +{ + unsigned long paddr = (pfn << PAGE_SHIFT); + if (paddr >= rtas_rmo_buf && paddr < (rtas_rmo_buf + RTAS_RMOBUF_MAX)) It probably cannot overflow with actual values of rtas_rmo_buf and RTAS_RMOBUF_MAX, but otherwise it is an