[PATCH] DMA: Freescale: change BWC from 256 bytes to 1024 bytes

2014-01-15 Thread hongbo.zhang
From: Hongbo Zhang Freescale DMA has a feature of BandWidth Control (ab. BWC), which is currently 256 bytes and should be changed to 1024 bytes for best DMA throughput. Changing BWC from 256 to 1024 will improve DMA performance much, in cases whatever one channel is running or multi channels are

[PATCH 7/7] DMA: Freescale: add suspend resume functions for DMA driver

2014-01-15 Thread hongbo.zhang
From: Hongbo Zhang This patch adds suspend resume functions for Freescale DMA driver. .prepare callback is used to stop further descriptors from being added into the pending queue, and also issue pending queues into execution if there is any. .suspend callback makes sure all the pending jobs are

[PATCH 5/7] DMA: Freescale: change descriptor release process for supporting async_tx

2014-01-15 Thread hongbo.zhang
From: Hongbo Zhang Fix the potential risk when enable config NET_DMA and ASYNC_TX. Async_tx is lack of support in current release process of dma descriptor, all descriptors will be released whatever is acked or no-acked by async_tx, so there is a potential race condition when dma engine is uesd b

[PATCH 4/7] DMA: Freescale: move functions to avoid forward declarations

2014-01-15 Thread hongbo.zhang
From: Hongbo Zhang These functions will be modified in the next patch in the series. By moving the function in a patch separate from the changes, it will make review easier. Signed-off-by: Hongbo Zhang Signed-off-by: Qiang Liu --- drivers/dma/fsldma.c | 192 +-

[PATCH 6/7] DMA: Freescale: use spin_lock_bh instead of spin_lock_irqsave

2014-01-15 Thread hongbo.zhang
From: Hongbo Zhang The usage of spin_lock_irqsave() is a stronger locking mechanism than is required throughout the driver. The minimum locking required should be used instead. Interrupts will be turned off and context will be saved, it is unnecessary to use irqsave. This patch changes all insta

[PATCH 1/7] DMA: Freescale: unify register access methods

2014-01-15 Thread hongbo.zhang
From: Hongbo Zhang Methods of accessing DMA contorller registers are inconsistent, some registers are accessed by DMA_IN/OUT directly, while others are accessed by functions get/set_* which are wrappers of DMA_IN/OUT, and even for the BCR register, it is read by get_bcr but written by DMA_OUT. Th

[PATCH 3/7] DMA: Freescale: add fsl_dma_free_descriptor() to reduce code duplication

2014-01-15 Thread hongbo.zhang
From: Hongbo Zhang There are several places where descriptors are freed using identical code. This patch puts this code into a function to reduce code duplication. Signed-off-by: Hongbo Zhang Signed-off-by: Qiang Liu --- drivers/dma/fsldma.c | 38 -- 1 fi

[PATCH 2/7] DMA: Freescale: remove attribute DMA_INTERRUPT of dmaengine

2014-01-15 Thread hongbo.zhang
From: Hongbo Zhang Delete attribute DMA_INTERRUPT because fsldma doesn't support this function, exception will be thrown if talitos is used to offload xor at the same time. Signed-off-by: Hongbo Zhang Signed-off-by: Qiang Liu --- drivers/dma/fsldma.c | 31 --- 1

[PATCH 0/7] DMA: Freescale: driver cleanups and enhancements

2014-01-15 Thread hongbo.zhang
From: Hongbo Zhang Hi Vinod Koul and Dan Williams, Please have a look at these patches. Note that patch 2~6 had beed sent out for upstream before, but were together with other storage patches at that time, that was not easy for being reviewed and merged, so I send them separately this time. Tha

[PATCH 2/2][v3] powerpc/config: Enable memory driver

2014-01-15 Thread Prabhakar Kushwaha
As Freescale IFC controller has been moved to driver to driver/memory. So enable memory driver in powerpc config Signed-off-by: Prabhakar Kushwaha --- Changes for v2: Sending as it is Changes for v3: Sending as it is arch/powerpc/configs/corenet32_smp_defconfig |1 + arch/powerpc/configs

[PATCH 1/2][v3] driver/memory:Move Freescale IFC driver to a common driver

2014-01-15 Thread Prabhakar Kushwaha
Freescale IFC controller has been used for mpc8xxx. It will be used for ARM-based SoC as well. This patch moves the driver to driver/memory and fix the header file includes. Also remove module_platform_driver() and instead call platform_driver_register() from subsys_initcall() to make sure t

Re: [PATCH 2/3] powerpc/85xx: Provide two functions to save/restore the core registers

2014-01-15 Thread Scott Wood
On Tue, 2014-01-14 at 21:30 -0600, Wang Dongsheng-B40534 wrote: > > > -Original Message- > > From: Wood Scott-B07421 > > Sent: Wednesday, January 15, 2014 7:51 AM > > To: Wang Dongsheng-B40534 > > Cc: b...@kernel.crashing.org; Zhao Chenhui-B35336; an...@enomsg.org; > > linuxppc- > > d...@

