[PATCH] powerpc/powernv: Use MSI bitmap to manage IRQs

2013-03-05 Thread Gavin Shan
As Michael Ellerman mentioned, arch/powerpc/sysdev/msi_bitmap.c already implemented bitmap to manage (alloc/free) MSI interrupts. The patch intends to use that mechanism to manage MSI interrupts for PowerNV platform. Signed-off-by: Gavin Shan --- arch/powerpc/platforms/powernv/pci-ioda.c | 1

Re: [PATCH 2/3] irq: Add hw continuous IRQs map to virtual continuous IRQs support

2013-03-05 Thread Mike Qiu
于 2013/3/6 13:42, Michael Ellerman 写道: On Wed, Mar 06, 2013 at 01:34:58PM +0800, Mike Qiu wrote: 于 2013/3/6 11:54, Michael Ellerman 写道: On Tue, Mar 05, 2013 at 03:19:57PM +0800, Mike Qiu wrote: 于 2013/3/5 10:23, Michael Ellerman 写道: On Tue, Jan 15, 2013 at 03:38:55PM +0800, Mike Qiu wrote: d

Re: [PATCH] ppc32: Fix compile of sha1-powerpc-asm.S

2013-03-05 Thread Christian Kujau
On Wed, 6 Mar 2013 at 15:09, Michael Ellerman wrote: > Thanks Christian. What hardware are you on? This is a PowerBook G4, 32bit, uni-processor. Full dmesg, e.g.: http://nerdbynature.de/bits/3.9.0-rc1/dmesg.txt C. -- BOFH excuse #88: Boss' kid fucked up the machine __

[PATCH -V2 15/26] powerpc: Print page size info during boot

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" This gives hint about different base and actual page size combination supported by the platform. Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/mm/hash_utils_64.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/arch/powerpc/mm/hash_ut

[PATCH -V2 24/26] powerpc/THP: get_user_pages_fast changes

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" handle large pages for get_user_pages_fast. Also take care of large page splitting. Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/mm/gup.c | 84 +++-- 1 file changed, 82 insertions(+), 2 deletions(-) diff --git a/arch/

[PATCH -V2 17/26] mm/THP: Add pmd args to pgtable deposit and withdraw APIs

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" This will be later used by powerpc THP support. In powerpc we want to use pgtable for storing the hash index values. So instead of adding them to mm_context list, we would like to store them in the second half of pmd Cc: Andrea Arcangeli Signed-off-by: Aneesh Kumar K.V

[PATCH -V2 26/26] powerpc: Optimize hugepage invalidate

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" Hugepage invalidate involves invalidating multiple hpte entries. Optimize the operation using H_BULK_REMOVE on lpar platforms. On native, reduce the number of tlb flush. Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/include/asm/machdep.h|3 + arch/powerpc/mm

[PATCH -V2 25/26] powerpc/THP: Enable THP on PPC64

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" We enable only if the we support 16MB page size. Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/include/asm/pgtable.h | 30 -- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/include/asm/pgtable.h b/arch/powe

[PATCH -V2 22/26] powerpc: Handle huge page in perf callchain

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/perf/callchain.c | 32 +--- 1 file changed, 21 insertions(+), 11 deletions(-) diff --git a/arch/powerpc/perf/callchain.c b/arch/powerpc/perf/callchain.c index 578cac7..99262ce 100644 --- a/a

[PATCH -V2 23/26] powerpc/THP: hypervisor require few WIMG bit set

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" Without this insert will return H_PARAMETER error. Also use the signed variant when printing error. Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/mm/hugepage-hash64.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/powerpc/mm/hugepage-hash64.c b/arch/

[PATCH -V2 21/26] powerpc/THP: Add code to handle HPTE faults for large pages

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" We now have pmd entries covering to 16MB range. To implement THP on powerpc, we double the size of PMD. The second half is used to deposit the pgtable (PTE page). We also use the depoisted PTE page for tracking the HPTE information. The information include [ secondary g

[PATCH -V2 20/26] powerpc/THP: Differentiate THP PMD entries from HUGETLB PMD entries

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" HUGETLB clear the top bit of PMD entries and use that to indicate a HUGETLB page directory. Since we store pfns in PMDs for THP, we would have the top bit cleared by default. Add the top bit mask for THP PMD entries and clear that when we are looking for pmd_pfn. Signed-

[PATCH -V2 19/26] powerpc/THP: Implement transparent huge pages for ppc64

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" We now have pmd entries covering to 16MB range. To implement THP on powerpc, we double the size of PMD. The second half is used to deposit the pgtable (PTE page). We also use the depoisted PTE page for tracking the HPTE information. The information include [ secondary g

[PATCH -V2 18/26] mm/THP: withdraw the pgtable after pmdp related operations

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" For architectures like ppc64 we look at deposited pgtable when calling pmdp_get_and_clear. So do the pgtable_trans_huge_withdraw after finishing pmdp related operations. Cc: Andrea Arcangeli Signed-off-by: Aneesh Kumar K.V --- mm/huge_memory.c |3 ++- 1 file chang

