Re: [PATCH 2/5] ARC: perf: introduce Kernel PMU events support

2018-12-05 Thread Vineet Gupta
On 12/5/18 9:06 AM, Eugeniy Paltsev wrote: > Export all available ARC architected hardware events as > kernel PMU events to make non-generic events accessible. > > ARC PMU HW allow us to read the list of all available > events names. So we generate kernel PMU event list > dynamically in

Re: [PATCH 4/5] ARC: perf: fix description comment

2018-12-05 Thread Vineet Gupta
On 12/5/18 9:06 AM, Eugeniy Paltsev wrote: > Fix description comment as this code doesn't belong only to > ARC700 anymore. > > Also while I'm at it, use SPDX License Identifier. > > Signed-off-by: Eugeniy Paltsev Maybe squash this into trivial cleanups 1/5 ? Acked-by:

Re: [PATCH v3] clocksource/drivers/arc_timer: Utilize generic sched_clock

2018-11-19 Thread Vineet Gupta
; > Note how much more meaningful is the second output - time spent for > execution pretty much matches number of cycles spent (we're runnign > @ 1GHz here). > > Signed-off-by: Alexey Brodkin > Cc: Daniel Lezcano > Cc: Vineet Gupta > Cc: Thomas Gleixner Acked-by: Vineet Gupta Thx, -Vineet

Re: [PATCH v4 6/6] arch: Move initrd= parsing into do_mounts_initrd.c

2018-11-12 Thread Vineet Gupta
On 11/12/18 4:52 PM, Florian Fainelli wrote: > On 11/12/18 4:40 PM, Vineet Gupta wrote: >> On 11/12/18 4:38 PM, Florian Fainelli wrote: >>>>> #ifdef CONFIG_BLK_DEV_INITRD >>>>> - if (initrd_start) >>>>> - memblock

Re: [PATCH 06/13] arc: define syscall_get_arch()

2018-11-09 Thread Vineet Gupta
On 11/8/18 7:16 PM, Dmitry V. Levin wrote: > syscall_get_arch() is required to be implemented on all architectures > that use tracehook_report_syscall_entry() in order to extend > the generic ptrace API with PTRACE_GET_SYSCALL_INFO request. > > Signed-off-by: Dmitry V. Levin > --- >

Re: [PATCH 02/13] elf-em.h: add EM_ARC

2018-11-09 Thread Vineet Gupta
On 11/8/18 7:15 PM, Dmitry V. Levin wrote: > The uapi/linux/audit.h header is going to use EM_ARC in order > to define AUDIT_ARCH_ARC which is needed to implement > syscall_get_arch() which in turn is required to extend > the generic ptrace API with PTRACE_GET_SYSCALL_INFO request. > > The value

Re: [PATCH 12/18] arch/tlb: Clean up simple architectures

2018-10-03 Thread Vineet Gupta
tion) > openrisc: has inefficient flush_tlb_range() -> 2 > (no limit on range iteration) > parisc: already uses flush_tlb_range() -> 1 > sparc32:already uses flush_tlb_range() -> 1 > unicore32: has inefficient flush_tlb_range() -> 2 > (no

Re: [PATCH 3/4] mm/tlb, x86/mm: Support invalidating TLB caches for RCU_TABLE_FREE

2018-08-29 Thread Vineet Gupta
On 08/27/2018 04:00 AM, Peter Zijlstra wrote: > > The one obvious thing SH and ARM want is a sensible default for > tlb_start_vma(). (also: https://lkml.org/lkml/2004/1/15/6 ) > > The below make tlb_start_vma() default to flush_cache_range(), which > should be right and sufficient. The only

Re: linux-next: manual merge of the arc-current tree with Linus' tree

2018-08-14 Thread Vineet Gupta
On 08/14/2018 03:11 PM, Stephen Rothwell wrote: > Hi Vineet, > > Today's linux-next merge of the arc-current tree got a conflict in: > > arch/arc/include/asm/atomic.h > > between commit: > > ab0b910490fe ("atomics/arc: Define atomic64_fetch_add_unless()") > > from Linus' tree and commit: > >

Re: [PATCH] ARC: AXS10x/HSDK: Allow U-Boot to pass MAC-address to the kernel

2018-08-02 Thread Vineet Gupta
On 08/02/2018 03:19 AM, Alexey Brodkin wrote: > Otherwise kernel uses random MAC which is not very conveniet. Curious what exactly is the issue - why does the user care what MAC is assigned ? > With that change in place use might set desired MAC in U-Boot > with "setenv ethaddr

Re: ARC show_regs() triggers preempt debug splat, lockdep

2018-08-01 Thread Vineet Gupta
On 08/01/2018 12:53 AM, Peter Zijlstra wrote: > On Tue, Jul 31, 2018 at 02:26:32PM -0700, Vineet Gupta wrote: >> Hi Peter, Al, >> >> Reaching out about a problem I understand, but not quite sure how to fix it. >> Its the weird feeling of how was this working all along,

Re: linux-next: Signed-off-by missing for commit in the arc-current tree

2018-07-30 Thread Vineet Gupta
On 07/28/2018 07:14 PM, Stephen Rothwell wrote: > Hi Vineet, > > Commit > > fa52704e2816 ("ARC: add SMP_CACHE_BYTES value validate") > > is missing a Signed-off-by from its committer. Thx for the report Stephen. This is now fixed/pushed. -Vineet

Re: [PATCH] ARC: prevent showing irrelevant exception info in signal message

2018-07-02 Thread Vineet Gupta
+CC Al On 06/29/2018 12:39 PM, Eugeniy Paltsev wrote: > We process signals in the end of syscall/exception handler. > It the signal is fatal we print register's content using > show_regs function. show_regs() also prints information about > last exception happened. > > In case of multicore system

Re: [PATCH] arc/Kconfig: include mm/Kconfig inside "ARC system configuration"

2018-06-29 Thread Vineet Gupta
On 06/29/2018 01:29 PM, Randy Dunlap wrote: > On 06/29/2018 12:28 PM, Mike Rapoport wrote: >> Hi Randy, >> >> On Fri, Jun 29, 2018 at 09:34:55AM -0700, Randy Dunlap wrote: >>> On 06/29/2018 06:42 AM, Mike Rapoport wrote: Otherwise mm configuration options show up in the top level menu.

Re: ARC compact700 NPS platform - EZ_MachineCheck exception handler

2018-05-21 Thread Vineet Gupta
On 05/21/2018 07:14 AM, Ofer Levi(SW) wrote: Resending, due to typo in LKML mail address. Also please CC linux-snps-...@lists.infradead.org for any ARC Linux related posts. The EV_MachineCheck exception handler is halting the core for exceptions which are not tlb_overlap_fault.

Re: dma_sync_*_for_cpu and direction=TO_DEVICE (was Re: [PATCH 02/20] dma-mapping: provide a generic dma-noncoherent implementation)

2018-05-18 Thread Vineet Gupta
On 05/18/2018 10:50 AM, Russell King - ARM Linux wrote: On Fri, May 18, 2018 at 10:20:02AM -0700, Vineet Gupta wrote: I never understood the need for this direction. And if memory serves me right, at that time I was seeing twice the amount of cache flushing ! It's necessary. Take a moment

Re: [PATCH 02/20] dma-mapping: provide a generic dma-noncoherent implementation

2018-05-18 Thread Vineet Gupta
On 05/18/2018 06:23 AM, h...@lst.de wrote: Fri, May 18, 2018 at 01:03:46PM +, Alexey Brodkin wrote: Note mmc_get_dma_dir() is just "data->flags & MMC_DATA_WRITE ? DMA_TO_DEVICE : DMA_FROM_DEVICE". I.e. if we're preparing for sending data dma_noncoherent_map_sg() will have DMA_TO_DEVICE

dma_sync_*_for_cpu and direction=TO_DEVICE (was Re: [PATCH 02/20] dma-mapping: provide a generic dma-noncoherent implementation)

2018-05-18 Thread Vineet Gupta
to dma_noncoherent_sync_sg_for_device() in dma_noncoherent_map_sg(). I'd say this is not entirely correct because IMHO arch_sync_dma_for_cpu() is supposed to only be used in case of DMA_FROM_DEVICE and arch_sync_dma_for_device() only in case of DMA_TO_DEVICE. So roughly 10 years ago, some kernel rookie nam

Re: [PATCH] ARC: Improve cmpxchng syscall implementation

2018-04-18 Thread Vineet Gupta
On 03/21/2018 04:54 AM, Alexey Brodkin wrote: /* * This is only for old cores lacking LLOCK/SCOND, which by defintion @@ -60,23 +62,48 @@ SYSCALL_DEFINE3(arc_usr_cmpxchg, int *, uaddr, int, expected, int, new) /* Z indicates to userspace if operation succeded */

Re: [PATCH] clocksource: arc_timer: add comments about locking while read GFRC

2018-04-17 Thread Vineet Gupta
Acked-by: Vineet Gupta <vgu...@synopsys.com> --- drivers/clocksource/arc_timer.c | 13 + 1 file changed, 13 insertions(+) diff --git a/drivers/clocksource/arc_timer.c b/drivers/clocksource/arc_timer.c index 4927355f9cbe..b594c373debc 100644 --- a/drivers/clocksource/arc_t

Re: [PATCH v6 04/16] arc: Switch to generic free_initrd_mem.

2018-04-09 Thread Vineet Gupta
__ref free_initmem(void) { free_initmem_default(-1); } - -#ifdef CONFIG_BLK_DEV_INITRD -void __init free_initrd_mem(unsigned long start, unsigned long end) -{ - free_reserved_area((void *)start, (void *)end, -1, "initrd"); -} -#endif LGTM. Acked-by: Vineet Gupta <

Re: [PATCH 0/3] move __HAVE_ARCH_PTE_SPECIAL in Kconfig

2018-04-09 Thread Vineet Gupta
On 04/09/2018 06:57 AM, Laurent Dufour wrote: The per architecture __HAVE_ARCH_PTE_SPECIAL is defined statically in the per architecture header files. This doesn't allow to make other configuration dependent on it. So I understand this series has more "readability" value and I'm fine with this

Re: dma-mapping: clearing GFP_ZERO flag caused crashes of Ethernet on arc/hsdk board.

2018-03-27 Thread Vineet Gupta
Hi Christoph, Andy On 03/27/2018 11:11 AM, Andy Shevchenko wrote: On Tue, Mar 27, 2018 at 8:12 PM, Evgeniy Didin wrote: Hello, After commit 57bf5a8963f8 ("dma-mapping: clear harmful GFP_* flags in common code") we noticed problems with Ethernet controller on

Re: [PATCH] ARC: Improve cmpxchng syscall implementation

2018-03-19 Thread Vineet Gupta
On 03/19/2018 04:00 AM, Alexey Brodkin wrote: arc_usr_cmpxchg syscall is supposed to be used on platforms that lack support of Load-Locked/Store-Conditional instructions in hardware. And in that case we mimic missing hardware features with help of kernel's sycall that "atomically" checks current

Re: arc_usr_cmpxchg and preemption

2018-03-16 Thread Vineet Gupta
On 03/16/2018 10:33 AM, Alexey Brodkin wrote: Hi Peter, Vineet, On Wed, 2018-03-14 at 18:53 +0100, Peter Zijlstra wrote: On Wed, Mar 14, 2018 at 09:58:19AM -0700, Vineet Gupta wrote: Well it is broken wrt the semantics the syscall is supposed to provide. Preemption disabling is what prevents

Re: Do we need to disable preemption in flush_tlb_range()?

2018-03-15 Thread Vineet Gupta
+CC some more folks for intc/irq insights - please see question at the bottom ! On 03/15/2018 02:39 AM, Alexey Brodkin wrote: Hi Peter, On Thu, 2018-03-15 at 09:27 +0100, Peter Zijlstra wrote: On Wed, Mar 14, 2018 at 01:19:01PM -0700, Vineet Gupta wrote: +CC Peter since we have his attention

Re: arc_usr_cmpxchg and preemption

2018-03-14 Thread Vineet Gupta
On 03/14/2018 01:38 PM, Alexey Brodkin wrote: @Vineet, are you OK with proposed implementation? I couldn't agree any more ! -Vineet

Re: Do we need to disable preemption in flush_tlb_range()?

2018-03-14 Thread Vineet Gupta
+CC Peter since we have his attention ;-) On 03/01/2018 07:13 AM, Alexey Brodkin wrote: Hi Vineet, Just noticed that in comments for smp_call_function_many() it is said that preemption must be disabled during its execution. And that function gets executed among other ways like that:

Re: arc_usr_cmpxchg and preemption

2018-03-14 Thread Vineet Gupta
+CC linux-arch, Peter for any preemption insights ! On 03/14/2018 09:36 AM, Alexey Brodkin wrote: Hi Vineet, While debugging a segfault of user-space app on system without atomic ops (I mean LLOCK/SCOND) I understood the root-cause is in implementation of kernel's __NR_arc_usr_cmpxchg syscall

[GIT PULL] ARC fixes for 4.16-rc4

2018-03-01 Thread Vineet Gupta
Fix trailing semicolon ARC: boot log: Fix trailing semicolon Ulf Magnusson (1): ARC: Fix malformed ARC_EMUL_UNALIGNED default Vineet Gupta (1): ARCv2: boot log: fix HS48 release number arch/arc/Kconfig | 1 - arch/arc/boot/dts/axs101.dts | 2 +- arch/

[tip:timers/urgent] clocksource/drivers/arc_timer: Update some comments

2018-02-28 Thread tip-bot for Vineet Gupta
Commit-ID: a4f538573cd72e7961f4ec5eb13c171f5add58ec Gitweb: https://git.kernel.org/tip/a4f538573cd72e7961f4ec5eb13c171f5add58ec Author: Vineet Gupta <vineet.gup...@synopsys.com> AuthorDate: Wed, 21 Feb 2018 11:31:31 -0800 Committer: Thomas Gleixner <t...@linutronix.de> Com

Re: [PATCH v2 2/3] ARC: mcip: update MCIP debug mask when the new cpu came online

2018-02-23 Thread Vineet Gupta
hardcoded MCIP debug mask. Signed-off-by: Eugeniy Paltsev<eugeniy.palt...@synopsys.com> Acked-by: Vineet Gupta <vgu...@ynopsys.com>

Re: [PATCH v2 1/3] ARC: mcip: halt GFRC together with ARC cores

2018-02-23 Thread Vineet Gupta
Eugeniy Paltsev<eugeniy.palt...@synopsys.com> Acked-by: vineet Gupta <vgu...@synopsys.com>

Re: [BUG] ARCv2: MCIP: GFRC: mcip cmd/readback concurrency

2018-02-22 Thread Vineet Gupta
On 02/22/2018 06:26 AM, Eugeniy Paltsev wrote: To read any data from ARconnect we have special interface which includes two AUX registers: MCIP_CMD and MCIP_READBACK. We write command to MCIP_CMD and read data from MCIP_READBACK after that. We have only one instance of this registers per

Re: [PATCH 1/3] ARC: mcip: halt GFRC together with ARC cores

2018-02-21 Thread Vineet Gupta
On 02/21/2018 12:31 PM, Vineet Gupta wrote: Hi Eugeniy, Starting from ARC HS v3.0 From the STAR fix, it seem this was fixed in HS 2.1c, so you should be able to test it on HSDK, which was my next question: where and how did you test this and verify that it works as we think it does. I

Re: [PATCH] mmc: dw_mmc: Fix the DTO timeout overflow calculation for 32-bit systems

2018-02-21 Thread Vineet Gupta
ouglas Anderson <diand...@chromium.org> CC: Ulf Hansson <ulf.hans...@linaro.org> CC: linux-kernel@vger.kernel.org CC: linux-snps-...@lists.infradead.org Tested-by: Vineet Gupta <vgu...@synopsys.com> Fixes: ARC STAR 9001306872 HSDK, sdio: board crashes when copying big files

Re: [PATCH 1/3] ARC: mcip: halt GFRC together with ARC cores

2018-02-21 Thread Vineet Gupta
Hi Eugeniy, On 02/21/2018 01:40 AM, Eugeniy Paltsev wrote: Currently GFRC is running regardless state of ARC cores in the SMP cluster. That means even if ARC cores are halted when doing JTAG debugging GFRC [our source of wall-time] continues to run giving us unexpected warnings once we allow

[PATCH] clocksource: arc_timer: update some comments

2018-02-21 Thread Vineet Gupta
TIMER0 interrupt ACK is different for ARC700 and HS3x cores. This came to light in some internal discussions and it is nice to have this documented rather than digging up the PRM (Prog Ref Manual) again Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- drivers/clocksource/arc_timer.

Re: [PATCH] ARC: Don't check presense of Timer1 in SMP builds

2018-02-13 Thread Vineet Gupta
On 02/13/2018 11:35 AM, Alexey Brodkin wrote: In case of SMP we use GFRC from ARconnect and Timer1 is left untouched. Still with that check in place we're panicing if Timer1 is missing in current hardware which is quite unexpected. Signed-off-by: Alexey Brodkin ---

Re: [PATCH v2] arc: dts: use 'atmel' as manufacturer for at24 in axs10x_mb

2018-02-06 Thread Vineet Gupta
On 02/06/2018 01:04 PM, Alexey Brodkin wrote: Feel free to drop this patch if you plan to submit the fix soon - otherwise, apply it if it may take some time. No I think it worth applying especially in the light of your comment about NXP EEPROM. Vineet, could you please take this one? I've

Re: [PATCH 19/20] ARC: Fix malformed ARC_EMUL_UNALIGNED default

2018-02-05 Thread Vineet Gupta
On 02/04/2018 05:21 PM, Ulf Magnusson wrote: 'default N' should be 'default n', though they happen to have the same effect here, due to undefined symbols (N in this case) evaluating to n in a tristate sense. Remove the default from ARC_EMUL_UNALIGNED instead of changing it. bool and tristate

Re: [PATCH 2/2] ARC: boot log: Fix trailing semicolon

2018-01-23 Thread Vineet Gupta
On 01/23/2018 07:21 AM, Luis de Bethencourt wrote: The trailing semicolon is an empty statement that does no operation. Removing it since it doesn't do anything. Signed-off-by: Luis de Bethencourt Applied to for-curr Thx, -Vineet

Re: [PATCH 1/2] ARC: dw2 unwind: Fix trailing semicolon

2018-01-23 Thread Vineet Gupta
On 01/23/2018 07:20 AM, Luis de Bethencourt wrote: The trailing semicolon is an empty statement that does no operation. Removing it since it doesn't do anything. Signed-off-by: Luis de Bethencourt Applied to for-curr Thx, -Vineet

Re: [PATCH] arc: fix iounmap prototype

2018-01-19 Thread Vineet Gupta
On 01/02/2018 06:23 AM, Geert Uytterhoeven wrote: Hi Arnd, On Tue, Jan 2, 2018 at 12:01 PM, Arnd Bergmann wrote: The missing 'volatile' keyword on the iounmap argument leads to lots of harmless warnings in an allmodconfig build: sound/pci/echoaudio/echoaudio.c:1879:10:

Re: [PATCH v2] ARC: Force disable IOC if we don't want to use it

2018-01-19 Thread Vineet Gupta
On 12/18/2017 07:29 AM, Alexey Brodkin wrote: If software that was executed before Linux kernel [like boot-ROM or bootloader] enabled IOC but we'd like to not use it [mostly for debugging of weird DMA issues] we essentially need to disable IOC. So we do here. Note we will only disable IOC if

Re: [PATCH] ARC: Add a knob to control usage of dual-issue

2018-01-18 Thread Vineet Gupta
On 01/18/2018 11:11 AM, Alexey Brodkin wrote: Hi Vineet, On Thu, 2018-01-18 at 10:54 -0800, Vineet Gupta wrote: On 01/18/2018 05:48 AM, Alexey Brodkin wrote: HS48 core starts with dual-issue enabled but in some cases like debugging as well as benchmarking it might be useful to disable dual

Re: [PATCH] ARC: Add a knob to control usage of dual-issue

2018-01-18 Thread Vineet Gupta
On 01/18/2018 05:48 AM, Alexey Brodkin wrote: HS48 core starts with dual-issue enabled but in some cases like debugging as well as benchmarking it might be useful to disable dual-issue for a particular run. Note: 1. To disable dual-issue user has to change a value of a global variable

Re: [PATCH] ARC: Allow disabling of prefetch operations for debugging purposes

2018-01-18 Thread Vineet Gupta
On 01/18/2018 05:48 AM, Alexey Brodkin wrote: Signed-off-by: Alexey Brodkin --- arch/arc/Kconfig | 5 + arch/arc/include/asm/processor.h | 11 +++ arch/arc/lib/memcpy-archs.S | 16 arch/arc/lib/memset-archs.S |

[GIT PULL] ARC updates for 4.15-rc7

2018-01-05 Thread Vineet Gupta
set in platform code ARC: [plat-axs103]: Set initial core pll output frequency ARC: [plat-axs103] refactor the quad core DT quirk code Sergey Senozhatsky (1): arc: do not use __print_symbol() Vineet Gupta (3): ARC: uaccess: dont use "l" gcc inline asm constraint modif

Re: [RFC] ARC: setup cpu possible mask according to status field in dts

2018-01-05 Thread Vineet Gupta
On 12/22/2017 11:08 AM, Eugeniy Paltsev wrote: As we have option in u-boot to set CPU mask for running linux, we want to pass information to kernel about CPU cores should be brought up. So we patch kernel dtb in u-boot to set CPUs status. On linux boot we setup cpu possible mask according to

Re: [PATCH 09/67] arc: remove CONFIG_ARC_PLAT_NEEDS_PHYS_TO_DMA

2018-01-05 Thread Vineet Gupta
On 12/29/2017 12:25 AM, Christoph Hellwig wrote: We always use the stub definitions, so remove the unused other code. Signed-off-by: Christoph Hellwig <h...@lst.de> Acked-by: Vineet Gupta <vgu...@synopsys.com> FWIW, it was removed and reintroduced as one of the customers want

Re: [PATCH] arch: drop duplicate exports of abort()

2018-01-03 Thread Vineet Gupta
On 01/02/2018 02:33 AM, Arnd Bergmann wrote: We now have exports in both architecture code in in common code, which causes a link failure when symbol versioning is eanbled, on four architectures: kernel/exit.o: In function `__crc_abort': exit.c:(*ABS*+0xc0e2ec8b): multiple definition of

[PATCH 0/2] ARC __builtin_trap handling

2017-12-20 Thread Vineet Gupta
Vineet Gupta (2): ARC: handle gcc generated __builtin_trap() ARC: handle gcc generated __builtin_trap for older compiler arch/arc/kernel/traps.c| 14 ++ arch/arc/kernel/troubleshoot.c | 3 +++ 2 files changed, 17 insertions(+) -- 2.7.4

[PATCH 1/2] ARC: handle gcc generated __builtin_trap()

2017-12-20 Thread Vineet Gupta
is terminated with a SEGV, for kernel mode die() called after register and stack dump. Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- arch/arc/kernel/traps.c| 6 ++ arch/arc/kernel/troubleshoot.c | 3 +++ 2 files changed, 9 insertions(+) diff --git a/arch/arc/kernel/traps.c b/ar

[PATCH 2/2] ARC: handle gcc generated __builtin_trap for older compiler

2017-12-20 Thread Vineet Gupta
ARC gcc prior to GNU 2018.03 release didn't have a target specific __builtin_trap() implementation, generating default abort() call. Implement the abort() call - emulating what newer gcc does for the same, as suggested by Arnd. Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- ar

Re: [PATCH] bug.h: Work around GCC PR82365 in BUG()

2017-12-19 Thread Vineet Gupta
orm barrel-shift swap minmax swape BPU        : partial match, cache:2048, Predict Table:16384 BUG: failure at ../arch/arc/mm/tlb.c:827/arc_mmu_init()! Tested-by: Vineet Gupta <vgu...@synopsys.com> FWIW newer ARC gcc actually implements the builtin so we get a trap 5 instruction now, vs

Re: [PATCH v2] arch: define weak abort

2017-12-19 Thread Vineet Gupta
On 12/12/2017 02:49 PM, Sudip Mukherjee wrote: gcc toggle -fisolate-erroneous-paths-dereference (default at -O2 onwards) isolates faulty code paths such as null pointer access, divide by zero etc. If gcc port doesnt implement __builtin_trap, an abort() is generated which causes kernel link

Re: [PATCH] bug.h: Work around GCC PR82365 in BUG()

2017-12-19 Thread Vineet Gupta
On 12/19/2017 03:41 AM, Arnd Bergmann wrote: Looking at functions with large stack frames across all architectures led me discovering that BUG() suffers from the same problem as fortify_panic(), which I've added a workaround for already. In short, variables that go out of scope by calling a

Re: [PATCH 0/4] ARC: Set initial core pll output frequency via DTS

2017-12-15 Thread Vineet Gupta
On 12/09/2017 05:59 AM, Eugeniy Paltsev wrote: Set initial core pll output frequency on HSDK and AXS103 via "assigned-clock-rates" property in device tree. It will be applied at the core pll driver probing. Eugeniy Paltsev (4): ARC: [plat-hsdk]: Set initial core pll output frequency ARC:

Re: [PATCH] arch: define weak abort

2017-12-12 Thread Vineet Gupta
On 12/11/2017 01:26 PM, Sudip Mukherjee wrote: gcc was generating abort due to 'divide by zero' and if it is not defined in the toolchain the build fails. Currently 'frv' and 'arc' are failing. Previously other arch was also broken like m32r was fixed by d22e3d69ee1a ("m32r: fix build

Re: [PATCH] ARC: Force disable IOC if ioc_enable=0

2017-12-12 Thread Vineet Gupta
On 12/05/2017 02:19 AM, Alexey Brodkin wrote: U-Boot enables and uses IOC so if we don't want to use it in the kernel we need to _disable_ it for real. This is in comparison to what we do today based on "ioc_enable" flag - if it is set to 0 we just _dont_enable_ IOC which effectively keeps IOC

Re: [PATCH 13/13] arc: do not use __print_symbol()

2017-12-11 Thread Vineet Gupta
printk("%pS") call. Signed-off-by: Sergey Senozhatsky <sergey.senozhat...@gmail.com> Cc: Vineet Gupta <vgu...@synopsys.com> Applied to arc for-curr Thx, -Vineet --- arch/arc/kernel/stacktrace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/a

[PATCH 2/2] ARC: provide for gcc "isolate path" induced generated abort calls

2017-12-08 Thread Vineet Gupta
the builtin, but we need to handle this error for older toolchains. The code in question triggering gcc is in lib/mpi/mpih-div.o Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- arch/arc/kernel/setup.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/arch/arc/kernel/setup.c b/ar

[PATCH 1/2] ARC: uaccess: dont use "l" inline as constraint

2017-12-08 Thread Vineet Gupta
This constraint has been removed from gcc There was an earlier fix 3c7c7a2fc8811 which fixed this in delay.h but somehow missed this one as gcc change had not made its way into production toolchains Cc: sta...@vger.kernel.org Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- ar

Re: [PATCH 0/4] ARC: Set initial core pll output frequency via DTS

2017-12-06 Thread Vineet Gupta
On 11/27/2017 10:56 AM, Eugeniy Paltsev wrote: Set initial core pll output frequency on HSDK and AXS103 via "assigned-clock-rates" property in device tree. It will be applied at the core pll driver probing. Can you repost - CC'ing Stephen boyd and RobH ? -Vineet Eugeniy Paltsev (4):

Re: [PATCH] frv: fix build failure

2017-12-06 Thread Vineet Gupta
On 12/03/2017 02:32 PM, Sudip Mukherjee wrote: On Mon, Nov 27, 2017 at 10:25:16AM -0800, Vineet Gupta wrote: +CC linux-arch, Arnd On 11/23/2017 09:17 AM, Alexey Brodkin wrote: Hi Sudip, On Tue, 2017-11-21 at 22:10 +, Sudip Mukherjee wrote: I understand the case/need for adding

Re: [PATCH] ARC: Enable machine_desc->init_per_cpu for non-SMP configs

2017-11-30 Thread Vineet Gupta
On 11/29/2017 12:21 AM, Alexey Brodkin wrote: As of today we assumed that "machine_desc->init_per_cpu" calls are only usable on SMP systems when we want to run some piece of code on early boot for each and every core, I guess assumption was we have "machine_desc->init_early" for single-core

Re: [PATCH] frv: fix build failure

2017-11-27 Thread Vineet Gupta
+CC linux-arch, Arnd On 11/23/2017 09:17 AM, Alexey Brodkin wrote: Hi Sudip, On Tue, 2017-11-21 at 22:10 +, Sudip Mukherjee wrote: The frv defconfig build is failing with the error: lib/mpi/mpih-div.o: In function `mpihelp_divrem': mpih-div.c:(.text+0x30c): undefined reference to `abort'

[GIT PULL] ARC updates for 4.15-rc1

2017-11-22 Thread Vineet Gupta
ew micro-arch gizmos - axs10x platform wiring up reset driver merged in this cycle - ARC perf driver optimizations Eugeniy Paltsev (1): ARC: [plat-axs10x] DTS: Add reset controller node to manage ethernet reset Vineet Gupta (

Re: [PATCH 4/4] ARCv2: entry: Reduce perf intr return path

2017-11-21 Thread Vineet Gupta
On 11/17/2017 03:42 PM, Vineet Gupta wrote: What do you (on ARC) do about irq_work ? So the reason I'm asking is that some architectures that don't have NMIs call irq_work_run() at the very end of their perf-interrupt handler (ARM does this for instance). But on ARC, we don't call

Re: [PATCH 0/4] ARC perf updates

2017-11-21 Thread Vineet Gupta
On 11/07/2017 02:13 PM, Vineet Gupta wrote: Hi, Found these when cleaning up some old branches. The only controversial one could be the last one. Thx, -Vineet Vineet Gupta (4): ARCv2: perf: tweak overflow interrupt ARCv2: perf: optimize given that num counters <= 32 ARC: perf: av

Re: [PATCH 4/4] ARCv2: entry: Reduce perf intr return path

2017-11-17 Thread Vineet Gupta
But I was choosing to ignore it mainly to reduce the overhead of a perf intr in general. A subsequent real interrupt could go thru thru the gyrations of preemption etc. So that's dangerous thinking... People that run a PREEMPT kernel generally tend to care about latency (esp. when combined

Re: [PATCH 4/4] ARCv2: entry: Reduce perf intr return path

2017-11-14 Thread Vineet Gupta
On 11/14/2017 02:28 AM, Peter Zijlstra wrote: On Tue, Nov 07, 2017 at 02:13:04PM -0800, Vineet Gupta wrote: In the more likely case of returning to kernel from perf interrupt, do a fast path returning w/o bothering about CONFIG_PREEMPT etc I think this needs more explaining and certainly also

Re: [PATCH 0/4] ARC perf updates

2017-11-13 Thread Vineet Gupta
On 11/07/2017 02:13 PM, Vineet Gupta wrote: Hi, Found these when cleaning up some old branches. The only controversial one could be the last one. Thx, -Vineet Vineet Gupta (4): ARCv2: perf: tweak overflow interrupt ARCv2: perf: optimize given that num counters <= 32 ARC: perf: av

[PATCH 3/4] ARC: perf: avoid vmalloc backed mmap

2017-11-07 Thread Vineet Gupta
: 35.060 | ... | Performance counter stats for 'hackbench' (5 runs): Before: 399235 dTLB-load-misses ( +- 2.08% ) After : 397676 dTLB-load-misses ( +- 2.27% ) Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- arch/arc/Kconfig | 2 +- 1 file changed, 1 insertion

[PATCH 1/4] ARCv2: perf: tweak overflow interrupt

2017-11-07 Thread Vineet Gupta
Current perf ISR loops thru all 32 counters, checking for each if it caused the interrupt. Instead only loop thru counters which actually interrupted (typically 1). Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- arch/arc/kernel/perf_event.c | 24 ++-- 1 file c

[PATCH 4/4] ARCv2: entry: Reduce perf intr return path

2017-11-07 Thread Vineet Gupta
In the more likely case of returning to kernel from perf interrupt, do a fast path returning w/o bothering about CONFIG_PREEMPT etc However, if returning to user space, need do go thru the usual gyrations, as check for pending signals is an absolute must. Signed-off-by: Vineet Gupta <

[PATCH 2/4] ARCv2: perf: optimize given that num counters <= 32

2017-11-07 Thread Vineet Gupta
use ffz primitive which maps to ARCv2 instruction, vs. non atomic __test_and_set_bit It is unlikely if we will even have more than 32 counters, but still add a BUILD_BUG to catch that Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- arch/arc/kernel/perf_event.c | 16 +++--

[PATCH 0/4] ARC perf updates

2017-11-07 Thread Vineet Gupta
Hi, Found these when cleaning up some old branches. The only controversial one could be the last one. Thx, -Vineet Vineet Gupta (4): ARCv2: perf: tweak overflow interrupt ARCv2: perf: optimize given that num counters <= 32 ARC: perf: avoid vmalloc backed mmap ARCv2: entry: Reduce p

Re: [PATCH] ARCv2: Accomodate NS48 MMUv5 by releaxing MMU ver checking

2017-11-07 Thread Vineet Gupta
On 11/07/2017 07:33 AM, Alexey Brodkin wrote: Hi Vineet, Subject contains one typo: NS48 -> HS48. On Mon, 2017-11-06 at 11:30 -0800, Vineet Gupta wrote: HS48 cpus will have a new MMUv5, although Linux is currently not explicitly supporting the newer features (so remains at V4). The exist

[PATCH] ARCv2: Accomodate NS48 MMUv5 by releaxing MMU ver checking

2017-11-06 Thread Vineet Gupta
current kernel support level to work with new hardware. Also while at it, move the ancient MMU related code to under ARCompact builds as baseline MMU for HS cpus is v4. Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- arch/arc/mm/tlb.

Re: [PATCH v2] ARC: reset: introduce AXS10x reset driver

2017-10-27 Thread Vineet Gupta
Hi Eugeniy, Ping ! Can you please follow up the ARC patch to use the driver for 4.15. Thx, -Vineet On 10/09/2017 11:25 AM, Vineet Gupta wrote: On 10/04/2017 03:09 AM, Philipp Zabel wrote: Hi Vineet, On Mon, 2017-09-18 at 18:51 +0200, Philipp Zabel wrote: Will it be OK for you to apply

[GIt PULL] ARC fixes for 4.14-rc7

2017-10-27 Thread Vineet Gupta
SDK platform - module build error for !LLSC config Eugeniy Paltsev (1): ARC: [plat-hsdk] Increase SDIO CIU frequency to 5000Hz Vineet Gupta (2): ARC: [plat-hsdk] select CONFIG_RESET_HSDK from Kconfig ARC: unb

Re: [PATCH] CLK: ARC: Set initial pll output frequency specified in device tree

2017-10-26 Thread Vineet Gupta
Hi folks, On 09/29/2017 06:13 AM, Eugeniy Paltsev wrote: Add option to set initial output frequency of plls via "clock-frequency" property in pll's device tree node. This frequency will be set while pll driver probed. The usage example is setting CPU clock frequency on boot See discussion:

Re: [PATCH] ARC: [plat-hsdk]: Increase SDIO CIU frequency to 50000000Hz

2017-10-11 Thread Vineet Gupta
-by-8) to the minimum possible value of the divisor (div-by-2) in HSDK platform code. Reported-by: Vineet Gupta <vgu...@synopsys.com> Tested-by: Vineet Gupta <vgu...@synopsys.com> Signed-off-by: Eugeniy Paltsev <eugeniy.palt...@synopsys.com> Thx for the quick fix - I've applied i

Re: [RFC] ARC: [plat-hsdk]: Increase SDIO CIU frequency to 50000000Hz

2017-10-11 Thread Vineet Gupta
On 10/10/2017 10:29 AM, Alexey Brodkin wrote: Hi Vineet, On Tue, 2017-10-10 at 10:09 -0700, Vineet Gupta wrote: On 10/10/2017 09:11 AM, Eugeniy Paltsev wrote: Increase SDIO CIU frequency from 1250Hz to 5000Hz by switching from the default divisor value (div-by-8) to the minimum

Re: [RFC] ARC: [plat-hsdk]: Increase SDIO CIU frequency to 50000000Hz

2017-10-10 Thread Vineet Gupta
On 10/10/2017 09:11 AM, Eugeniy Paltsev wrote: Increase SDIO CIU frequency from 1250Hz to 5000Hz by switching from the default divisor value (div-by-8) to the minimum possible value of the divisor (div-by-2) in HSDK platform code. Please describe the problem first not the solution.

Re: [PATCH v2] ARC: reset: introduce AXS10x reset driver

2017-10-09 Thread Vineet Gupta
On 10/04/2017 03:09 AM, Philipp Zabel wrote: Hi Vineet, On Mon, 2017-09-18 at 18:51 +0200, Philipp Zabel wrote: Will it be OK for you to apply the corresponding DT update for platform - that way I don't have to keep track of when ur branch hits mainline etc. The chances of any ensuing

[GIT PULL] ARC updates for 4.14-rc4

2017-10-06 Thread Vineet Gupta
ARC: [plat-hsdk]: Add reset controller node to manage ethernet reset Masahiro Yamada (1): arc: remove redundant UTS_MACHINE define in arch/arc/Makefile Vineet Gupta (4): ARC: [plat-eznps] Update platform maintainer as Noam left ARC: boot log: decontaminate ARCv2 ISA_CONFIG regis

Re: [PATCH v3] ARC: [plat-hsdk]: Add reset controller node to manage ethernet reset

2017-10-05 Thread Vineet Gupta
Hi Eugeniy, On 09/22/2017 09:49 AM, Eugeniy Paltsev wrote: DW ethernet controller on HSDK hangs sometimes after SW reset, so add reset node to make possible to reset DW ethernet controller HW. Signed-off-by: Eugeniy Paltsev --- Changes v2 -> v3: * Remove v1

Re: [PATCH v2] ARC: reset: introduce AXS10x reset driver

2017-10-04 Thread Vineet Gupta
Hi Philipp, On 10/04/2017 03:09 AM, Philipp Zabel wrote: Maybe it is better to do this the other way around? I can put this patch on a stable reset/arc branch for you to merge before applying the reset DT updates. Have you come to a decision on this? Just in case, I have removed the AXS10x

[PATCH 2/2] ARCv2: boot log: identify HS48 cores (dual issue)

2017-09-29 Thread Vineet Gupta
Signed-off-by: Vineet Gupta <vgu...@synopsys.com> --- arch/arc/include/asm/arcregs.h | 3 ++- arch/arc/kernel/setup.c| 17 ++--- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/arch/arc/include/asm/arcregs.h b/arch/arc/include/asm/arcregs.h index b71d84

[PATCH 1/2] ARC: boot log: decontaminate ARCv2 ISA_CONFIG register

2017-09-29 Thread Vineet Gupta
bits for atomics and stack check). At runtime, we treat ARCv2 ISA info as a generic palceholder but populate it correctly depending on ARC700 or HS. This paves way for adding more HS specific bits in isa info which was colliding with the extra bits for arc700. Signed-off-by: Vineet Gupta <