Re: [PATCH 3/3] powerpc/fsl: Use the new interface to save or restore registers

2014-01-15 Thread Scott Wood
On Tue, 2014-01-14 at 20:57 -0600, Wang Dongsheng-B40534 wrote: > > > -Original Message- > > From: Wood Scott-B07421 > > Sent: Wednesday, January 15, 2014 7:30 AM > > To: Wang Dongsheng-B40534 > > Cc: b...@kernel.crashing.org; Zhao Chenhui-B35336; an...@enomsg.org; > > linuxppc- > > d...@

Re: [PATCH V5 0/8] cpuidle/ppc: Enable deep idle states on PowerNV

2014-01-15 Thread Preeti U Murthy
Hi Paul, On 01/15/2014 08:59 PM, Paul Gortmaker wrote: > On 14-01-15 03:07 AM, Preeti U Murthy wrote: > > [...] > >> >> This patchset is based on mainline commit-id:8ae516aa8b8161254d3, and the > > I figured I'd give this a quick sanity build test for a few > configs, but v3.13-rc1-141-g8ae516

Re: powerpc/powernv: Call OPAL sync before kexec'ing

2014-01-15 Thread Benjamin Herrenschmidt
On Thu, 2014-01-16 at 11:58 +1100, Michael Ellerman wrote: > On Wed, 2014-01-15 at 17:02 +1100, Benjamin Herrenschmidt wrote: > > From: Vasant Hegde > > > > Its possible that OPAL may be writing to host memory during > > kexec (like dump retrieve scenario). In this situation we might > > end

Re: powerpc/powernv: Call OPAL sync before kexec'ing

2014-01-15 Thread Michael Ellerman
On Wed, 2014-01-15 at 17:02 +1100, Benjamin Herrenschmidt wrote: > From: Vasant Hegde > > Its possible that OPAL may be writing to host memory during > kexec (like dump retrieve scenario). In this situation we might > end up corrupting host memory. Are we happy with that happening during kdu

[PATCH v2] drivers/tty/hvc: don't use module_init in non-modular hyp. console code

2014-01-15 Thread Paul Gortmaker
The HVC_OPAL/RTAS/UDBG/XEN options are all bool, and hence their support is either present or absent. It will never be modular, so using module_init as an alias for __initcall is rather misleading. Fix this up now, so that we can relocate module_init from init.h into module.h in the future. If w

[PATCH] drivers/tty/hvc: don't use module_init in non-modular hyp. console code

2014-01-15 Thread Paul Gortmaker
The HVC_OPAL/RTAS/UDBG options are all bool, and hence their support is either present or absent. It will never be modular, so using module_init as an alias for __initcall is rather misleading. Fix this up now, so that we can relocate module_init from init.h into module.h in the future. If we do

Please pull 'next' branch of 5xxx tree

2014-01-15 Thread Anatolij Gustschin
Hi Ben ! please pull mpc5xxx patches for v3.14: Switch mpc512x to the common clock framework and adapt mpc512x drivers to use the new clock driver. Old PPC_CLOCK code is removed entirely since there are no users any more. All these patches have been in linux-next for more then two weeks now. Th

[PATCH] powerpc: mm: fix mmap errno when MAP_FIXED is set and mapping exceeds the allowed address space

2014-01-15 Thread Jerome Marchand
According to Posix, if MAP_FIXED is specified mmap shall set ENOMEM if the requested mapping exceeds the allowed range for address space of the process. The generic code set it right, but the specific powerpc slice_get_unmapped_area() function currently returns -EINVAL in that case. This patch corr

Re: [PATCH V5 0/8] cpuidle/ppc: Enable deep idle states on PowerNV

2014-01-15 Thread Paul Gortmaker
On 14-01-15 03:07 AM, Preeti U Murthy wrote: [...] > > This patchset is based on mainline commit-id:8ae516aa8b8161254d3, and the I figured I'd give this a quick sanity build test for a few configs, but v3.13-rc1-141-g8ae516aa8b81 seems too old; Ben's ppc next branch is at v3.13-rc1-160-gfac515

Re: [PATCH 1/2][v2] driver/memory:Move Freescale IFC driver to a common driver

2014-01-15 Thread Arnd Bergmann
On Wednesday 15 January 2014, Prabhakar Kushwaha wrote: > Freescale IFC controller has been used for mpc8xxx. It will be used > for ARM-based SoC as well. This patch moves the driver to driver/memory > and fix the header file includes. > > Also remove module_platform_driver() and instead call > p

[PATCH 2/2][v2] powerpc/config: Enable memory driver

2014-01-15 Thread Prabhakar Kushwaha
As Freescale IFC controller has been moved to driver to driver/memory. So enable memory driver in powerpc config Signed-off-by: Prabhakar Kushwaha --- changes for v2: Sending as it is arch/powerpc/configs/corenet32_smp_defconfig |1 + arch/powerpc/configs/corenet64_smp_defconfig |1 +

[PATCH 1/2][v2] driver/memory:Move Freescale IFC driver to a common driver