[PATCH -V2 16/26] mm/THP: HPAGE_SHIFT is not a #define on some arch

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" On archs like powerpc that support different huge page sizes, HPAGE_SHIFT and other derived values like HPAGE_PMD_ORDER are not constants. So move that to hugepage_init Cc: Andrea Arcangeli Signed-off-by: Aneesh Kumar K.V --- include/linux/huge_mm.h |3 --- mm/hug

[PATCH -V2 06/26] powerpc: Reduce PTE table memory wastage

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" We allocate one page for the last level of linux page table. With THP and large page size of 16MB, that would mean we are be wasting large part of that page. To map 16MB area, we only need a PTE space of 2K with 64K page size. This patch reduce the space wastage by sharin

[PATCH -V2 13/26] powerpc: Update tlbie/tlbiel as per ISA doc

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" This make sure we handle multiple page size segment correctly. Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/mm/hash_native_64.c | 52 +- 1 file changed, 40 insertions(+), 12 deletions(-) diff --git a/arch/powerpc/mm/hash_nativ

[PATCH -V2 14/26] powerpc: print both base and actual page size on hash failure

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/include/asm/mmu-hash64.h |3 ++- arch/powerpc/mm/hash_utils_64.c | 12 +++- arch/powerpc/mm/hugetlbpage-hash64.c |2 +- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/arch/powerpc

[PATCH -V2 12/26] powerpc: Return all the valid pte ecndoing in KVM_PPC_GET_SMMU_INFO ioctl

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/kvm/book3s_hv.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/kvm/book3s_hv.c b/arch/powerpc/kvm/book3s_hv.c index 48f6d99..e50eb0d 100644 --- a/arch/powerpc/kvm/book3s_hv.

[PATCH -V2 05/26] powerpc: Move the pte free routines from common header

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" This patch moves the common code to 32/64 bit headers and also duplicate 4K_PAGES and 64K_PAGES section. We will later change the 64 bit 64K_PAGES version to support smaller PTE fragments. The patch doesn't introduce any functional changes. Acked-by: Paul Mackerras Sign

[PATCH -V2 11/26] powerpc: Fix hpte_decode to use the correct decoding for page sizes

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" As per ISA doc, we encode base and actual page size in the LP bits of PTE. The number of bit used to encode the page sizes depend on actual page size. ISA doc lists this as PTE LP actual page size rrrz ≥8KB rrzz ≥16KB rzzz ≥32KB r

[PATCH -V2 10/26] powerpc: Decode the pte-lp-encoding bits correctly.

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" We look at both the segment base page size and actual page size and store the pte-lp-encodings in an array per base page size. We also update all relevant functions to take actual page size argument so that we can use the correct PTE LP encoding in HPTE. This should also

[PATCH -V2 09/26] powerpc: Use encode avpn where we need only avpn values

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" In all these cases we are doing something similar to HPTE_V_COMPARE(hpte_v, want_v) which ignores the HPTE_V_LARGE bit With MPSS support we would need actual page size to set HPTE_V_LARGE bit and that won't be available in most of these cases. Since we are ignoring HPTE

[PATCH -V2 08/26] powerpc: Clarify __pgtable_cache_add by renaming shift to index

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" With table_size as second argument, first argument of the function is not the shift value, but rather index into the array. Rename the variable to clarify the same. Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/include/asm/pgtable-ppc64.h |2 +- arch/powerpc/mm/

[PATCH -V2 07/26] powerpc: Add size argument to pgtable_cache_add

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" We will use this later with THP changes to request for pmd table of double the size. THP code does PTE page allocation along with large page request and deposit them for later use. This is to ensure that we won't have any failures when we split huge pages to regular page

[PATCH -V2 04/26] powerpc: Reduce the PTE_INDEX_SIZE

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" This make one PMD cover 16MB range. That helps in easier implementation of THP on power. THP core code make use of one pmd entry to track the huge page and the range mapped by a single pmd entry should be equal to the huge page size supported by the hardware. Acked-by: P

[PATCH -V2 03/26] powerpc: Don't hard code the size of pte page

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" USE PTRS_PER_PTE to indicate the size of pte page. To support THP, later patches will be changing PTRS_PER_PTE value. Acked-by: Paul Mackerras Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/include/asm/pgtable.h |6 ++ arch/powerpc/mm/hash_low_64.S |

[PATCH -V2 02/26] powerpc: Save DAR and DSISR in pt_regs on MCE

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" We were not saving DAR and DSISR on MCE. Save then and also print the values along with exception details in xmon. Acked-by: Paul Mackerras Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/kernel/exceptions-64s.S |9 + arch/powerpc/xmon/xmon.c

