Re: [PATCH v3 2/5] ia64: reuse append_elf_note() and final_note() functions

2017-01-04 Thread Dave Young
On 01/02/17 at 07:44pm, Hari Bathini wrote: > Get rid of multiple definitions of append_elf_note() & final_note() > functions. Reuse these functions compiled under CONFIG_CRASH_CORE > Also, define Elf_Word and use it instead of generic u32 or the more > specific Elf64_Word. > > Signed-off-by:

Re: [PATCH v3 1/5] crash: move crashkernel parsing and vmcore related code under CONFIG_CRASH_CORE

2017-01-04 Thread Dave Young
Hi, Hari On 01/02/17 at 07:43pm, Hari Bathini wrote: > Traditionally, kdump is used to save vmcore in case of a crash. Some > architectures like powerpc can save vmcore using architecture specific > support instead of kexec/kdump mechanism. Such architecture specific > support also needs to

Re: [PATCH v5 08/12] powerpc: Add support to mask perf interrupts and replay them

2017-01-04 Thread Nicholas Piggin
On Wed, 4 Jan 2017 22:21:05 +0530 Madhavan Srinivasan wrote: > On Wednesday 04 January 2017 06:08 PM, Nicholas Piggin wrote: > > On Wed, 4 Jan 2017 17:19:46 +0530 > > Madhavan Srinivasan wrote: > > > >> @@ -134,7 +137,7 @@ static inline

Re: [PATCH v3 2/3] Keep interrupts enabled even on soft disable

2017-01-04 Thread Madhavan Srinivasan
On Thursday 05 January 2017 10:25 AM, Balbir Singh wrote: This patch removes the disabling of interrupts in soft-disable mode, when interrupts are received (in lazy mode). The new scheme keeps the interrupts enabled when we receive an interrupt and does the following: When an external

[PATCH v3 3/3] Enable soft nmi handler

2017-01-04 Thread Balbir Singh
a. On decrementer interrupt, instead of setting dec to maximum and returning, we do the following i. Call a function handle_nmi_dec, which in turn calls handle_soft_nmi ii. handle_soft_nmi sets the decrementer value to 1 second and checks if more than 30 seconds have passed

[PATCH v3 2/3] Keep interrupts enabled even on soft disable

2017-01-04 Thread Balbir Singh
This patch removes the disabling of interrupts in soft-disable mode, when interrupts are received (in lazy mode). The new scheme keeps the interrupts enabled when we receive an interrupt and does the following: When an external interrupt is received, we store the interrupt in local_paca via

[PATCH v3 1/3] Merge IPI and DEFAULT priorities

2017-01-04 Thread Balbir Singh
We merge IPI and DEFAULT priorities to the same value. The idea is to keep interrupts enabled even in lazy soft-disabled mode. Instead of storing the IPI and irq separately, we keep the levels same so that we deal with only one of them Cc: Michael Ellerman Cc: Benjamin

[PATCH v3 0/3] Support Soft NMI

2017-01-04 Thread Balbir Singh
This patch is based on suggestions from paulus and benh. The bugs are all mine. The idea was to implement soft NMI(s) by keeping interrupts enabled in the soft-disabled state, but to use the interrupt controller to gate posting of new interrupts to the processor. This is still work in progress and

Re: [PATCH 9/9] powerpc: A new cache shape aux vectors

2017-01-04 Thread Benjamin Herrenschmidt
On Wed, 2017-01-04 at 11:04 -0200, Tulio Magno Quites Machado Filho > > +#define AT_L1I_CACHESIZE 40 > > +#define AT_L1I_CACHESHAPE 41 > > +#define AT_L1D_CACHESIZE 42 > > +#define AT_L1D_CACHESHAPE 43 > > +#define AT_L2_CACHESIZE44 > > +#define AT_L2_CACHESHAPE 45 > >

Re: [PATCH v4 3/4] powerpc/mm: add radix__remove_section_mapping()