Re: [PATCH] ARC: [plat-hsdk]: Temporary fix to set CPU frequency to 1GHz

2017-09-29 Thread Vineet Gupta
On 09/28/2017 07:33 AM, Eugeniy Paltsev wrote: Add temporary fix to HSDK platform code to setup CPU frequency to 1GHz on early boot. We can remove this fix when smart hsdk pll driver will be introduced, see discussion: https://www.mail-archive.com/linux-snps-arc@lists.infradead.org/msg02689.html

Re: [PATCH] ARC: reset: remove the misleading v1 suffix all over

2017-09-27 Thread Vineet Gupta
Hi Philipp, On 09/14/2017 03:44 AM, Philipp Zabel wrote: On Mon, 2017-09-11 at 09:33 -0700, Vineet Gupta wrote: On 09/11/2017 03:28 AM, Philipp Zabel wrote: Hi Vineet, [added Eugeniy to Cc] On Thu, 2017-08-31 at 11:06 -0700, Vineet Gupta wrote: There is no plan yet to do a v2 board

Re: [PATCH v3] ARC: [plat-hsdk]: Add reset controller node to manage ethernet reset

2017-09-27 Thread Vineet Gupta
On 09/22/2017 09:49 AM, Eugeniy Paltsev wrote: DW ethernet controller on HSDK hangs sometimes after SW reset, so add reset node to make possible to reset DW ethernet controller HW. Signed-off-by: Eugeniy Paltsev --- Changes v2 -> v3: * Remove v1 suffix as we