[PATCH -V2 01/26] powerpc: Use signed formatting when printing error

2013-03-05 Thread Aneesh Kumar K.V
From: "Aneesh Kumar K.V" PAPR defines these errors as negative values. So print them accordingly for easy debugging. Acked-by: Paul Mackerras Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/platforms/pseries/lpar.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/p

[PATCH -V2 00/26]T HP support for PPC64

2013-03-05 Thread Aneesh Kumar K.V
Hi, This patchset adds transparent huge page support for PPC64. TODO: * ppc64 KVM related changes * powernv still doesn't boot * hash preload support in update_mmu_cache_pmd Some numbers: The latency measurements code from Anton found at http://ozlabs.org/~anton/junkcode/latency2001.c THP dis

Re: [PATCH 2/3] irq: Add hw continuous IRQs map to virtual continuous IRQs support

2013-03-05 Thread Mike Qiu
于 2013/3/6 11:54, Michael Ellerman 写道: On Tue, Mar 05, 2013 at 03:19:57PM +0800, Mike Qiu wrote: 于 2013/3/5 10:23, Michael Ellerman 写道: On Tue, Jan 15, 2013 at 03:38:55PM +0800, Mike Qiu wrote: Adding a function irq_create_mapping_many() which can associate multiple MSIs to a continous irq map

3.9-rc1 powerpc ptrace.c: 'brk.len' is used uninitialized

2013-03-05 Thread Philippe De Muyter
Hello Michael, bisect tells me that since your commit 9422de3e953d0e60eb95f5430a9dd803eec1c6d7 "powerpc: Hardware breakpoints rewrite to handle non DABR breakpoint registers", compiling linux fails with : cc1: warnings being treated as errors arch/powerpc/kernel/ptrace.c: In function 'arch_p

Re: [PATCH 5/6][v4]: perf: Create a sysfs entry for Power event format

2013-03-05 Thread Sukadev Bhattiprolu
Michael Ellerman [mich...@ellerman.id.au] wrote: | I suspect Arnaldo was either waiting for an ACK from Ben, or was | expecting Ben to take it? Arnaldo, here is an updated patch. If it is acked by Paul Mackerras, Michael Ellerman or Ben, will you add it to your tree so the whole patchset comes fro

Re: [PATCH 2/3] irq: Add hw continuous IRQs map to virtual continuous IRQs support

2013-03-05 Thread Michael Ellerman
On Wed, Mar 06, 2013 at 01:34:58PM +0800, Mike Qiu wrote: > 于 2013/3/6 11:54, Michael Ellerman 写道: > >On Tue, Mar 05, 2013 at 03:19:57PM +0800, Mike Qiu wrote: > >>于 2013/3/5 10:23, Michael Ellerman 写道: > >>>On Tue, Jan 15, 2013 at 03:38:55PM +0800, Mike Qiu wrote: > diff --git a/kernel/irq/irq

Re: [PATCH -V1 06/24] powerpc: Reduce PTE table memory wastage

2013-03-05 Thread Aneesh Kumar K.V
Paul Mackerras writes: > On Mon, Mar 04, 2013 at 04:28:42PM +0530, Aneesh Kumar K.V wrote: >> The last one that ends up doing atomic_xor_bits which cause the mapcount >> to go zero, will take the page off the list and free the page. > > No, look at the example again. page_table_free_rcu() won't

Re: [PATCH -V1 09/24] powerpc: Decode the pte-lp-encoding bits correctly.