2017-01-04 Thread Reza Arbab
On Wed, Jan 04, 2017 at 10:37:58AM +0530, Aneesh Kumar K.V wrote: Reza Arbab writes: +static void remove_pagetable(unsigned long start, unsigned long end) +{ + unsigned long addr, next; + pud_t *pud_base; + pgd_t *pgd; + +

Re: [PATCH v4 1/4] powerpc/mm: refactor radix physical page mapping

2017-01-04 Thread Reza Arbab
On Wed, Jan 04, 2017 at 10:34:25AM +0530, Aneesh Kumar K.V wrote: We lost the below in the change. pr_info("Mapping range 0x%lx - 0x%lx with 0x%lx\n", (unsigned long)base, (unsigned long)end, linear_page_size); Is there a way to

Re: [PATCH v2 3/3] powerpc/pseries: Update affinity for memory and cpus specified in a PRRN event

2017-01-04 Thread Nathan Fontenot
On 12/15/2016 04:22 PM, John Allen wrote: > Extend the existing PRRN infrastructure to perform the actual affinity > updating for cpus and memory in addition to the device tree updating. For > cpus, dynamic affinity updating already appears to exist in the kernel in > the form of

Re: [PATCH] fsl_ssi: set fifo watermark to more reliable value

2017-01-04 Thread Mark Brown
On Tue, Jan 03, 2017 at 10:22:57AM -0800, Caleb Crome wrote: > From: Caleb Crome > > The fsl_ssi fifo watermark is by default set to 2 free spaces (i.e. > activate DMA on FIFO when only 2 spaces are left.) This means the Please submit patches using subject lines reflecting the

Re: [PATCH 0/2] dpaa_eth: a couple of fixes

2017-01-04 Thread David Miller
From: Madalin Bucur Date: Wed, 4 Jan 2017 13:21:28 +0200 > Add cleanup on PHY initialization failure path, avoid using > uninitialized memory at CGR init. Series applied, thanks.

[PATCH] powerpc: fix 32-bit ppc_fadvise64_64 for 64-bit offset

2017-01-04 Thread Joseph Myers
Consider the following test, built for 32-bit powerpc and run under a 32-bit kernel. #define _GNU_SOURCE #include #include #include #include int main (void) { int fd = open ("/dev/null", O_RDWR); int ret = posix_fadvise64 (fd, 0, -1, POSIX_FADV_NORMAL); if (ret == EINVAL) puts

Applied "ASoC: fsl_ssi: set fifo watermark to more reliable value" to the asoc tree

2017-01-04 Thread Mark Brown
The patch ASoC: fsl_ssi: set fifo watermark to more reliable value has been applied to the asoc tree at git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours)

Re: [PATCH] fsl_ssi: set fifo watermark to more reliable value

2017-01-04 Thread Mark Brown
On Wed, Jan 04, 2017 at 10:31:42AM -0800, ccrome wrote: > The subject should be > > [PATCH] ASoC: fsl_ssi: set fifo watermark to more reliable value > > Correct? Yes. > Should I re-submit? No, it's fine - if I'm sending one of those mails it'll be fine as I've actually seen the mail to reply

