Re: More commits added to powerpc.git next and master branches

2008-12-15 Thread Benjamin Herrenschmidt
On Tue, 2008-12-16 at 16:10 +1100, Paul Mackerras wrote: > I have added the following commits to the next and master branches of > my powerpc.git tree (including commits pulled from Kumar's tree). I > have also pulled in Linus' current tree and the 3 commits that I just > asked him to pull. Is th

Re: [PATCH 7/8] less use of NODE_DATA()

2008-12-15 Thread Paul Mackerras
Dave Hansen writes: > The use of NODE_DATA() in the ppc init code is fragile. We use > it for some nodes as we are initializing others. As the loop > initializing them has gotten more complex and broken out into > several functions it gets harder and harder to remember how > this goes. With thi

Re: [PATCH] [RFC] Pass a valid token to rats_call() in phyp-dump code.

2008-12-15 Thread Nathan Lynch
Tony Breeds wrote: > ibm_configure_kernel_dump, is passed as the token to rtas_call() but I > cannot see where it is initialised. Set it to something sane? Yes, please. Acked-by: Nathan Lynch Would be good to know whether the dump area registration and dump retrieval are working with your chan

More commits added to powerpc.git next and master branches

2008-12-15 Thread Paul Mackerras
I have added the following commits to the next and master branches of my powerpc.git tree (including commits pulled from Kumar's tree). I have also pulled in Linus' current tree and the 3 commits that I just asked him to pull. Paul. Anton Vorontsov (2): powerpc/qe: Move cmxgcr_lock definit

Re: [PATCH 6/8] cleanup do_init_bootmem()

2008-12-15 Thread Paul Mackerras
Dave Hansen writes: > I'm debating whether this is worth it. It makes this a bit more clean > looking, but doesn't seriously enhance readability. But, I do think > it helps a bit. I get this when compiling a pseries config (with the patches up to this point applied but not 7/8 or 8/8): CC

[git pull] Please pull powerpc.git merge branch

2008-12-15 Thread Paul Mackerras
Linus, Please pull from the 'merge' branch of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc.git merge to get three more commits that fix bugs causing kernel crashes on powerpc. Thanks, Paul. arch/powerpc/mm/hugetlbpage.c |3 +++ arch/powerpc/mm/numa.c

[PATCH] [RFC] Pass a valid token to rats_call() in phyp-dump code.

2008-12-15 Thread Tony Breeds
ibm_configure_kernel_dump, is passed as the token to rtas_call() but I cannot see where it is initialised. Set it to something sane? Signed-off-by: Tony Breeds --- arch/powerpc/platforms/pseries/phyp_dump.c |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/arch/powerpc/p

[PATCH] Protect against NULL pointer deref in phyp-dump code.

2008-12-15 Thread Tony Breeds
print_dump_header() will be called at least once with a NULL pointer in a normal boot sequence. if DEBUG is defined then we will get a deref, add a quick fix to exit early in the NULL pointer case. Signed-off-by: Tony Breeds --- arch/powerpc/platforms/pseries/phyp_dump.c |3 +++ 1 files cha

Re: [PATCH] POWERPC: MTD: Add cached map support to physmap_of MTD driver

2008-12-15 Thread Trent Piepho
On Tue, 16 Dec 2008, Paul Mackerras wrote: > Trent Piepho writes: >> The MTD system supports operation where a direct mapped flash chip is >> mapped twice. The normal mapping is a standard ioremap(), which is >> non-cached and guarded on powerpc. The second mapping is used only for >> reads and c

Re: [PATCH] POWERPC: MTD: Add cached map support to physmap_of MTD driver

2008-12-15 Thread Paul Mackerras
Trent Piepho writes: > The MTD system supports operation where a direct mapped flash chip is > mapped twice. The normal mapping is a standard ioremap(), which is > non-cached and guarded on powerpc. The second mapping is used only for > reads and can be cached and non-guarded. Currently, only t

Re: [PATCH 1/3] add of_find_next_cache_node()

2008-12-15 Thread Nathan Lynch
Benjamin Herrenschmidt wrote: > > Don't 970MP have a shared L2 tho ? The 970MP UM describes 1MB L2 per core, and the device tree on the quad G5 reflects that... might be interesting to know what it looks like on IBM JS21 for comparison's sake, but I think we're okay. _

Re: [PATCH 1/3] add of_find_next_cache_node()

2008-12-15 Thread Benjamin Herrenschmidt
On Mon, 2008-12-15 at 16:33 -0600, Nathan Lynch wrote: > Benjamin Herrenschmidt wrote: > > On Wed, 2008-12-10 at 18:46 -0600, Nathan Lynch wrote: > > > + /* OF on pmac has nodes instead of properties named "l2-cache" > > > +* beneath CPU nodes. > > > +*/ > > > + if (!str

Re: [PATCH 11/16] powerpc/mm: Add SMP support to no-hash TLB handling v3

2008-12-15 Thread Benjamin Herrenschmidt
On Mon, 2008-12-15 at 16:19 -0600, Kumar Gala wrote: > Ok. Lets use MMU_FTR_LOCK_BCAST_TLB_OPS and have a comment about > locking because bus implementations cant handle multiple ivax and/or > multiple syncs. > Hi used MMU_FTR_LOCK_BCAST_INVAL :-) And I put a comment that says: /* This indic

Re: update powerpc.git next and pull in some of benh's mmu patches

2008-12-15 Thread Benjamin Herrenschmidt
> Patches I want to still review and test: > > 6/16 powerpc/mm: Split mmu_context handling v3 > 7/16 powerpc/mm: Rework context management for CPUs with no hash table > v2 > 9/16 powerpc/mm: Introduce MMU features v2 > 11/16 powerpc/mm: Add SMP support to no-hash TLB handling v3 > 12/16 powerpc

Re: [PATCH] POWERPC: MTD: Add cached map support to physmap_of MTD driver

2008-12-15 Thread Trent Piepho
On Mon, 15 Dec 2008, Josh Boyer wrote: > > Did you actually change anything in this version when compared to the > version you sent out last week? If not, is there a reason you sent it > again without flagging it as a resend? I sent it out last week? I'm trying to tie up loose ends before I leav

Re: [PATCH 1/3] add of_find_next_cache_node()

2008-12-15 Thread Nathan Lynch
Benjamin Herrenschmidt wrote: > On Wed, 2008-12-10 at 18:46 -0600, Nathan Lynch wrote: > > + /* OF on pmac has nodes instead of properties named "l2-cache" > > +* beneath CPU nodes. > > +*/ > > + if (!strcmp(np->type, "cpu")) > > + for_each_child_of_node(np

Re: [PATCH 11/16] powerpc/mm: Add SMP support to no-hash TLB handling v3

2008-12-15 Thread Kumar Gala
On Dec 15, 2008, at 3:18 PM, Benjamin Herrenschmidt wrote: On Mon, 2008-12-15 at 15:10 -0600, Kumar Gala wrote: Hmm.. are you mixing the two different locking needs together? The is locking of ivax vs tlbwe and there is locking around multiple "msgs" on the bus. I know for us we can have

Re: [PATCH 11/16] powerpc/mm: Add SMP support to no-hash TLB handling v3

2008-12-15 Thread Benjamin Herrenschmidt
On Mon, 2008-12-15 at 15:10 -0600, Kumar Gala wrote: > Hmm.. are you mixing the two different locking needs together? The is > locking of ivax vs tlbwe and there is locking around multiple "msgs" > on the bus. I know for us we can have any # of ivax's on the bus, but > only one tlbsync. I

Re: [PATCH 11/16] powerpc/mm: Add SMP support to no-hash TLB handling v3

2008-12-15 Thread Kumar Gala
On Dec 15, 2008, at 3:03 PM, Benjamin Herrenschmidt wrote: The whole thing. Not totally clear, you have a better name ? Some CPUs want a lock on sync and some on ivax, I plan to lock the whole sequence. MMU_FTR_TLBIVAX_OR_SYNC_NEED_LOCK ? Which completely blows away the nice tab'ing :-)

Re: [PATCH 15/16] powerpc/mm: Rework usage of _PAGE_COHERENT/NO_CACHE/GUARDED

2008-12-15 Thread Benjamin Herrenschmidt
On Tue, 2008-12-16 at 08:03 +1100, Michael Ellerman wrote: > On Mon, 2008-12-15 at 14:54 -0600, Kumar Gala wrote: > > > > > > #ifndef __ASSEMBLY__ > > > + > > > +/* > > > + * Macro to mark a page protection value as "uncacheable". > > > + */ > > > + > > > +#define _PAGE_CACHE_CTL (_PAGE_COHERENT |

Re: [PATCH 15/16] powerpc/mm: Rework usage of _PAGE_COHERENT/NO_CACHE/GUARDED

2008-12-15 Thread Kumar Gala
On Dec 15, 2008, at 3:01 PM, Benjamin Herrenschmidt wrote: -#ifdef CONFIG_44x -#define _PAGE_BASE (_PAGE_PRESENT | _PAGE_ACCESSED | _PAGE_GUARDED) +#if defined(CONFIG_SMP) || defined(CONFIG_PPC_STD_MMU) +#define _PAGE_BASE (_PAGE_PRESENT | _PAGE_ACCESSED | _PAGE_COHERENT) #else #define

Re: [PATCH 11/16] powerpc/mm: Add SMP support to no-hash TLB handling v3

2008-12-15 Thread Benjamin Herrenschmidt
> > The whole thing. Not totally clear, you have a better name ? Some CPUs > > want a lock on sync and some on ivax, I plan to lock the whole > > sequence. > > MMU_FTR_TLBIVAX_OR_SYNC_NEED_LOCK ? Which completely blows away the nice tab'ing :-) MMU_FTR_LOCK_BCAST_TLB_OPS ? > Its probably a g

Re: [PATCH 15/16] powerpc/mm: Rework usage of _PAGE_COHERENT/NO_CACHE/GUARDED

2008-12-15 Thread Benjamin Herrenschmidt
> > -#ifdef CONFIG_44x > > -#define _PAGE_BASE (_PAGE_PRESENT | _PAGE_ACCESSED | _PAGE_GUARDED) > > +#if defined(CONFIG_SMP) || defined(CONFIG_PPC_STD_MMU) > > +#define _PAGE_BASE (_PAGE_PRESENT | _PAGE_ACCESSED | _PAGE_COHERENT) > > #else > > #define _PAGE_BASE (_PAGE_PRESENT | _PAGE_ACCESSED) >

Re: [PATCH 15/16] powerpc/mm: Rework usage of _PAGE_COHERENT/NO_CACHE/GUARDED

2008-12-15 Thread Michael Ellerman
On Mon, 2008-12-15 at 14:54 -0600, Kumar Gala wrote: > > > > #ifndef __ASSEMBLY__ > > + > > +/* > > + * Macro to mark a page protection value as "uncacheable". > > + */ > > + > > +#define _PAGE_CACHE_CTL(_PAGE_COHERENT | _PAGE_COHERENT | > > _PAGE_COHERENT | \ > > +_PAGE_WR

Re: [PATCH 11/16] powerpc/mm: Add SMP support to no-hash TLB handling v3

2008-12-15 Thread Kumar Gala
On Dec 15, 2008, at 2:46 PM, Benjamin Herrenschmidt wrote: Index: linux-work/arch/powerpc/include/asm/mmu.h === --- linux-work.orig/arch/powerpc/include/asm/mmu.h 2008-12-15 14:36:20.0 +1100 +++ linux-work/arch/powerp

Re: [PATCH 15/16] powerpc/mm: Rework usage of _PAGE_COHERENT/NO_CACHE/GUARDED

2008-12-15 Thread Kumar Gala
--- linux-work.orig/arch/powerpc/include/asm/pgtable-ppc32.h 2008-11-24 14:48:55.0 +1100 +++ linux-work/arch/powerpc/include/asm/pgtable-ppc32.h 2008-12-15 15:34:16.0 +1100 [snip] @@ -436,20 +437,23 @@ extern int icache_44x_need_flush; _PAGE_USER

Re: update powerpc.git next and pull in some of benh's mmu patches

2008-12-15 Thread Josh Boyer
On Mon, 15 Dec 2008 14:44:12 -0600 Kumar Gala wrote: > Pathces left up to Josh & Ben > > 3/16 powerpc/4xx: Extended DCR support v2 I'd like to test this one a bit. > 13/16 powerpc/44x: No need to mask MSR:CE, ME or DE in _tlbil_va on 440 This one should be good to go. I already Acked it. >

Re: [PATCH 8/16] powerpc/mm: Rename tlb_32.c and tlb_64.c to tlb_hash32.c and tlb_hash64.c

2008-12-15 Thread Benjamin Herrenschmidt
On Mon, 2008-12-15 at 14:36 -0600, Kumar Gala wrote: > > Acked-by: Kumar Gala > > (I'm told git-format-patch -M is useful for such patches) I'm still using quilt for my own developement. Cheers, Ben. ___ Linuxppc-dev mailing list Linuxppc-dev@ozlab

Re: [PATCH 11/16] powerpc/mm: Add SMP support to no-hash TLB handling v3

2008-12-15 Thread Benjamin Herrenschmidt
> > +void local_flush_tlb_mm(struct mm_struct *mm) > > +{ > > + unsigned int pid; > > + > > + preempt_disable(); > > + pid = mm->context.id; > > + if (pid != MMU_NO_CONTEXT) > > + _tlbil_pid(pid); > > + preempt_enable(); > > +} > > +EXPORT_SYMBOL(local_flush_tlb_mm); > > Do th

update powerpc.git next and pull in some of benh's mmu patches

2008-12-15 Thread Kumar Gala
Paul, Can you update powerpc.git to linus's top of tree (we need the tlbil_va patch Linus picked up). Also, can you pull in my next tree and some of Ben's trivial mmu related changes: 1/16 powerpc: Fix bogus cache flushing on all 40x and BookE processors v2 -- in my next tree (pull requ

Re: Need help to understand why kdump is for 64 bit PPC only

2008-12-15 Thread Josh Boyer
On Tue, 16 Dec 2008 07:33:04 +1100 Michael Ellerman wrote: > On Mon, 2008-12-15 at 13:35 -0600, Kumar Gala wrote: > > On Dec 15, 2008, at 12:58 PM, Frank Fan wrote: > > > > > Hello, > > > > > > I am working on a freescale MPC8572 CPU board and use 32 bit > > > Linux2.6.28. When I enable 64 bi

Re: [PATCH 8/16] powerpc/mm: Rename tlb_32.c and tlb_64.c to tlb_hash32.c and tlb_hash64.c

2008-12-15 Thread Kumar Gala
On Dec 14, 2008, at 11:44 PM, Benjamin Herrenschmidt wrote: This renames the files to clarify the fact that they are used by the hash based family of CPUs (the 603 being an exception in that family but is still handled by that code). This paves the way for the new tlb_nohash.c coming via a sub

Re: Need help to understand why kdump is for 64 bit PPC only

2008-12-15 Thread Michael Ellerman
On Mon, 2008-12-15 at 13:35 -0600, Kumar Gala wrote: > On Dec 15, 2008, at 12:58 PM, Frank Fan wrote: > > > Hello, > > > > I am working on a freescale MPC8572 CPU board and use 32 bit > > Linux2.6.28. When I enable 64 bit, it shows "kdump" in "kernel > > options". Otherwise, "kdump" is disabl

Please pull from 'next' branch

2008-12-15 Thread Kumar Gala
Please pull from 'next' branch of master.kernel.org:/pub/scm/linux/kernel/git/galak/powerpc.git next to receive the following updates: arch/powerpc/boot/dts/mpc8572ds.dts | 16 arch/powerpc/include/asm/cputable.h | 15 --- 2 files changed, 16 insertions(

Re: [PATCH 5/16] powerpc/mm: Add local_flush_tlb_mm() to SW loaded TLB implementations

2008-12-15 Thread Kumar Gala
On Dec 14, 2008, at 11:44 PM, Benjamin Herrenschmidt wrote: This adds a local_flush_tlb_mm() call as a pre-requisite for some SMP work for BookE processors Signed-off-by: Benjamin Herrenschmidt --- arch/powerpc/include/asm/tlbflush.h |5 + 1 file changed, 5 insertions(+) Acked-by: K

Re: [PATCH 6/16] powerpc/mm: Split mmu_context handling v3

2008-12-15 Thread Benjamin Herrenschmidt
On Mon, 2008-12-15 at 16:43 +0100, Arnd Bergmann wrote: > Didn't we lift the limit to 30,000 tasks at some point? The comment > in linux/threads.h mentions that the PID space goes up to 4 million. > What does actually happen when we increase pid_max to beyond 32768 > on those systems and try to use

Re: [PATCH 11/16] powerpc/mm: Add SMP support to no-hash TLB handling v3

2008-12-15 Thread Kumar Gala
On Dec 14, 2008, at 11:44 PM, Benjamin Herrenschmidt wrote: This patch moves the whole no-hash TLB handling out of line into a new tlb_nohash.c file, and implements some basic SMP support using IPIs and/or broadcast tlbivax instructions. Note that I'm using local invalidations for D->I cache c

Re: Need help to understand why kdump is for 64 bit PPC only

2008-12-15 Thread Kumar Gala
On Dec 15, 2008, at 12:58 PM, Frank Fan wrote: Hello, I am working on a freescale MPC8572 CPU board and use 32 bit Linux2.6.28. When I enable 64 bit, it shows "kdump" in "kernel options". Otherwise, "kdump" is disabled. Can someone give me some hint why kdump is for 64 bit PPC only? Pr

Need help to understand why kdump is for 64 bit PPC only

2008-12-15 Thread Frank Fan
Hello, I am working on a freescale MPC8572 CPU board and use 32 bit Linux2.6.28. When I enable 64 bit, it shows "kdump" in "kernel options". Otherwise, "kdump" is disabled. Can someone give me some hint why kdump is for 64 bit PPC only? Thanks for the help, Frank Fan Alcatel-Lucent Salt Lake Cit

Re: [PATCH] POWERPC: MTD: Add cached map support to physmap_of MTD driver

2008-12-15 Thread Josh Boyer
On Mon, 15 Dec 2008 10:25:18 -0800 Trent Piepho wrote: > The MTD system supports operation where a direct mapped flash chip is > mapped twice. The normal mapping is a standard ioremap(), which is > non-cached and guarded on powerpc. The second mapping is used only for > reads and can be cached

[PATCH] POWERPC: MTD: Add cached map support to physmap_of MTD driver

2008-12-15 Thread Trent Piepho
The MTD system supports operation where a direct mapped flash chip is mapped twice. The normal mapping is a standard ioremap(), which is non-cached and guarded on powerpc. The second mapping is used only for reads and can be cached and non-guarded. Currently, only the pxa2xx mapping driver makes

UC1611 LCD controller driver

2008-12-15 Thread mike zheng
Hi, Does anyone has the UC1611 LCD controller driver of Kernel2.6? Thanks for your help, Mike ___ Linuxppc-dev mailing list Linuxppc-dev@ozlabs.org https://ozlabs.org/mailman/listinfo/linuxppc-dev

Re: [PATCH 6/16] powerpc/mm: Split mmu_context handling v3

2008-12-15 Thread Arnd Bergmann
On Monday 15 December 2008, Benjamin Herrenschmidt wrote: > +/* > + * On 32-bit PowerPC 6xx/7xx/7xxx CPUs, we use a set of 16 VSIDs > + * (virtual segment identifiers) for each context. Although the > + * hardware supports 24-bit VSIDs, and thus >1 million contexts, > + * we only use 32,768 of the

Re: [PATCH 13/16] powerpc/44x: No need to mask MSR:CE,ME or DE in _tlbil_va on 440

2008-12-15 Thread Josh Boyer
On Mon, 15 Dec 2008 16:45:05 +1100 Benjamin Herrenschmidt wrote: > The handlers for Critical, Machine Check or Debug interrupts > will save and restore MMUCR nowadays, thus we only need to > disable normal interrupts when invalidating TLB entries. > > Signed-off-by: Benjamin Herrenschmidt Acke