Re: [PATCH v2 1/5] ARC: SMP: Use "unsigned virq" in smp_ipi_irq_setup instead of "signed irq"

2016-10-24 Thread Vineet Gupta
On 10/24/2016 05:46 AM, Yuriy Kolerov wrote: > This function takes a cpu number and a virq number and registers an > appropriate handler per cpu. However smp_ipi_irq_setup is incorrectly > used in several places of ARC platform code - hwirq is passed instead > of virq. This patch is intended to cla

Re: [PATCH v2 2/5] ARC: SMP: Pass virq to smp_ipi_irq_setup instead of hwirq

2016-10-24 Thread Vineet Gupta
On 10/24/2016 05:46 AM, Yuriy Kolerov wrote: > This function takes a cpu number and a virq number and registers an > appropriate handler per cpu. However smp_ipi_irq_setup is incorrectly > used in several places of ARC platform code - hwirq is passed instead of > virq. There is a code with an examp

Re: [PATCH] asm-generic: Drop getrlimit and setrlimit syscalls from default list

2016-10-24 Thread Ley Foon Tan
On Mon, Oct 24, 2016 at 5:09 PM, James Hogan wrote: > On Sat, Oct 22, 2016 at 03:14:04PM +0300, Yury Norov wrote: >> The newer prlimit64 syscall provides all the functionality provided by >> the getrlimit and setrlimit syscalls and adds the pid of target process, >> so future architectures won't n

Re: [PATCH v2 1/5] ARC: SMP: Use "unsigned virq" in smp_ipi_irq_setup instead of "signed irq"

2016-10-24 Thread Vineet Gupta
Hi Yuriy, On 10/24/2016 05:46 AM, Yuriy Kolerov wrote: > This function takes a cpu number and a virq number and registers an > appropriate handler per cpu. However smp_ipi_irq_setup is incorrectly > used in several places of ARC platform code - hwirq is passed instead > of virq. This patch is inte

RE: [PATCH v2] drm/arcpgu: Accommodate adv7511 switch to DRM bridge

2016-10-24 Thread Alexey Brodkin
Hi Daniel, > -Original Message- > From: linux-snps-arc [mailto:linux-snps-arc-boun...@lists.infradead.org] On > Behalf Of Alexey Brodkin > Sent: 19 октября 2016 г. 12:33 > To: dri-de...@lists.freedesktop.org; arch...@codeaurora.org; > eugeniy.palt...@synopsys.com > Cc: linux-snps-arc@lis

[net-next PATCH RFC 03/26] arch/arc: Add option to skip sync on DMA mapping

2016-10-24 Thread Alexander Duyck
This change allows us to pass DMA_ATTR_SKIP_CPU_SYNC which allows us to avoid invoking cache line invalidation if the driver will just handle it later via a sync_for_cpu or sync_for_device call. Cc: Vineet Gupta Cc: linux-snps-arc@lists.infradead.org Signed-off-by: Alexander Duyck --- arch/arc/

[PATCH-v2] ARC: syscall for userspace cmpxchg assist

2016-10-24 Thread Vineet Gupta
Older ARC700 cores (ARC750 specifically) lack instructions to implement atomic r-w-w. This is problematic for userspace libraries such as NPTL which need atomic primitives. So enable them by providing kernel assist. This is costly but really the only sane soluton (othern than tight spinning using t

Re: [PATCH] ARC: return -EFAULT on failed access_ok for arc_usr_cmpxchg syscall

2016-10-24 Thread Colin Ian King
On 24/10/16 16:56, Vineet Gupta wrote: > On 10/24/2016 03:47 AM, Colin King wrote: >> From: Colin Ian King >> >> arc_usr_cmpxchg currently returns an uninitialized value in ret >> on a failed access_ok call. Instead, return -EFAULT. >> >> Signed-off-by: Colin Ian King >> --- >> arch/arc/kernel/p

Re: [PATCH] ARC: return -EFAULT on failed access_ok for arc_usr_cmpxchg syscall

2016-10-24 Thread Vineet Gupta
On 10/24/2016 03:47 AM, Colin King wrote: > From: Colin Ian King > > arc_usr_cmpxchg currently returns an uninitialized value in ret > on a failed access_ok call. Instead, return -EFAULT. > > Signed-off-by: Colin Ian King > --- > arch/arc/kernel/process.c | 2 +- > 1 file changed, 1 insertion(

[PATCH v2 4/5] ARC: MCIP: Set an initial affinity value in idu_irq_map

2016-10-24 Thread Yuriy Kolerov
Originally an initial distribution mode (its value resides in Device Tree) for each common interrupt is set in idu_irq_xlate. This leads to the following problems. idu_irq_xlate may be called several times during parsing of the Device Tree and it is semantically wrong to configure an initial distri

[PATCH v2 5/5] ARC: MCIP: Use IDU_M_DISTRI_DEST mode if there is only 1 destination core

2016-10-24 Thread Yuriy Kolerov
ARC linux uses 2 distribution modes for common interrupts: round robin mode (IDU_M_DISTRI_RR) and a simple destination mode (IDU_M_DISTRI_DEST). The first one is used when more than 1 cores may handle a common interrupt and the second one is used when only 1 core may handle a common interrupt. How

[PATCH v2 1/5] ARC: SMP: Use "unsigned virq" in smp_ipi_irq_setup instead of "signed irq"

2016-10-24 Thread Yuriy Kolerov
This function takes a cpu number and a virq number and registers an appropriate handler per cpu. However smp_ipi_irq_setup is incorrectly used in several places of ARC platform code - hwirq is passed instead of virq. This patch is intended to clarify declaration of virq argument to prevent passing

[PATCH v2 3/5] ARC: MCIP: Use hwirq instead of virq for resolution of IDU IRQ handlers

2016-10-24 Thread Yuriy Kolerov
Multicore ARC configurations use IDU (Interrupt Distribution Unit) for distributing of common interrupts. In fact IDU is a interrupt controller on top of main per core interrupt controller. All common IRQs are physically and linearly mapped to per core interrupts. E.g. <0, 1, 2, 3> common IDU inte

[PATCH v2 2/5] ARC: SMP: Pass virq to smp_ipi_irq_setup instead of hwirq

2016-10-24 Thread Yuriy Kolerov
This function takes a cpu number and a virq number and registers an appropriate handler per cpu. However smp_ipi_irq_setup is incorrectly used in several places of ARC platform code - hwirq is passed instead of virq. There is a code with an example of inccorect usage of smp_ipi_irq_setup: smp_

[PATCH] ARC: return -EFAULT on failed access_ok for arc_usr_cmpxchg syscall

2016-10-24 Thread Colin King
From: Colin Ian King arc_usr_cmpxchg currently returns an uninitialized value in ret on a failed access_ok call. Instead, return -EFAULT. Signed-off-by: Colin Ian King --- arch/arc/kernel/process.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arc/kernel/process.c b/

Re: [PATCH] asm-generic: Drop getrlimit and setrlimit syscalls from default list

2016-10-24 Thread James Hogan
On Sat, Oct 22, 2016 at 03:14:04PM +0300, Yury Norov wrote: > The newer prlimit64 syscall provides all the functionality provided by > the getrlimit and setrlimit syscalls and adds the pid of target process, > so future architectures won't need to include getrlimit and setrlimit. > > Therefore dro