Re: bootx_init.c:88: undefined reference to `__stack_chk_fail_local'

2017-01-04 Thread Christian Kujau
On Wed, 4 Jan 2017, Christophe LEROY wrote: > Using GCC 5.4.0, I don't have that issue. bootx_init.o only contains reference > to __stack_chk_fail FWIW, building with a GCC 5.2 crosscompiler succeeds (with CONFIG_CC_STACKPROTECTOR_STRONG=y), but I don't know if it will boot though, see my other

Re: [PATCH] fsl_ssi: set fifo watermark to more reliable value

2017-01-04 Thread ccrome
On Wed, Jan 4, 2017 at 10:27 AM, Mark Brown wrote: > > On Tue, Jan 03, 2017 at 10:22:57AM -0800, Caleb Crome wrote: > > From: Caleb Crome > > > > The fsl_ssi fifo watermark is by default set to 2 free spaces (i.e. > > activate DMA on FIFO when only 2 spaces

Re: ext4 filesystem corruption with 4.10-rc2 on ppc64le

2017-01-04 Thread Linus Torvalds
On Wed, Jan 4, 2017 at 8:23 AM, Jens Axboe wrote: > On 01/04/2017 08:28 AM, Theodore Ts'o wrote: >> >> Jens, could you expedite a pull request to Linus? This is affecting >> ext4 on 1k block file systems on x86/x86_64, so this is not a ppc-only >> regression. > > Yes, it'll go out

Re: ext4 filesystem corruption with 4.10-rc2 on ppc64le

2017-01-04 Thread Jens Axboe
On 01/04/2017 08:28 AM, Theodore Ts'o wrote: > On Wed, Jan 04, 2017 at 11:32:42AM +0530, Chandan Rajendra wrote: >> On Wednesday, January 04, 2017 04:18:08 PM Anton Blanchard wrote: >>> I'm consistently seeing ext4 filesystem corruption using a mainline >>> kernel. It doesn't take much to trigger

Re: [PATCH v5 08/12] powerpc: Add support to mask perf interrupts and replay them

2017-01-04 Thread Madhavan Srinivasan
On Wednesday 04 January 2017 06:08 PM, Nicholas Piggin wrote: On Wed, 4 Jan 2017 17:19:46 +0530 Madhavan Srinivasan wrote: @@ -134,7 +137,7 @@ static inline bool arch_irqs_disabled(void) _was_enabled = local_paca->soft_enabled; \

Re: ext4 filesystem corruption with 4.10-rc2 on ppc64le

2017-01-04 Thread Theodore Ts'o
On Wed, Jan 04, 2017 at 11:32:42AM +0530, Chandan Rajendra wrote: > On Wednesday, January 04, 2017 04:18:08 PM Anton Blanchard wrote: > > I'm consistently seeing ext4 filesystem corruption using a mainline > > kernel. It doesn't take much to trigger it - download a ppc64le Ubuntu > > cloud image,

Re: ext4 filesystem corruption with 4.10-rc2 on ppc64le

2017-01-04 Thread Jens Axboe
On 01/03/2017 10:18 PM, Anton Blanchard wrote: > Hi, > > I'm consistently seeing ext4 filesystem corruption using a mainline > kernel. It doesn't take much to trigger it - download a ppc64le Ubuntu > cloud image, boot it in KVM and run: > > sudo apt-get update > sudo apt-get dist-upgrade > sudo

Re: bootx_init.c:88: undefined reference to `__stack_chk_fail_local'

2017-01-04 Thread Christian Kujau
On Wed, 4 Jan 2017, Christophe LEROY wrote: > Looking a bit over internet, some people have reported having encountered that > issue due to old object files not properly cleaned. > Have you tried a 'make clean' or 'distclean' ? I'm compiling with O=$DIR and I've deleted the entire $DIR before

Re: [PATCH v3 15/15] livepatch: allow removal of a disabled patch

2017-01-04 Thread Miroslav Benes
> diff --git a/samples/livepatch/livepatch-sample.c > b/samples/livepatch/livepatch-sample.c > index bb61c65..0625f38 100644 > --- a/samples/livepatch/livepatch-sample.c > +++ b/samples/livepatch/livepatch-sample.c > @@ -89,7 +89,6 @@ static int livepatch_init(void) > > static void

Re: [PATCH] dt-bindings: qman: Remove pool channel node

2017-01-04 Thread Rob Herring
On Wed, Jan 04, 2017 at 01:03:49PM +0200, Madalin Bucur wrote: > From: Scott Wood > > No device tree has these, nor does any driver look for them. > > Signed-off-by: Scott Wood > --- > .../devicetree/bindings/soc/fsl/qman-portals.txt | 20 >

Re: [PATCH v3 14/15] livepatch: add /proc//patch_state

2017-01-04 Thread Miroslav Benes
On Thu, 8 Dec 2016, Josh Poimboeuf wrote: > Expose the per-task patch state value so users can determine which tasks > are holding up completion of a patching operation. > > Signed-off-by: Josh Poimboeuf Reviewed-by: Miroslav Benes Miroslav