Re: [PATCH] arch: remove unused *_segments() macros/functions

2017-09-22 Thread Vineet Gupta
ssor.h| 3 --- Acked-by: Vineet Gupta <vgu...@synopsys.com> [for arch/arc] Thx, -Vineet

Re: [PATCH] arc: remove redundant UTS_MACHINE define in arch/arc/Makefile

2017-09-20 Thread Vineet Gupta
On 09/20/2017 04:25 AM, Masahiro Yamada wrote: The top-level Makefile sets the default of UTS_MACHINE to $(ARCH). If ARCH and UTS_MACHINE match, arch/$(ARCH)/Makefile need not specify UTS_MACHINE explicitly. Signed-off-by: Masahiro Yamada Thx Masahiro san !

Re: [PATCH] reset: Restrict RESET_HSDK_V1 to ARC_SOC_HSDK or COMPILE_TEST

2017-09-19 Thread Vineet Gupta
On 09/11/2017 05:22 AM, Geert Uytterhoeven wrote: The HSDK reset driver is only useful when building for an ARC HSDK platform. While at it, drop the "default n", as that is the default. Fixes: e0be864f14240cb1 ("ARC: reset: introduce HSDKv1 reset driver") Signed-off-by: Geert Uytterhoeven

Re: [PATCH v2] ARC: reset: introduce AXS10x reset driver

2017-09-18 Thread Vineet Gupta
Hi Philipp, On 09/18/2017 05:07 AM, Philipp Zabel wrote: On Thu, 2017-09-14 at 17:28 +0300, Eugeniy Paltsev wrote: ARC AXS10x boards support custom IP-block which allows to control reset signals of selected peripherals. For example DW GMAC, etc... This block is controlled via memory-mapped

  1   2   3   4   5   6   7   8   9   10   >