2013-03-05 Thread Aneesh Kumar K.V
Paul Mackerras writes: > On Mon, Mar 04, 2013 at 05:11:53PM +0530, Aneesh Kumar K.V wrote: >> Paul Mackerras writes: >> >> +static inline int hpte_actual_psize(struct hash_pte *hptep, int psize) >> >> +{ >> >> + unsigned int mask; >> >> + int i, penc, shift; >> >> + /* Look at the 8 bit LP value

Re: [PATCH -V1 07/24] powerpc: Add size argument to pgtable_cache_add

2013-03-05 Thread Aneesh Kumar K.V
Paul Mackerras writes: > On Mon, Mar 04, 2013 at 04:32:24PM +0530, Aneesh Kumar K.V wrote: >> >> Now with table_size argument, the first arg is no more the shift value, >> rather it is index into the array. Hence i changed the variable name. I >> will split that patch to make it easy for review.

Re: [PATCH] powerpc/powernv: Fix next available MSI IRQ

2013-03-05 Thread Gavin Shan
On Wed, Mar 06, 2013 at 02:24:54PM +1100, Michael Ellerman wrote: >On Tue, Mar 05, 2013 at 02:59:16PM +0800, Gavin Shan wrote: >> The allocation of MSI is implemented based on bitmap and working >> like the mechanism of strict round through the traced next available >> cursor. However, the next ava

Re: [PATCH] ppc32: Fix compile of sha1-powerpc-asm.S

2013-03-05 Thread Michael Ellerman
On Mon, Mar 04, 2013 at 05:23:14PM -0800, Christian Kujau wrote: > On Tue, 26 Feb 2013 at 13:20, Tony Breeds wrote: > > When building with CRYPTO_SHA1_PPC enabled we fail with: > > --- > > powerpc/crypto/sha1-powerpc-asm.S: Assembler messages: > > powerpc/crypto/sha1-powerpc-asm.S:116: Error: can't

Re: [PATCH -V1 06/24] powerpc: Reduce PTE table memory wastage

2013-03-05 Thread Aneesh Kumar K.V
Paul Mackerras writes: > On Mon, Mar 04, 2013 at 04:28:42PM +0530, Aneesh Kumar K.V wrote: >> Paul Mackerras writes: >> >> > The other general comment I have is that it's not really clear when a >> > page will be on the mm->context.pgtable_list and when it won't. I >> > would like to see an in

Re: [PATCH -V1 06/24] powerpc: Reduce PTE table memory wastage

2013-03-05 Thread Aneesh Kumar K.V
Benjamin Herrenschmidt writes: > On Mon, 2013-03-04 at 16:28 +0530, Aneesh Kumar K.V wrote: >> I added the below comment when initializing the list. >> >> +#ifdef CONFIG_PPC_64K_PAGES >> + /* >> +* Used to support 4K PTE fragment. The pages are added to list, >> +* when we

Re: [PATCH 2/3] irq: Add hw continuous IRQs map to virtual continuous IRQs support

2013-03-05 Thread Michael Ellerman
On Tue, Mar 05, 2013 at 03:19:57PM +0800, Mike Qiu wrote: > 于 2013/3/5 10:23, Michael Ellerman 写道: > >On Tue, Jan 15, 2013 at 03:38:55PM +0800, Mike Qiu wrote: > >>Adding a function irq_create_mapping_many() which can associate > >>multiple MSIs to a continous irq mapping. > >> > >>This is needed t

[PATCH 2/2] powerpc: Setup in HFSCR for POWER8

2013-03-05 Thread Michael Neuling
Setup the HFSCR (Hypervisor Facility Status and Control Register) for POWER8 when running HV=1. The HFSCR is the same as the FSCR except it's for hypervisors. It controls the available of various facilities in OS and userspace levels. It also indicates the cause of a hypervisor facility unavaila

[PATCH 1/2] powerpc: Add HFSCR SPR definitions

2013-03-05 Thread Michael Neuling
Add SPR number and bit definitions for the HFSCR (Hypervisor Facility Status and Control Register). Signed-off-by: Michael Neuling --- arch/powerpc/include/asm/reg.h |6 ++ 1 file changed, 6 insertions(+) diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/reg.h index

[PATCH 0/2] powerpc: HFSCR enablement for POWER8

2013-03-05 Thread Michael Neuling
Benh, This small series adds support for the HFSCR (Hypervisor Facility Status & Control Register) in POWER8. It just sets the bits we know about at this stage. This is useful only when MSR HV=1. The HFSCR is the same as the FSCR except it's for hypervisors. It controls the available of vario

Re: [PATCH] powerpc/powernv: Fix next available MSI IRQ

2013-03-05 Thread Michael Ellerman
On Tue, Mar 05, 2013 at 02:59:16PM +0800, Gavin Shan wrote: > The allocation of MSI is implemented based on bitmap and working > like the mechanism of strict round through the traced next available > cursor. However, the next available MSI is never updated in current > implementation. The patch fix

Re: [PATCH 5/8] powerpc/fsl-booke: Add initial silicon device tree for

2013-03-05 Thread Roy Zang
On 03/06/2013 07:15 AM, Kumar Gala wrote: * Thread support on e6500 * Proper PAMU topology information * DPAA related nodes (Qman, Bman, Fman, Rman, DCE) * Prefetch Manager * Thermal monitor unit * Interlaken Signed-off-by: Roy Zang Signed-off-by: Minghuan Lian Signed-off-by: Haiying Wang Signed

[PATCH 2/2] powerpc: Setup in HFSCR for POWER8

2013-03-05 Thread Michael Neuling
Setup the HFSCR (Hypervisor Facility Status and Control Register) for POWER8 when running HV=1. The HFSCR is the same as the FSCR except but for hypervisors. This patch sets the facilities Linux knows about incase the firmware doesn't. Signed-off-by: Michael Neuling --- arch/powerpc/kernel/cpu

[PATCH 1/2] powerpc: Add HFSCR SPR definitions

2013-03-05 Thread Michael Neuling
Add SPR number and bit definitions for the HFSCR (Hypervisor Facility Status and Control Register). Signed-off-by: Michael Neuling --- arch/powerpc/include/asm/reg.h |6 ++ 1 file changed, 6 insertions(+) diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/reg.h index

[PATCH 0/2] powerpc: HFSCR enablement for POWER8

2013-03-05 Thread Michael Neuling
Benh, This small series adds support for the HFSCR (Hypervisor Facility Status & Control Register) in POWER8. It just sets the bits we know about at this stage. This is useful only when MSR HV=1. Mikey ___ Linuxppc-dev mailing list Linuxppc-dev@lists

Re: [PATCH 5/8] powerpc/fsl-booke: Add initial silicon device tree for

2013-03-05 Thread Scott Wood
On 03/05/2013 05:15:57 PM, Kumar Gala wrote: Enable a baseline T4240 SoC to boot. There are several things missing from the device trees for T4240: * Thread support on e6500 Why did threads get removed from the device tree? It's supposed to describe hardware, not what Linux currently suppo

[PATCH 8/8] powerpc/85xx: Update corenet64_smp_defconfig for T4240

2013-03-05 Thread Kumar Gala
* Add support for up to 24 cores on T4240 (includes threads) * Enable AltiVec support (on T4240) * Add T4240QDS board into build * Other changes are due to general kernel update of defconfig Signed-off-by: Kumar Gala --- arch/powerpc/configs/corenet64_smp_defconfig |9 - 1 file chang

[PATCH 7/8] powerpc/fsl-booke: Add initial T4240QDS board support

2013-03-05 Thread Kumar Gala
Some minor changes to the common corenet_ds.c code are needed to support the T4240QDS: * Add support for "fsl,qoriq-pcie-v3.0" controller * Bump max # of IRQs to 512 (T4240 supports more interrupts than previous SoCs). Signed-off-by: Kumar Gala --- arch/powerpc/platforms/85xx/Kconfig |

[PATCH 6/8] powerpc/fsl-booke: Add initial T4240QDS board device

2013-03-05 Thread Kumar Gala
Signed-off-by: Minghuan Lian Signed-off-by: Roy Zang Signed-off-by: Prabhakar Kushwaha Signed-off-by: Andy Fleming Signed-off-by: Shaohui Xie Signed-off-by: Prabhakar Kushwaha Signed-off-by: Scott Wood Signed-off-by: Kumar Gala --- arch/powerpc/boot/dts/t4240qds.dts | 220

[PATCH 5/8] powerpc/fsl-booke: Add initial silicon device tree for

2013-03-05 Thread Kumar Gala
Enable a baseline T4240 SoC to boot. There are several things missing from the device trees for T4240: * Thread support on e6500 * Proper PAMU topology information * DPAA related nodes (Qman, Bman, Fman, Rman, DCE) * Prefetch Manager * Thermal monitor unit * Interlaken Signed-off-by: Roy Zang S

[PATCH 1/8] powerpc/85xx: Added SEC-5.0 device tree.

2013-03-05 Thread Kumar Gala
From: Vakul Garg Add device tree for SEC (crypto engine) version 5.0 used on T4240. Signed-off-by: Vakul Garg Signed-off-by: Andy Fleming Signed-off-by: Kumar Gala --- arch/powerpc/boot/dts/fsl/qoriq-sec5.0-0.dtsi | 109 + 1 file changed, 109 insertions(+) create mo

[PATCH 4/8] powerpc/85xx: Add AltiVec support for e6500

2013-03-05 Thread Kumar Gala
The e6500 core adds support for AltiVec on a Book-E class processor. Connect up all the various exception handling code and build config mechanisms to allow user spaces apps to utilize AltiVec. Signed-off-by: Kumar Gala --- arch/powerpc/include/asm/cputable.h |2 +- arch/powerpc/includ

[PATCH 2/8] powerpc/85xx: Add support for FSL PCIe controller v3.0

2013-03-05 Thread Kumar Gala
From: Roy ZANG The T4240 utilizes a new PCIe controller block that has some minor programming model differences from previous versions. The major one that impacts initialization is how we determine the link state. On the 3.x controllers we have a memory mapped SoC register instead of a PCI conf

[PATCH 3/8] powerpc/fsl-booke: Support detection of page sizes on

2013-03-05 Thread Kumar Gala
The e6500 core used on T4240 and B4860 SoCs from FSL implements MMUv2 of the Power Book-E Architecture. However there are some minor differences between it and other Book-E implementations. Add support to parse SPRN_TLB1PS for the variable page sizes supported. In the future this should be expand

[PATCH][v2] powerpc: add missing deo arch category to e500mc/e5500 dts

2013-03-05 Thread Stuart Yoder
From: Stuart Yoder Signed-off-by: Stuart Yoder --- -v2 -deo is EREF specific, changed name of property arch/powerpc/boot/dts/fsl/e500mc_power_isa.dtsi |1 + arch/powerpc/boot/dts/fsl/e5500_power_isa.dtsi |1 + 2 files changed, 2 insertions(+) diff --git a/arch/powerpc/boot/dts/fs

[PATCH][v3] powerpc/e6500: Add architecture categories for e6500 cores

2013-03-05 Thread Stuart Yoder
From: Stuart Yoder -also define a binding for fsl,eref-* properties Signed-off-by: Stuart Yoder --- -v3 -converted EREF specific properties to fsl,eref-* .../devicetree/bindings/powerpc/fsl/cpus.txt | 21 +++ arch/powerpc/boot/dts/fsl/e6500_power_isa.dtsi | 65 ++

Re: [PATCH][v2] powerpc/e6500: Add Power ISA properties for e6500 cores

2013-03-05 Thread Scott Wood
On 03/05/2013 02:37:42 PM, Yoder Stuart-B08248 wrote: > -Original Message- > From: Wood Scott-B07421 > Sent: Tuesday, March 05, 2013 2:29 PM > To: Yoder Stuart-B08248 > Cc: ga...@kernel.crashing.org; linuxppc-dev@lists.ozlabs.org; Yoder Stuart-B08248 > Subject: Re: [PATCH][v2] powerpc

RE: [PATCH][v2] powerpc/e6500: Add Power ISA properties for e6500 cores

2013-03-05 Thread Yoder Stuart-B08248
> -Original Message- > From: Wood Scott-B07421 > Sent: Tuesday, March 05, 2013 2:29 PM > To: Yoder Stuart-B08248 > Cc: ga...@kernel.crashing.org; linuxppc-dev@lists.ozlabs.org; Yoder > Stuart-B08248 > Subject: Re: [PATCH][v2] powerpc/e6500: Add Power ISA properties for e6500 > cores >

Re: [PATCH] powerpc: add missing deo ISA category to e500mc/e5500 dts

2013-03-05 Thread Scott Wood
On 03/05/2013 02:23:36 PM, Stuart Yoder wrote: From: Stuart Yoder Signed-off-by: Stuart Yoder --- arch/powerpc/boot/dts/fsl/e500mc_power_isa.dtsi |1 + arch/powerpc/boot/dts/fsl/e5500_power_isa.dtsi |1 + 2 files changed, 2 insertions(+) diff --git a/arch/powerpc/boot/dts/fsl/e500mc

Re: [PATCH][v2] powerpc/e6500: Add Power ISA properties for e6500 cores

2013-03-05 Thread Scott Wood
On 03/05/2013 02:16:42 PM, Stuart Yoder wrote: From: Stuart Yoder Signed-off-by: Stuart Yoder --- -v2 -fix some typos arch/powerpc/boot/dts/fsl/e6500_power_isa.dtsi | 65 1 file changed, 65 insertions(+) create mode 100644 arch/powerpc/boot/dts/fsl/e6500_pow

[PATCH] powerpc: add missing deo ISA category to e500mc/e5500 dts

2013-03-05 Thread Stuart Yoder
From: Stuart Yoder Signed-off-by: Stuart Yoder --- arch/powerpc/boot/dts/fsl/e500mc_power_isa.dtsi |1 + arch/powerpc/boot/dts/fsl/e5500_power_isa.dtsi |1 + 2 files changed, 2 insertions(+) diff --git a/arch/powerpc/boot/dts/fsl/e500mc_power_isa.dtsi b/arch/powerpc/boot/dts/fsl/e500

[PATCH][v2] powerpc/e6500: Add Power ISA properties for e6500 cores

2013-03-05 Thread Stuart Yoder
From: Stuart Yoder Signed-off-by: Stuart Yoder --- -v2 -fix some typos arch/powerpc/boot/dts/fsl/e6500_power_isa.dtsi | 65 1 file changed, 65 insertions(+) create mode 100644 arch/powerpc/boot/dts/fsl/e6500_power_isa.dtsi diff --git a/arch/powerpc/boot/dts/fsl/

Re: [PATCH] powerpc/e6500: Add Power ISA properties for e6500 cores

2013-03-05 Thread Scott Wood
On 03/05/2013 01:24:55 PM, Stuart Yoder wrote: From: Stuart Yoder Signed-off-by: Stuart Yoder --- arch/powerpc/boot/dts/fsl/e6500_power_isa.dtsi | 66 1 file changed, 66 insertions(+) create mode 100644 arch/powerpc/boot/dts/fsl/e6500_power_isa.dtsi diff --git

[PATCH] powerpc/e6500: Add Power ISA properties for e6500 cores

2013-03-05 Thread Stuart Yoder
From: Stuart Yoder Signed-off-by: Stuart Yoder --- arch/powerpc/boot/dts/fsl/e6500_power_isa.dtsi | 66 1 file changed, 66 insertions(+) create mode 100644 arch/powerpc/boot/dts/fsl/e6500_power_isa.dtsi diff --git a/arch/powerpc/boot/dts/fsl/e6500_power_isa.dtsi b/

Re: [PATCH V4] powerpc/85xx: Add machine check handler to fix PCIe erratum on mpc85xx

2013-03-05 Thread Scott Wood
On 03/05/2013 04:12:30 AM, Jia Hongtao-B38951 wrote: > -Original Message- > From: Wood Scott-B07421 > Sent: Tuesday, March 05, 2013 7:46 AM > To: Stuart Yoder > Cc: Jia Hongtao-B38951; linuxppc-dev@lists.ozlabs.org; Kumar Gala > Subject: Re: [PATCH V4] powerpc/85xx: Add machine check ha

Re: [PATCH v6 04/46] percpu_rwlock: Implement the core design of Per-CPU Reader-Writer Locks

2013-03-05 Thread Srivatsa S. Bhat
Hi Lai, On 03/05/2013 09:55 PM, Lai Jiangshan wrote: > Hi, Srivatsa, > > I'm sorry again, I delayed your works. > No, you didn't :-) I have been busy with some internal work lately, so I haven't been able to go through the recent discussions and review the new code carefully.. I'll get to it as

Re: [PATCH V2] lglock: add read-preference local-global rwlock

2013-03-05 Thread Srivatsa S. Bhat
On 03/05/2013 09:11 PM, Lai Jiangshan wrote: > On 03/03/13 01:11, Srivatsa S. Bhat wrote: >> On 03/02/2013 06:44 PM, Lai Jiangshan wrote: >>> From 345a7a75c314ff567be48983e0892bc69c4452e7 Mon Sep 17 00:00:00 2001 >>> From: Lai Jiangshan >>> Date: Sat, 2 Mar 2013 20:33:14 +0800 >>> Subject: [PATCH]

Re: [PATCH V2] lglock: add read-preference local-global rwlock

2013-03-05 Thread Oleg Nesterov
On 03/05, Lai Jiangshan wrote: > > On 03/03/13 01:20, Oleg Nesterov wrote: > > On 03/02, Lai Jiangshan wrote: > >> > >> +void lg_rwlock_local_read_unlock(struct lgrwlock *lgrw) > >> +{ > >> + switch (__this_cpu_read(*lgrw->reader_refcnt)) { > >> + case 1: > >> + __this_cpu_write(*lgrw->r

Re: [PATCH] lglock: add read-preference local-global rwlock

2013-03-05 Thread Oleg Nesterov
On 03/05, Lai Jiangshan wrote: > > On 03/03/13 01:06, Oleg Nesterov wrote: > > On 03/02, Michel Lespinasse wrote: > >> > >> My version would be slower if it needs to take the > >> slow path in a reentrant way, but I'm not sure it matters either :) > > > > I'd say, this doesn't matter at all, simply

Re: [PATCH] lglock: add read-preference local-global rwlock

2013-03-05 Thread Michel Lespinasse
On Tue, Mar 5, 2013 at 7:54 AM, Lai Jiangshan wrote: > On 03/03/13 01:06, Oleg Nesterov wrote: >> On 03/02, Michel Lespinasse wrote: >>> >>> My version would be slower if it needs to take the >>> slow path in a reentrant way, but I'm not sure it matters either :) >> >> I'd say, this doesn't matter

Re: [PATCH] lglock: add read-preference local-global rwlock

2013-03-05 Thread Lai Jiangshan
On 03/03/13 01:06, Oleg Nesterov wrote: > On 03/02, Michel Lespinasse wrote: >> >> My version would be slower if it needs to take the >> slow path in a reentrant way, but I'm not sure it matters either :) > > I'd say, this doesn't matter at all, simply because this can only happen > if we race wit

Re: [PATCH v6 04/46] percpu_rwlock: Implement the core design of Per-CPU Reader-Writer Locks

2013-03-05 Thread Lai Jiangshan
On 02/03/13 03:47, Srivatsa S. Bhat wrote: > On 03/01/2013 11:20 PM, Lai Jiangshan wrote: >> On 28/02/13 05:19, Srivatsa S. Bhat wrote: >>> On 02/27/2013 06:03 AM, Lai Jiangshan wrote: On Wed, Feb 27, 2013 at 3:30 AM, Srivatsa S. Bhat wrote: > On 02/26/2013 09:55 PM, Lai Jiangshan wr

Re: [PATCH V2] lglock: add read-preference local-global rwlock

2013-03-05 Thread Michel Lespinasse
Hi Lai, Just a few comments about your v2 proposal. Hopefully you'll catch these before you send out v3 :) - I would prefer reader_refcnt to be unsigned int instead of unsigned long - I would like some comment to indicate that lgrwlocks don't have reader-writer fairness and are thus somewhat di

[PATCH] powerpc/85xx: Move ePAPR paravirt initialization earlier

2013-03-05 Thread Laurentiu Tudor
From: Tudor Laurentiu The ePAPR para-virtualization needs to happen very early otherwise the bytechannel based console will silently drop some of the early boot messages. Before this patch, this is how the kernel log started: - > Brought up 2

[PATCH] powerpc/watchdog: Don't enable interrupt on PPC64 BookE

2013-03-05 Thread Laurentiu Tudor
From: Tudor Laurentiu Critical interrupts are not handled on PPC64 BookE machines, so when the first watchdog interrupt fires the machine will freeze without a warning until it's rebooted by the second watchdog trigger. Plus, the interrupt isn't used anyway since the driver expects a usermode app

Re: [PATCH V2] lglock: add read-preference local-global rwlock

2013-03-05 Thread Lai Jiangshan
On 03/03/13 01:11, Srivatsa S. Bhat wrote: > On 03/02/2013 06:44 PM, Lai Jiangshan wrote: >> From 345a7a75c314ff567be48983e0892bc69c4452e7 Mon Sep 17 00:00:00 2001 >> From: Lai Jiangshan >> Date: Sat, 2 Mar 2013 20:33:14 +0800 >> Subject: [PATCH] lglock: add read-preference local-global rwlock >>

Re: [PATCH V2] lglock: add read-preference local-global rwlock

2013-03-05 Thread Lai Jiangshan
On 03/03/13 01:20, Oleg Nesterov wrote: > On 03/02, Lai Jiangshan wrote: >> >> +void lg_rwlock_local_read_unlock(struct lgrwlock *lgrw) >> +{ >> +switch (__this_cpu_read(*lgrw->reader_refcnt)) { >> +case 1: >> +__this_cpu_write(*lgrw->reader_refcnt, 0); >> +lg_local_

[PATCH 4/4][v2] Basic configuration module for Le88266 Zarlink SLIC

2013-03-05 Thread Sandeep Singh
- Basic driver which does minimum intialization of the Le88266 SLIC device. - The code was originally borrowed from Zarlink driver implementation. - It is not full fledged SLIC driver code, it just does basic initialization which is required to setup a voice data path between channels. Thi

[PATCH 3/4][v2] Added TDM device support and Freescale Starlite driver

2013-03-05 Thread Sandeep Singh
Freescale TDM controller consists of a TDM module supporting 128 channels running at up to 50 Mbps with 8-bit and 16-bit word size. The TDM bus connects gluelessly to most T1/E1 frames as well as to common buses such as the H.110, SCAS, and MVIP. TDM also supports an I2S mode. The TDM module operat

[PATCH 2/4][v2] TDM Framework

2013-03-05 Thread Sandeep Singh
TDM Framework is an attempt to provide a platform independent layer which can offer a standard interface for TDM access to different client modules. Beneath, the framework layer can house different types of TDM drivers to handle various TDM devices, the hardware intricacies of the devices bei

[PATCH 1/4][v2] Adding Documentation for TDM

2013-03-05 Thread Sandeep Singh
tdm-summary.txt contains general description about TDM. tdm-framework.txt contains specific description of TDM framework. Signed-off-by: Sandeep Singh Signed-off-by: Poonam Aggrwal --- Documentation/tdm/tdm-framework.txt | 264 +++ Documentation/tdm/tdm-summar

RE: [PATCH V4] powerpc/85xx: Add machine check handler to fix PCIe erratum on mpc85xx

2013-03-05 Thread Jia Hongtao-B38951
> -Original Message- > From: Wood Scott-B07421 > Sent: Tuesday, March 05, 2013 7:46 AM > To: Stuart Yoder > Cc: Jia Hongtao-B38951; linuxppc-dev@lists.ozlabs.org; Kumar Gala > Subject: Re: [PATCH V4] powerpc/85xx: Add machine check handler to fix > PCIe erratum on mpc85xx > > On 03/04/20

RE: [PATCH V4] powerpc/85xx: Add machine check handler to fix PCIe erratum on mpc85xx

2013-03-05 Thread Jia Hongtao-B38951
> -Original Message- > From: David Laight [mailto:david.lai...@aculab.com] > Sent: Tuesday, March 05, 2013 1:16 AM > To: Jia Hongtao-B38951; linuxppc-dev@lists.ozlabs.org; > ga...@kernel.crashing.org > Cc: Wood Scott-B07421 > Subject: RE: [PATCH V4] powerpc/85xx: Add machine check handler

Re: [PATCH] drivers/tty/hvc: using strlcpy instead of strncpy

2013-03-05 Thread Jiri Slaby
On 03/05/2013 02:58 AM, Chen Gang wrote: > 于 2013年02月28日 21:47, Jiri Slaby 写道: when strlen(&pi->location_code[0]) == HVCS_CLC_LENGTH + 2 >> It cannot, pi->location_code is defined as char[HVCS_CLC_LENGTH + 1]. >> > > really, it is, I did not notice it. > > but I still prefer to modify