Re: [PATCH v3 13/15] livepatch: change to a per-task consistency model

2017-01-04 Thread Miroslav Benes
On Thu, 8 Dec 2016, Josh Poimboeuf wrote: > +void klp_start_transition(void) > +{ > + struct task_struct *g, *task; > + unsigned int cpu; > + > + WARN_ON_ONCE(klp_target_state == KLP_UNDEFINED); > + > + pr_notice("'%s': %s...\n", klp_transition_patch->mod->name, > +

Re: [PATCH 9/9] powerpc: A new cache shape aux vectors

2017-01-04 Thread Tulio Magno Quites Machado Filho
Benjamin Herrenschmidt writes: > diff --git a/arch/powerpc/include/uapi/asm/auxvec.h > b/arch/powerpc/include/uapi/asm/auxvec.h > index ce17d2c..79183d2 100644 > --- a/arch/powerpc/include/uapi/asm/auxvec.h > +++ b/arch/powerpc/include/uapi/asm/auxvec.h > @@ -16,6

Re: [PATCH v5 08/12] powerpc: Add support to mask perf interrupts and replay them

2017-01-04 Thread Nicholas Piggin
On Wed, 4 Jan 2017 17:19:46 +0530 Madhavan Srinivasan wrote: > @@ -134,7 +137,7 @@ static inline bool arch_irqs_disabled(void) > _was_enabled = local_paca->soft_enabled;\ > local_paca->soft_enabled = IRQ_DISABLE_MASK_LINUX;\ >

RE: [PATCH] ASoC : fsl_ssi : Correct the condition to check AC97 mode

2017-01-04 Thread David Laight
From: Harisangam, Sharvari (S.) > Sent: 28 December 2016 11:07 > Corrected the condition to check if ssi is configured for AC97 > mode. Other modes like dsp_a also satisfy the ANDing condition. Under the assumption that the constants have 1 bit set nothing is wrong. David ... > -

[PATCH v5 12/12] powerpc: Rename soft_enabled to soft_disabled_mask

2017-01-04 Thread Madhavan Srinivasan
Rename the paca->soft_enabled to paca->soft_disabled_mask as it is no more used as a flag for interrupt state. Signed-off-by: Madhavan Srinivasan --- arch/powerpc/include/asm/hw_irq.h | 36 ++-- arch/powerpc/include/asm/kvm_ppc.h | 2

[PATCH v5 11/12] powerpc: rewrite local_t using soft_irq

2017-01-04 Thread Madhavan Srinivasan
Local atomic operations are fast and highly reentrant per CPU counters. Used for percpu variable updates. Local atomic operations only guarantee variable modification atomicity wrt the CPU which owns the data and these needs to be executed in a preemption safe way. Here is the design of this

[PATCH v5 09/12] powerpc:Add new kconfig IRQ_DEBUG_SUPPORT

2017-01-04 Thread Madhavan Srinivasan
New Kconfig is added "CONFIG_IRQ_DEBUG_SUPPORT" to add warn_on to alert the invalid transitions. Also moved the code under the CONFIG_TRACE_IRQFLAGS in arch_local_irq_restore() to new Kconfig. Signed-off-by: Madhavan Srinivasan --- arch/powerpc/Kconfig | 4

[PATCH v5 10/12] powerpc: Add new set of soft_enabled_ functions

2017-01-04 Thread Madhavan Srinivasan
To support disabling and enabling of irq with PMI, set of new powerpc_local_irq_pmu_save() and powerpc_local_irq_restore() functions are added. And powerpc_local_irq_save() implemented, by adding a new soft_enabled manipulation function soft_enabled_or_return(). Local_irq_pmu_* macros are provided

[PATCH v5 08/12] powerpc: Add support to mask perf interrupts and replay them

2017-01-04 Thread Madhavan Srinivasan
Two new bit mask field "IRQ_DISABLE_MASK_PMU" is introduced to support the masking of PMI and "IRQ_DISABLE_MASK_ALL" to aid interrupt masking checking. Couple of new irq #defs "PACA_IRQ_PMI" and "SOFTEN_VALUE_0xf0*" added to use in the exception code to check for PMI interrupts. In the

[PATCH v5 07/12] Add support to take additional parameter in MASKABLE_* macro

2017-01-04 Thread Madhavan Srinivasan
To support addition of "bitmask" to MASKABLE_* macros, factor out the EXCPETION_PROLOG_1 macro. Make it explicit the interrupt masking supported by a gievn interrupt handler. Patch correspondingly extends the MASKABLE_* macros with an addition's parameter. "bitmask" parameter is passed to

[PATCH v5 06/12] powerpc: Avoid using EXCEPTION_PROLOG_1 macro in MASKABLE_*

2017-01-04 Thread Madhavan Srinivasan
Currently we use both EXCEPTION_PROLOG_1 and __EXCEPTION_PROLOG_1 in the MASKABLE_* macros. As a cleanup, this patch makes MASKABLE_* to use only __EXCEPTION_PROLOG_1. There is not logic change. Reviewed-by: Nicholas Piggin Signed-off-by: Madhavan Srinivasan

[PATCH v5 05/12] powerpc: reverse the soft_enable logic

2017-01-04 Thread Madhavan Srinivasan
"paca->soft_enabled" is used as a flag to mask some of interrupts. Currently supported flags values and their details: soft_enabledMSR[EE] 0 0 Disabled (PMI and HMI not masked) 1 1 Enabled "paca->soft_enabled" is initialized to 1 to make the

[PATCH v5 04/12] powerpc: Add soft_enabled manipulation functions

2017-01-04 Thread Madhavan Srinivasan
Add new soft_enabled_* manipulation function and implement arch_local_* using the soft_enabled_* wrappers. Reviewed-by: Nicholas Piggin Signed-off-by: Madhavan Srinivasan --- arch/powerpc/include/asm/hw_irq.h | 32 ++-- 1

[PATCH v5 03/12] powerpc: Use soft_enabled_set api to update paca->soft_enabled

2017-01-04 Thread Madhavan Srinivasan
Force use of soft_enabled_set() wrapper to update paca-soft_enabled wherever possisble. Also add a new wrapper function, soft_enabled_set_return(), added to force the paca->soft_enabled updates. Signed-off-by: Madhavan Srinivasan --- arch/powerpc/include/asm/hw_irq.h

[PATCH v5 02/12] powerpc: move set_soft_enabled() and rename

2017-01-04 Thread Madhavan Srinivasan
Move set_soft_enabled() from powerpc/kernel/irq.c to asm/hw_irq.c, to force updates to paca-soft_enabled done via these access function. Add "memory" clobber to hint compiler since paca->soft_enabled memory is the target here Renaming it as soft_enabled_set() will make namespaces works better as

[PATCH v5 01/12] powerpc: Add #defs for paca->soft_enabled flags

2017-01-04 Thread Madhavan Srinivasan
Two #defs IRQ_DISABLE_LEVEL_NONE and IRQ_DISABLE_LEVEL_LINUX are added to be used when updating paca->soft_enabled. Replace the hardcoded values used when updating paca->soft_enabled with IRQ_DISABLE_MASK_* #def. No logic change. Reviewed-by: Nicholas Piggin Signed-off-by:

[PATCH v5 00/12]powerpc: "paca->soft_enabled" based local atomic operation implementation

2017-01-04 Thread Madhavan Srinivasan
Local atomic operations are fast and highly reentrant per CPU counters. Used for percpu variable updates. Local atomic operations only guarantee variable modification atomicity wrt the CPU which owns the data and these needs to be executed in a preemption safe way. Here is the design of the

[PATCH 2/2] dpaa_eth: Initialize CGR structure before init

2017-01-04 Thread Madalin Bucur
From: Roy Pledge The QBMan CGR options needs to be zeroed before calling the init function Signed-off-by: Roy Pledge --- drivers/net/ethernet/freescale/dpaa/dpaa_eth.c | 2 ++ 1 file changed, 2 insertions(+) diff --git

[PATCH 0/2] dpaa_eth: a couple of fixes

2017-01-04 Thread Madalin Bucur
Add cleanup on PHY initialization failure path, avoid using uninitialized memory at CGR init. Madalin Bucur (1): dpaa_eth: cleanup after init_phy() failure Roy Pledge (1): dpaa_eth: Initialize CGR structure before init drivers/net/ethernet/freescale/dpaa/dpaa_eth.c | 6 +- 1 file

[PATCH 1/2] dpaa_eth: cleanup after init_phy() failure

2017-01-04 Thread Madalin Bucur
Signed-off-by: Madalin Bucur --- drivers/net/ethernet/freescale/dpaa/dpaa_eth.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c index 624ba90..77517aa

[PATCH] dt-bindings: qman: Remove pool channel node

2017-01-04 Thread Madalin Bucur
From: Scott Wood No device tree has these, nor does any driver look for them. Signed-off-by: Scott Wood --- .../devicetree/bindings/soc/fsl/qman-portals.txt | 20 1 file changed, 20 deletions(-) diff --git

Re: [PATCH V3 3/4] arch/powerpc: Implement Optprobes

2017-01-04 Thread Naveen N. Rao
On 2016/12/25 11:54AM, Masami Hiramatsu wrote: > On Mon, 19 Dec 2016 18:48:24 +0530 > Anju T Sudhakar wrote: > > > Detour buffer contains instructions to create an in memory pt_regs. > > After the execution of the pre-handler, a call is made for instruction > >

Re: DEBUG_LOCKS_WARN_ON(1) / lockdep.c:3134 lockdep_init_map+0x1e8/0x1f0

2017-01-04 Thread Peter Zijlstra
On Tue, Jan 03, 2017 at 06:11:20PM -0800, Christian Kujau wrote: > Hi, > > booting v4.10-rc2 on this PowerPC G4 machine prints the following early > on, but then continues to boot and the machine is running fine so far: > > > BUG: key ef0ba7d0 not in .data! > DEBUG_LOCKS_WARN_ON(1) >

Re: [PATCH v4 12/12] powerpc: Rename soft_enabled to soft_disabled_mask

2017-01-04 Thread Madhavan Srinivasan
On Tuesday 20 December 2016 08:28 AM, Nicholas Piggin wrote: On Mon, 19 Dec 2016 13:37:08 +0530 Madhavan Srinivasan wrote: Rename the paca->soft_enabled to paca->soft_disabled_mask as it is no more used as a flag for interrupt state. This makes it much more

Re: bootx_init.c:88: undefined reference to `__stack_chk_fail_local'

2017-01-04 Thread Segher Boessenkool
On Wed, Jan 04, 2017 at 09:23:47AM +0100, Christophe LEROY wrote: > >The way gcc implements the stack protector has some serious > >incompatibilities with the way the Linux kernel uses r13, I wouldn't > >even try until we sort that out... > > Yes indeed, it looks like recent versions of GCC don't

Re: bootx_init.c:88: undefined reference to `__stack_chk_fail_local'

2017-01-04 Thread Christophe LEROY
Le 03/01/2017 à 23:50, Benjamin Herrenschmidt a écrit : On Tue, 2017-01-03 at 07:25 -0800, Christian Kujau wrote: Hi, when compiling v4.10-rc2 with CONFIG_CC_STACKPROTECTOR_STRONG=y, the linker fails with: The way gcc implements the stack protector has some serious incompatibilities with

Re: ext4 filesystem corruption with 4.10-rc2 on ppc64le

2017-01-04 Thread luigi burdo
Hi, it is present on ppc not le too. found it on Ubuntu Mate 16.10 PPC with kernel 4.9 rc6 PPC64 on P5020/P5040 Thanks Luigi Da: Linuxppc-dev per conto di Anton Blanchard