2014-01-15 Thread Prabhakar Kushwaha
Freescale IFC controller has been used for mpc8xxx. It will be used for ARM-based SoC as well. This patch moves the driver to driver/memory and fix the header file includes. Also remove module_platform_driver() and instead call platform_driver_register() from subsys_initcall() to make sure this m

Re: Disable sleep states on P7+

2014-01-15 Thread Deepthi Dharwar
Hi Steven, On 01/14/2014 08:06 PM, Steven Pratt wrote: > I am looking for info on when and how we are able to disable power saving > features of current (P7, P7+) chips in order to reduce latency. This is often > done in latency sensitive applications when power consumption is not an issue. On

Re: [git pull] Please pull powerpc.git merge branch

2014-01-15 Thread Benjamin Herrenschmidt
On Wed, 2014-01-15 at 15:05 +0700, Linus Torvalds wrote: > On Wed, Jan 15, 2014 at 12:01 PM, Benjamin Herrenschmidt > wrote: > > > > My original intend was to put it in powerpc-next and then shoot it to > > stable, but it got a tad annoying (due to churn it needs to be applied > > at least on rc4

[PATCH V5 8/8] cpuidle/powernv: Parse device tree to setup idle states

2014-01-15 Thread Preeti U Murthy
Add deep idle states such as nap and fast sleep to the cpuidle state table only if they are discovered from the device tree during cpuidle initialization. Signed-off-by: Preeti U Murthy --- drivers/cpuidle/cpuidle-powernv.c | 81 + 1 file changed, 64 insert

[PATCH V5 6/8] time/cpuidle: Support in tick broadcast framework in the absence of external clock device

2014-01-15 Thread Preeti U Murthy
On some architectures, in certain CPU deep idle states the local timers stop. An external clock device is used to wakeup these CPUs. The kernel support for the wakeup of these CPUs is provided by the tick broadcast framework by using the external clock device as the wakeup source. However not all

[PATCH V5 7/8] cpuidle/powernv: Add "Fast-Sleep" CPU idle state

2014-01-15 Thread Preeti U Murthy
Fast sleep is one of the deep idle states on Power8 in which local timers of CPUs stop. On PowerPC we do not have an external clock device which can handle wakeup of such CPUs. Now that we have the support in the tick broadcast framework for archs that do not sport such a device and the low level s

[PATCH V5 5/8] powermgt: Add OPAL call to resync timebase on wakeup

2014-01-15 Thread Preeti U Murthy
From: Vaidyanathan Srinivasan During "Fast-sleep" and deeper power savings state, decrementer and timebase could be stopped making it out of sync with rest of the cores in the system. Add a firmware call to request platform to resync timebase using low level platform methods. Signed-off-by: Vai

[PATCH V5 4/8] powernv/cpuidle: Add context management for Fast Sleep

2014-01-15 Thread Preeti U Murthy
From: Vaidyanathan Srinivasan Before adding Fast-Sleep into the cpuidle framework, some low level support needs to be added to enable it. This includes saving and restoring of certain registers at entry and exit time of this state respectively just like we do in the NAP idle state. Signed-off-by

[PATCH V5 3/8] cpuidle/ppc: Split timer_interrupt() into timer handling and interrupt handling routines

2014-01-15 Thread Preeti U Murthy
Split timer_interrupt(), which is the local timer interrupt handler on ppc into routines called during regular interrupt handling and __timer_interrupt(), which takes care of running local timers and collecting time related stats. This will enable callers interested only in running expired local t

[PATCH V5 2/8] powerpc: Implement tick broadcast IPI as a fixed IPI message

2014-01-15 Thread Preeti U Murthy
From: Srivatsa S. Bhat For scalability and performance reasons, we want the tick broadcast IPIs to be handled as efficiently as possible. Fixed IPI messages are one of the most efficient mechanisms available - they are faster than the smp_call_function mechanism because the IPI handlers are fixed

[PATCH V5 1/8] powerpc: Free up the slot of PPC_MSG_CALL_FUNC_SINGLE IPI message

2014-01-15 Thread Preeti U Murthy
From: Srivatsa S. Bhat The IPI handlers for both PPC_MSG_CALL_FUNC and PPC_MSG_CALL_FUNC_SINGLE map to a common implementation - generic_smp_call_function_single_interrupt(). So, we can consolidate them and save one of the IPI message slots, (which are precious on powerpc, since only 4 of those s

[PATCH V5 0/8] cpuidle/ppc: Enable deep idle states on PowerNV

2014-01-15 Thread Preeti U Murthy
On PowerPC, when CPUs enter certain deep idle states, the local timers stop and the time base could go out of sync with the rest of the cores in the system. This patchset adds support to wake up CPUs in such idle states by broadcasting IPIs to them at their next timer events using the tick broadca

Re: [git pull] Please pull powerpc.git merge branch

2014-01-15 Thread Linus Torvalds
On Wed, Jan 15, 2014 at 12:01 PM, Benjamin Herrenschmidt wrote: > > My original intend was to put it in powerpc-next and then shoot it to > stable, but it got a tad annoying (due to churn it needs to be applied > at least on rc4 or later while my next is at rc1 and clean that way), so > I put it i