[PATCH 2/2] sparc: Implement update_arch_nmi_watchdog

2016-10-06 Thread Babu Moger
interface. Example commands. To enable: echo 1 > /proc/sys/kernel/nmi_watchdog To disable: echo 0 > /proc/sys/kernel/nmi_watchdog It can also achieved using the sysctl parameter kernel.nmi_watchdog Signed-off-by: Babu Moger --- arch/sparc/kernel/nmi.c | 26 ++ 1

Re: [PATCH 1/2] watchdog: Introduce update_arch_nmi_watchdog

2016-10-07 Thread Babu Moger
On 10/6/2016 11:34 PM, Sam Ravnborg wrote: On Thu, Oct 06, 2016 at 03:16:42PM -0700, Babu Moger wrote: Currently we do not have a way to enable/disable arch specific watchdog handlers if it was implemented by any of the architectures. This patch introduces new function

Re: [PATCH v2 RESEND] drivers/usb: Skip auto handoff for TI and RENESAS usb controllers

2016-10-24 Thread Babu Moger
On 10/24/2016 5:54 AM, Yoshihiro Shimoda wrote: Hi, From: Mathias Nyman Sent: Monday, October 24, 2016 6:58 PM On 22.10.2016 01:25, Babu Moger wrote: Never seen XHCI auto handoff working on TI and RENESAS cards. Eventually, we force handoff. This code forces the handoff unconditionally

Re: [PATCH v2 1/2] watchdog: Introduce arch_watchdog_nmi_enable and arch_watchdog_nmi_disable

2016-10-24 Thread Babu Moger
On 10/24/2016 10:19 AM, Don Zickus wrote: On Fri, Oct 21, 2016 at 04:50:21PM -0500, Babu Moger wrote: Don, On 10/21/2016 2:19 PM, Andrew Morton wrote: On Fri, 21 Oct 2016 11:11:14 -0400 Don Zickus wrote: On Thu, Oct 20, 2016 at 08:25:27PM -0700, Andrew Morton wrote: On Thu, 20 Oct 2016

Re: [PATCH v2 RESEND] drivers/usb: Skip auto handoff for TI and RENESAS usb controllers

2016-10-25 Thread Babu Moger
On 10/25/2016 1:51 AM, Mathias Nyman wrote: On 24.10.2016 17:52, Babu Moger wrote: On 10/24/2016 5:54 AM, Yoshihiro Shimoda wrote: Hi, From: Mathias Nyman Sent: Monday, October 24, 2016 6:58 PM On 22.10.2016 01:25, Babu Moger wrote: Never seen XHCI auto handoff working on TI and RENESAS

[RFC PATCH 4/4] sparc: Implement watchdog_nmi_enable and watchdog_nmi_disable

2016-10-26 Thread Babu Moger
proc or sysctl interface. Example commands. To enable: echo 1 > /proc/sys/kernel/nmi_watchdog To disable: echo 0 > /proc/sys/kernel/nmi_watchdog It can also achieved using the sysctl parameter kernel.nmi_watchdog Signed-off-by: Babu Moger --- arch/sparc/kernel/nmi.c

[RFC PATCH 0/4] Clean up watchdog handlers

2016-10-26 Thread Babu Moger
such that architectures can override its definitions. Thanks to Don Zickus for his suggestions. Here is the previous discussion http://www.spinics.net/lists/sparclinux/msg16441.html Babu Moger (4): watchdog: Remove hardlockup handler references watchdog: Move shared definitions to nmi.h watchdog: Move

[RFC PATCH 2/4] watchdog: Move shared definitions to nmi.h

2016-10-26 Thread Babu Moger
Move shared macros and definitions to nmi.h so that watchdog.c, watchdog_hld.c or any other architecture specific handler can use those definitions. Signed-off-by: Babu Moger --- include/linux/nmi.h | 19 +++ kernel/watchdog.c | 25 - 2 files

[RFC PATCH 1/4] watchdog: Remove hardlockup handler references

2016-10-26 Thread Babu Moger
Separate hardlockup code from watchdog.c. It is mostly straight forward. Remove everything inside CONFIG_HARDLOCKUP_DETECTORS. This code will go to file watchdog_hld.c. We also define weak handlers watchdog_nmi_enable and watchdog_nmi_disable. Signed-off-by: Babu Moger --- kernel/watchdog.c

[RFC PATCH 3/4] watchdog: Move hardlockup detector to separate file

2016-10-26 Thread Babu Moger
Move hardlockup detector code to watchdog_hld.c. Also update the makefile accordigly. Signed-off-by: Babu Moger --- kernel/Makefile |1 + kernel/watchdog_hld.c | 238 + 2 files changed, 239 insertions(+), 0 deletions(-) create mode

[PATCH v2] arch/sparc: Avoid DCTI Couples

2017-03-17 Thread Babu Moger
, since not all implementations make that distinction, for optimal performance, a DCTI should not be placed in the instruction word immediately following an annulled branch-always instruction (BA,A or BPA,A)." Signed-off-by: Babu Moger Reviewed-by: Rob Gardner --- arch/sparc/kernel/hea

[PATCH 1/6] kernel/locking: Fix compile error with qrwlock.c

2017-05-18 Thread Babu Moger
/spinlock_types.h:5:3: error: #error "please don't include this file directly" Re-arrange the includes in qrwlock_types.h and also include spinlock.h in qrwlock.c to fix it. This should also help other architectures when queued rwlock is enabled. Signed-off-by: Babu Moger Reviewed-by: H

[PATCH 5/6] arch/sparc: Introduce xchg16 for SPARC

2017-05-18 Thread Babu Moger
xchg16. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Steven Sistare Reviewed-by: Shannon Nelson Reviewed-by: Jane Chu Reviewed-by: Vijay Kumar --- arch/sparc/include/asm/cmpxchg_64.h | 49 +++--- 1 files changed, 39 insertions(+), 10 deletions

[PATCH 6/6] arch/sparc: Enable queued spinlock support for SPARC

2017-05-18 Thread Babu Moger
This patch makes the necessary changes in SPARC architecture to enable queued spinlock support. Here are some of the earlier discussions about this feature. https://lwn.net/Articles/561775/ https://lwn.net/Articles/590243/ Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu

[PATCH 3/6] arch/sparc: Introduce cmpxchg_u8 SPARC

2017-05-18 Thread Babu Moger
-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Steve Sistare Reviewed-by: Shannon Nelson Reviewed-by: Jane Chu Reviewed-by: Vijay Kumar --- arch/sparc/include/asm/cmpxchg_64.h | 29 + 1 files changed, 29 insertions(+), 0 deletions(-) diff --git a/arch

[PATCH 4/6] arch/sparc: Enable queued rwlocks for SPARC

2017-05-18 Thread Babu Moger
Enable queued rwlocks for SPARC. Here are the discussions on this feature when this was introduced. https://lwn.net/Articles/572765/ https://lwn.net/Articles/582200/ Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar

[PATCH 2/6] arch/sparc: Define config parameter CPU_BIG_ENDIAN

2017-05-18 Thread Babu Moger
(u8 *)lock + 3 * IS_BUILTIN(CONFIG_CPU_BIG_ENDIAN); } Define CPU_BIG_ENDIAN for SPARC to fix it. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |4 1 files changed, 4 insertions

[PATCH 0/6] Enable queued rwlock and queued spinlock for SPARC

2017-05-18 Thread Babu Moger
324812.2+20.74 fserver IO 1200-2000 users 229538.87 284713.77 +24.03 Disk I/O results are little bit in negative territory. But majority of the performance changes are in positive and it is significant in some cases. Babu Moger (6): kernel/locking: Fix compile error

Re: [PATCH v2 1/7] kernel/locking: Fix compile error with qrwlock.c

2017-05-22 Thread Babu Moger
On 5/22/2017 2:03 PM, David Miller wrote: From: Babu Moger Date: Fri, 19 May 2017 18:16:55 -0600 Some architectures use the following guard in include file "asm/spinlock_types.h" to discourage including the file directly. Saw these compile errors on SPARC when queued rwlo

[PATCH v3 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN

2017-05-23 Thread Babu Moger
(u8 *)lock + 3 * IS_BUILTIN(CONFIG_CPU_BIG_ENDIAN); } Define CPU_BIG_ENDIAN for SPARC to fix it. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |4 1 files changed, 4 insertions

[PATCH v3 6/7] arch/sparc: Introduce xchg16 for SPARC

2017-05-23 Thread Babu Moger
xchg16. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Steven Sistare Reviewed-by: Shannon Nelson Reviewed-by: Jane Chu Reviewed-by: Vijay Kumar --- arch/sparc/include/asm/cmpxchg_64.h | 49 +++--- 1 files changed, 39 insertions(+), 10 deletions

[PATCH v3 0/7] Enable queued rwlock and queued spinlock for SPARC

2017-05-23 Thread Babu Moger
nitial version Babu Moger (7): arch/sparc: Remove the check #ifndef __LINUX_SPINLOCK_TYPES_H kernel/locking: Fix compile error with qrwlock.c arch/sparc: Define config parameter CPU_BIG_ENDIAN arch/sparc: Introduce cmpxchg_u8 SPARC arch/sparc: Enable queued rwlocks for SPARC arch/sparc: Int

[PATCH v3 1/7] arch/sparc: Remove the check #ifndef __LINUX_SPINLOCK_TYPES_H

2017-05-23 Thread Babu Moger
ndif Remove this un-necessary "ifndef __LINUX_SPINLOCK_TYPES_H" stanza from SPARC. Signed-off-by: Babu Moger Suggested-by: David Miller --- arch/sparc/include/asm/spinlock_types.h |4 1 files changed, 0 insertions(+), 4 deletions(-) diff --git a/arch/sparc/include/asm/spinlock

[PATCH v3 4/7] arch/sparc: Introduce cmpxchg_u8 SPARC

2017-05-23 Thread Babu Moger
-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Steve Sistare Reviewed-by: Shannon Nelson Reviewed-by: Jane Chu Reviewed-by: Vijay Kumar --- arch/sparc/include/asm/cmpxchg_64.h | 29 + 1 files changed, 29 insertions(+), 0 deletions(-) diff --git a/arch

[PATCH v3 7/7] arch/sparc: Enable queued spinlock support for SPARC

2017-05-23 Thread Babu Moger
are replaced by the function in Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |1 + arch/sparc/include/asm/qspinlock.h |7 +++ arch/sparc/include/asm/spinlock_64.h

[PATCH v3 2/7] kernel/locking: Fix compile error with qrwlock.c

2017-05-23 Thread Babu Moger
: implicit declaration of function ‘arch_spin_unlock’ make[4]: *** [kernel/locking/qrwlock.o] Error 1 Include spinlock.h in qrwlock.c to fix it. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- kernel/locking

[PATCH v3 5/7] arch/sparc: Enable queued rwlocks for SPARC

2017-05-23 Thread Babu Moger
in include/asm-generic/qrwlock.h Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |1 + arch/sparc/include/asm/qrwlock.h|7 ++ arch/sparc/include/asm/spinlock_64.h

Re: [PATCH v3 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN

2017-05-24 Thread Babu Moger
On 5/24/2017 4:48 AM, Geert Uytterhoeven wrote: On Tue, May 23, 2017 at 11:45 PM, Babu Moger wrote: Found this problem while enabling queued rwlock on SPARC. The parameter CONFIG_CPU_BIG_ENDIAN is used to clear the specific byte in qrwlock structure. Without this parameter, we clear the wrong

Re: CPU_BIG_ENDIAN in generic code (was: Re: [PATCH v3 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN)

2017-05-24 Thread Babu Moger
Arnd, On 5/24/2017 5:18 AM, Arnd Bergmann wrote: On Wed, May 24, 2017 at 11:59 AM, Geert Uytterhoeven wrote: On Tue, May 23, 2017 at 11:45 PM, Babu Moger wrote: Found this problem while enabling queued rwlock on SPARC. The parameter CONFIG_CPU_BIG_ENDIAN is used to clear the specific byte

Re: CPU_BIG_ENDIAN in generic code (was: Re: [PATCH v3 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN)

2017-05-24 Thread Babu Moger
On 5/24/2017 10:09 AM, Arnd Bergmann wrote: On Wed, May 24, 2017 at 4:45 PM, Babu Moger wrote: On 5/24/2017 5:18 AM, Arnd Bergmann wrote: On Wed, May 24, 2017 at 11:59 AM, Geert Uytterhoeven wrote: On Tue, May 23, 2017 at 11:45 PM, Babu Moger wrote: include/asm-generic/qrwlock.h is also

[PATCH v4 1/7] arch/sparc: Remove the check #ifndef __LINUX_SPINLOCK_TYPES_H

2017-05-24 Thread Babu Moger
ndif Remove this un-necessary "ifndef __LINUX_SPINLOCK_TYPES_H" stanza from SPARC. Signed-off-by: Babu Moger Suggested-by: David Miller --- arch/sparc/include/asm/spinlock_types.h |4 1 files changed, 0 insertions(+), 4 deletions(-) diff --git a/arch/sparc/include/asm/spinlock

[PATCH v4 4/7] arch/sparc: Introduce cmpxchg_u8 SPARC

2017-05-24 Thread Babu Moger
-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Steve Sistare Reviewed-by: Shannon Nelson Reviewed-by: Jane Chu Reviewed-by: Vijay Kumar --- arch/sparc/include/asm/cmpxchg_64.h | 29 + 1 files changed, 29 insertions(+), 0 deletions(-) diff --git a/arch

[PATCH v4 6/7] arch/sparc: Introduce xchg16 for SPARC

2017-05-24 Thread Babu Moger
xchg16. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Steven Sistare Reviewed-by: Shannon Nelson Reviewed-by: Jane Chu Reviewed-by: Vijay Kumar --- arch/sparc/include/asm/cmpxchg_64.h | 49 +++--- 1 files changed, 39 insertions(+), 10 deletions

[PATCH v4 2/7] kernel/locking: Fix compile error with qrwlock.c

2017-05-24 Thread Babu Moger
: implicit declaration of function ‘arch_spin_unlock’ make[4]: *** [kernel/locking/qrwlock.o] Error 1 Include spinlock.h in qrwlock.c to fix it. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- kernel/locking

[PATCH v4 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN

2017-05-24 Thread Babu Moger
(u8 *)lock + 3 * IS_BUILTIN(CONFIG_CPU_BIG_ENDIAN); } Define CPU_BIG_ENDIAN for SPARC to fix it. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |3 +++ 1 files changed, 3 insertions

[PATCH v4 0/7] Enable queued rwlock and queued spinlock for SPARC

2017-05-24 Thread Babu Moger
s defined now in qrwlock.h. 4. Removed check for CONFIG_QUEUED_SPINLOCKS in SPARC64 as it is the default definition now for SPARC64 now. Cleaned-up the previous arch_spin_xxx definitions as it is defined in qspinlock.h. v1: Initial version Babu Moger (7): arch/sparc: Remove the chec

[PATCH v4 7/7] arch/sparc: Enable queued spinlock support for SPARC

2017-05-24 Thread Babu Moger
are replaced by the function in Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |1 + arch/sparc/include/asm/qspinlock.h |7 +++ arch/sparc/include/asm/spinlock_64.h

[PATCH v4 5/7] arch/sparc: Enable queued rwlocks for SPARC

2017-05-24 Thread Babu Moger
in include/asm-generic/qrwlock.h Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |1 + arch/sparc/include/asm/qrwlock.h|7 ++ arch/sparc/include/asm/spinlock_64.h

Re: CPU_BIG_ENDIAN in generic code (was: Re: [PATCH v3 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN)

2017-05-25 Thread Babu Moger
Hi Arnd, Here is the draft patch. Some questions below. On 5/24/2017 5:18 AM, Arnd Bergmann wrote: On Wed, May 24, 2017 at 11:59 AM, Geert Uytterhoeven wrote: On Tue, May 23, 2017 at 11:45 PM, Babu Moger wrote: Found this problem while enabling queued rwlock on SPARC. The parameter

Re: CPU_BIG_ENDIAN in generic code (was: Re: [PATCH v3 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN)

2017-05-25 Thread Babu Moger
On 5/25/2017 3:09 PM, Arnd Bergmann wrote: On Thu, May 25, 2017 at 4:51 PM, Babu Moger wrote: On 5/24/2017 5:18 AM, Arnd Bergmann wrote: I guess the time is ripe for adding (both) symbols to all architectures? Good idea. I think we can do most of this by adding a few lines to arch/Kconfig

Re: CPU_BIG_ENDIAN in generic code (was: Re: [PATCH v3 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN)

2017-05-25 Thread Babu Moger
On 5/25/2017 5:27 PM, Max Filippov wrote: On Wed, May 24, 2017 at 3:18 AM, Arnd Bergmann wrote: On Wed, May 24, 2017 at 11:59 AM, Geert Uytterhoeven wrote: I guess the time is ripe for adding (both) symbols to all architectures? Good idea. I think we can do most of this by adding a few

Re: [PATCH 2/6] arch/sparc: Define config parameter CPU_BIG_ENDIAN

2017-05-19 Thread Babu Moger
On 5/18/2017 9:26 PM, David Miller wrote: From: Babu Moger Date: Thu, 18 May 2017 18:36:06 -0600 @@ -91,6 +91,10 @@ config ARCH_DEFCONFIG config ARCH_PROC_KCORE_TEXT def_bool y +config CPU_BIG_ENDIAN + bool + default y if SPARC64 + 32-bit sparc is big-endian too

Re: [PATCH 1/6] kernel/locking: Fix compile error with qrwlock.c

2017-05-19 Thread Babu Moger
On 5/18/2017 9:27 PM, David Miller wrote: From: Babu Moger Date: Thu, 18 May 2017 18:36:05 -0600 Seeing this error on SPARC while compiling qrwlock.c. CC kernel/locking/qrwlock.o In file included from ./include/asm-generic/qrwlock_types.h:5, from ./arch/sparc

Re: [PATCH 4/6] arch/sparc: Enable queued rwlocks for SPARC

2017-05-19 Thread Babu Moger
On 5/18/2017 9:31 PM, David Miller wrote: From: Babu Moger Date: Thu, 18 May 2017 18:36:08 -0600 @@ -82,6 +82,7 @@ config SPARC64 select HAVE_ARCH_AUDITSYSCALL select ARCH_SUPPORTS_ATOMIC_RMW select HAVE_NMI + select ARCH_USE_QUEUED_RWLOCKS If you

Re: [PATCH 6/6] arch/sparc: Enable queued spinlock support for SPARC

2017-05-19 Thread Babu Moger
On 5/18/2017 9:32 PM, David Miller wrote: From: Babu Moger Date: Thu, 18 May 2017 18:36:10 -0600 @@ -83,6 +83,7 @@ config SPARC64 select ARCH_SUPPORTS_ATOMIC_RMW select HAVE_NMI select ARCH_USE_QUEUED_RWLOCKS + select ARCH_USE_QUEUED_SPINLOCKS config

Re: [PATCH 4/6] arch/sparc: Enable queued rwlocks for SPARC

2017-05-19 Thread Babu Moger
On 5/19/2017 4:03 AM, Peter Zijlstra wrote: On Thu, May 18, 2017 at 10:31:13PM -0400, David Miller wrote: From: Babu Moger Date: Thu, 18 May 2017 18:36:08 -0600 @@ -82,6 +82,7 @@ config SPARC64 select HAVE_ARCH_AUDITSYSCALL select ARCH_SUPPORTS_ATOMIC_RMW select

[PATCH v2 5/7] arch/sparc: Enable queued rwlocks for SPARC

2017-05-19 Thread Babu Moger
in include/asm-generic/qrwlock.h Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |1 + arch/sparc/include/asm/qrwlock.h|7 ++ arch/sparc/include/asm/spinlock_64.h

[PATCH v2 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN

2017-05-19 Thread Babu Moger
(u8 *)lock + 3 * IS_BUILTIN(CONFIG_CPU_BIG_ENDIAN); } Define CPU_BIG_ENDIAN for SPARC to fix it. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |4 1 files changed, 4 insertions

[PATCH v2 4/7] arch/sparc: Introduce cmpxchg_u8 SPARC

2017-05-19 Thread Babu Moger
-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Steve Sistare Reviewed-by: Shannon Nelson Reviewed-by: Jane Chu Reviewed-by: Vijay Kumar --- arch/sparc/include/asm/cmpxchg_64.h | 29 + 1 files changed, 29 insertions(+), 0 deletions(-) diff --git a/arch

[PATCH v2 1/7] kernel/locking: Fix compile error with qrwlock.c

2017-05-19 Thread Babu Moger
d include spinlock.h in qrwlock.c to fix it. Also will be removing this stanza from SPARC. Stay tuned. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- include/asm-generic/qrwlock_types.h |6 +++--- kern

[PATCH v2 6/7] arch/sparc: Introduce xchg16 for SPARC

2017-05-19 Thread Babu Moger
xchg16. Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Steven Sistare Reviewed-by: Shannon Nelson Reviewed-by: Jane Chu Reviewed-by: Vijay Kumar --- arch/sparc/include/asm/cmpxchg_64.h | 49 +++--- 1 files changed, 39 insertions(+), 10 deletions

[PATCH v2 2/7] arch/sparc: Remove the check #ifndef __LINUX_SPINLOCK_TYPES_H

2017-05-19 Thread Babu Moger
Remove the un-necessary "ifndef __LINUX_SPINLOCK_TYPES_H" stanza from SPARC. Signed-off-by: Babu Moger Suggested-by: David Miller --- arch/sparc/include/asm/spinlock_types.h |4 1 files changed, 0 insertions(+), 4 deletions(-) diff --git a/arch/sparc/include/asm/spinlock_

[PATCH v2 0/7] Enable queued rwlock and queued spinlock for SPARC

2017-05-19 Thread Babu Moger
ons as it is defined now in qrwlock.h. 4. Removed check for CONFIG_QUEUED_SPINLOCKS in SPARC64 as it is the default definition now for SPARC64 now. Cleaned-up the previous arch_spin_xxx definitions as it is defined in qspinlock.h. v1: Initial version Babu Moger (7): kernel/locking: Fix compile er

[PATCH v2 7/7] arch/sparc: Enable queued spinlock support for SPARC

2017-05-19 Thread Babu Moger
are replaced by the function in Signed-off-by: Babu Moger Reviewed-by: Håkon Bugge Reviewed-by: Jane Chu Reviewed-by: Shannon Nelson Reviewed-by: Vijay Kumar --- arch/sparc/Kconfig |1 + arch/sparc/include/asm/qspinlock.h |7 +++ arch/sparc/include/asm/spinlock_64.h

[PATCH v2 0/2] Introduce arch specific nmi enable, disable handlers

2016-10-13 Thread Babu Moger
to introduce new variable nmi_init_done to synchronize watchdog thread and kernel init thread. v1: Initial version. Discussion thread here http://www.mail-archive.com/linux-kernel@vger.kernel.org/msg1245427.html Babu Moger (2): watchdog: Introduce arch_watchdog_nmi_enable

Re: [PATCH 0/2] Introduce update_arch_nmi_watchdog for arch specific handlers

2016-10-13 Thread Babu Moger
On 10/7/2016 10:51 AM, Don Zickus wrote: On Thu, Oct 06, 2016 at 03:16:41PM -0700, Babu Moger wrote: During our testing we noticed that nmi watchdogs in sparc could not be disabled or enabled dynamically using sysctl/proc interface. Sparc uses its own arch specific nmi watchdogs

[PATCH v2 1/2] watchdog: Introduce arch_watchdog_nmi_enable and arch_watchdog_nmi_disable

2016-10-13 Thread Babu Moger
handlers. These functions are defined as weak as architectures can override their definitions to enable/disable nmi watchdog behaviour. Signed-off-by: Babu Moger --- kernel/watchdog.c | 65 +++- 1 files changed, 44 insertions(+), 21 deletions

[PATCH v2 2/2] sparc: Implement arch_watchdog_nmi_enable and arch_watchdog_nmi_disable

2016-10-13 Thread Babu Moger
watchdogs using proc or sysctl interface. Example commands. To enable: echo 1 > /proc/sys/kernel/nmi_watchdog To disable: echo 0 > /proc/sys/kernel/nmi_watchdog It can also achieved using the sysctl parameter kernel.nmi_watchdog Signed-off-by: Babu Moger --- arch/sparc/kernel/nmi.c

Re: [RFC PATCH 0/4] Clean up watchdog handlers

2016-10-31 Thread Babu Moger
On 10/31/2016 4:00 PM, Don Zickus wrote: On Wed, Oct 26, 2016 at 09:02:19AM -0700, Babu Moger wrote: This is an attempt to cleanup watchdog handlers. Right now, kernel/watchdog.c implements both softlockup and hardlockup detectors. Softlockup code is generic. Hardlockup code is arch specific

Re: [RFC PATCH 0/4] Clean up watchdog handlers

2016-10-31 Thread Babu Moger
On 10/31/2016 4:00 PM, Don Zickus wrote: On Wed, Oct 26, 2016 at 09:02:19AM -0700, Babu Moger wrote: This is an attempt to cleanup watchdog handlers. Right now, kernel/watchdog.c implements both softlockup and hardlockup detectors. Softlockup code is generic. Hardlockup code is arch specific

Re: [RFC PATCH 0/4] Clean up watchdog handlers

2016-11-01 Thread Babu Moger
On 11/1/2016 8:20 AM, Don Zickus wrote: On Mon, Oct 31, 2016 at 04:30:59PM -0500, Babu Moger wrote: On 10/31/2016 4:00 PM, Don Zickus wrote: On Wed, Oct 26, 2016 at 09:02:19AM -0700, Babu Moger wrote: This is an attempt to cleanup watchdog handlers. Right now, kernel/watchdog.c implements

[PATCH v2 0/3] Clean up watchdog handlers

2016-11-01 Thread Babu Moger
. is_hardlockup kind of generic most part. kernel/built-in.o: In function `watchdog_overflow_callback': watchdog_hld.c:(.text+0x56940): undefined reference to `sysctl_hardlockup_all_cpu_backtrace' Moved this definition to nmi.h. v1: Initial version Babu Moger (3): watchdog: Move shared

[PATCH v2 2/3] watchdog: Move hardlockup detector to separate file

2016-11-01 Thread Babu Moger
Separate hardlockup code from watchdog.c and move it to watchdog_hld.c. It is mostly straight forward. Remove everything inside CONFIG_HARDLOCKUP_DETECTORS. This code will go to file watchdog_hld.c. Also update the makefile accordigly. Signed-off-by: Babu Moger --- kernel/Makefile |1

[PATCH v2 1/3] watchdog: Move shared definitions to nmi.h

2016-11-01 Thread Babu Moger
Move shared macros and definitions to nmi.h so that watchdog.c, new file watchdog_hld.c or any other architecture specific handler can use those definitions. Signed-off-by: Babu Moger --- include/linux/nmi.h | 24 kernel/watchdog.c | 28

[PATCH v2 3/3] sparc: Implement watchdog_nmi_enable and watchdog_nmi_disable

2016-11-01 Thread Babu Moger
proc or sysctl interface. Example commands. To enable: echo 1 > /proc/sys/kernel/nmi_watchdog To disable: echo 0 > /proc/sys/kernel/nmi_watchdog It can also achieved using the sysctl parameter kernel.nmi_watchdog Signed-off-by: Babu Moger --- arch/sparc/kernel/nmi.c

Re: [PATCH 2/2] include: warn for inconsistent endian config definition

2017-06-12 Thread Babu Moger
-ci/linux/commits/Babu-Moger/Define-CPU_BIG_ENDIAN-or-warn-for-inconsistencies/20170610-200424 config: microblaze-mmu_defconfig (attached as .config) compiler: microblaze-linux-gcc (GCC) 6.2.0 reproduce: wget https://raw.githubusercontent.com/01org/lkp-tests/master/sbin/make.cross -O ~/bin

Re: [PATCH 2/2] include: warn for inconsistent endian config definition

2017-06-12 Thread Babu Moger
On 6/12/2017 3:51 PM, Arnd Bergmann wrote: On Mon, Jun 12, 2017 at 10:30 PM, Babu Moger wrote: Looks like microblaze can be configured to either little or big endian formats. How about adding a choice statement to address this. Here is my proposed patch. Hi Babu, This part looks fine

Re: [PATCH 2/2] include: warn for inconsistent endian config definition

2017-06-12 Thread Babu Moger
On 6/12/2017 3:58 PM, Max Filippov wrote: On Mon, Jun 12, 2017 at 1:51 PM, Arnd Bergmann wrote: That way, we don't have to guess what the toolchain does, but rather tell it to do whatever is configured, like we do for most other architectures. Unfortunately we can't do the same thing on

[PATCH v3 0/3] Define CPU_BIG_ENDIAN or warn for inconsistencies

2017-06-12 Thread Babu Moger
ion for microblaze. Updated the Makefile for microblaze(Suggested by Arnd Bergmann) to properly compile for the correct format. Updated acks. v1 -> v2: Updated the commit messages and acks. Babu Moger (3): arch: Define CPU_BIG_ENDIAN for all fixed big endian archs arch/microblaze: Add

[PATCH v3 2/3] arch/microblaze: Add choice for endianness and update Makefile

2017-06-12 Thread Babu Moger
microblaze architectures can be configured for either little or big endian formats. Add a choice option for the user to select the correct endian format(default to big endian). Also update the Makefile so toolchain can compile for the format it is configured for. Signed-off-by: Babu Moger

[PATCH v3 3/3] include: warn for inconsistent endian config definition

2017-06-12 Thread Babu Moger
is not defined on big endian architecture and also warn if it defined on little endian architectures. Here is our original discussion https://lkml.org/lkml/2017/5/24/620 Signed-off-by: Babu Moger Suggested-by: Arnd Bergmann Acked-by: Geert Uytterhoeven --- include/linux/byteorder/big_endian.h

[PATCH v3 1/3] arch: Define CPU_BIG_ENDIAN for all fixed big endian archs

2017-06-12 Thread Babu Moger
/earlycon.c drivers/tty/serial/serial_core.c Be aware that this may cause regressions if someone has worked-around problems in the above code already. Remove the work-around. Here is our original discussion https://lkml.org/lkml/2017/5/24/620 Signed-off-by: Babu Moger Suggested-by: Arnd Bergmann

Re: [PATCH 3/4] watchdog: Split up config options

2017-06-14 Thread Babu Moger
Hi Don, On 6/14/2017 9:09 AM, Don Zickus wrote: On Wed, Jun 14, 2017 at 02:11:18AM +1000, Nicholas Piggin wrote: Yeah, if you wouldn't mind. Sorry for dragging this out, but I feel like we are getting close to have this defined properly which would allow us to split the code up correctly in

Re: [PATCH 3/4] watchdog: Split up config options

2017-06-15 Thread Babu Moger
Nick, On 6/14/2017 10:04 PM, Nicholas Piggin wrote: On Wed, 14 Jun 2017 21:16:04 -0500 Babu Moger wrote: Hi Don, On 6/14/2017 9:09 AM, Don Zickus wrote: On Wed, Jun 14, 2017 at 02:11:18AM +1000, Nicholas Piggin wrote: Yeah, if you wouldn't mind. Sorry for dragging this out, but I feel

Re: [PATCH v4 0/5] Improve watchdog config for arch watchdogs

2017-06-16 Thread Babu Moger
Tested on sparc: Tested-by: Babu Moger Reviewed patch #1, #2, #3 Reviewed-by: Babu Moger On 6/16/2017 9:50 AM, Don Zickus wrote: (adding Andrew) On Fri, Jun 16, 2017 at 04:57:10PM +1000, Nicholas Piggin wrote: This is the latest series to make the hardlockup watchdog more easily

Re: [PATCH 0/4][V3] Improve watchdog config for arch watchdogs

2017-06-06 Thread Babu Moger
Hi Don, Nicholas, On 6/6/2017 11:08 AM, Don Zickus wrote: (adding Babu) On Tue, May 30, 2017 at 11:26:55AM +1000, Nicholas Piggin wrote: Since last time: - Have the perf based hardlockup detector use arch_touch_nmi_watchdog() rather than hld_touch_nmi_watchdog(). This changes direction

Re: CPU_BIG_ENDIAN in generic code (was: Re: [PATCH v3 3/7] arch/sparc: Define config parameter CPU_BIG_ENDIAN)

2017-06-07 Thread Babu Moger
On 5/29/2017 9:56 PM, Michael Ellerman wrote: Geert Uytterhoeven writes: Hi Michael, On Mon, May 29, 2017 at 2:07 PM, Michael Ellerman wrote: Geert Uytterhoeven writes: On Tue, May 23, 2017 at 11:45 PM, Babu Moger wrote: Found this problem while enabling queued rwlock on SPARC

[PATCH 2/2] include: warn for inconsistent endian config definition

2017-06-08 Thread Babu Moger
discussion http://www.spinics.net/lists/devicetree/msg178101.html Signed-off-by: Babu Moger Suggested-by: Arnd Bergmann --- include/linux/byteorder/big_endian.h|4 include/linux/byteorder/little_endian.h |4 2 files changed, 8 insertions(+), 0 deletions(-) diff --git a/include

[PATCH 0/2] Define CPU_BIG_ENDIAN or warn for inconsistencies

2017-06-08 Thread Babu Moger
and sparc). And warn if there are inconsistencies in this definition. Babu Moger (2): arch: Define CPU_BIG_ENDIAN for all fixed big endian archs include: warn for inconsistent endian config definition arch/frv/Kconfig|3 +++ arch/h8300/Kconfig |3

[PATCH 1/2] arch: Define CPU_BIG_ENDIAN for all fixed big endian archs

2017-06-08 Thread Babu Moger
); } Problem is many of the fixed big endian architectures dont define CPU_BIG_ENDIAN and clears the wrong byte. Define CPU_BIG_ENDIAN for all the fixed big endian architecture. Here is the orinal discussion http://www.spinics.net/lists/devicetree/msg178101.html Signed-off-by: Babu Moger Suggested

Re: [PATCH 2/2] include: warn for inconsistent endian config definition

2017-06-09 Thread Babu Moger
Geert, On 6/9/2017 2:16 AM, Geert Uytterhoeven wrote: Hi Babu, On Fri, Jun 9, 2017 at 9:05 AM, Geert Uytterhoeven wrote: Here is the original discussion http://www.spinics.net/lists/devicetree/msg178101.html Signed-off-by: Babu Moger Suggested-by: Arnd Bergmann Hmm, the link above refers

Re: [PATCH 2/2] include: warn for inconsistent endian config definition

2017-06-09 Thread Babu Moger
On 6/9/2017 9:11 AM, Geert Uytterhoeven wrote: Hi Babu, On Fri, Jun 9, 2017 at 3:55 PM, Babu Moger wrote: On 6/9/2017 2:16 AM, Geert Uytterhoeven wrote: On Fri, Jun 9, 2017 at 9:05 AM, Geert Uytterhoeven wrote: Here is the original discussion http://www.spinics.net/lists/devicetree

Re: [PATCH 1/2] arch: Define CPU_BIG_ENDIAN for all fixed big endian archs

2017-06-09 Thread Babu Moger
On 6/9/2017 2:03 AM, Geert Uytterhoeven wrote: On Fri, Jun 9, 2017 at 12:17 AM, Babu Moger wrote: While working on enabling queued rwlock on SPARC, found this following code in include/asm-generic/qrwlock.h which uses CONFIG_CPU_BIG_ENDIAN to clear a byte. static inline u8

[PATCH v2 2/2] include: warn for inconsistent endian config definition

2017-06-09 Thread Babu Moger
is not defined on big endian architecture and also warn if it defined on little endian architectures. Here is our original discussion https://lkml.org/lkml/2017/5/24/620 Signed-off-by: Babu Moger Suggested-by: Arnd Bergmann Acked-by: Geert Uytterhoeven --- include/linux/byteorder/big_endian.h

[PATCH v2 1/2] arch: Define CPU_BIG_ENDIAN for all fixed big endian archs

2017-06-09 Thread Babu Moger
/earlycon.c drivers/tty/serial/serial_core.c Be aware that this may cause regressions if someone has worked-around problems in the above code already. Remove the work-around. Here is our original discussion https://lkml.org/lkml/2017/5/24/620 Signed-off-by: Babu Moger Suggested-by: Arnd Bergmann

[PATCH v2 0/2] Define CPU_BIG_ENDIAN or warn for inconsistencies

2017-06-09 Thread Babu Moger
/2017/5/24/620 Based on the discussion, it was decided to add CONFIG_CPU_BIG_ENDIAN for all the fixed big endian architecture(frv, h8300, m68k, openrisc, parisc and sparc). And warn if there are inconsistencies in this definition. v1 -> v2: Updated the commit messages and acks. Babu Moger

[PATCH v2 2/2] lockdep: Keep the static allocations small for PROVE_LOCKING_SMALL

2016-09-26 Thread Babu Moger
Reduce the size of data structure for lockdep entries half if PROVE_LOCKING_SMALL if defined. This is used for sparc. This config variable is disabled by default. Signed-off-by: Babu Moger --- kernel/locking/lockdep_internals.h | 13 ++--- 1 files changed, 10 insertions(+), 3

[PATCH v2 0/2] Ajust lockdep static allocations for sparc

2016-09-26 Thread Babu Moger
v2: As suggested by Peter Zijlstra, keeping the default as is. Introduced new config variable CONFIG_PROVE_LOCKING_SMALL to handle sparc specific case. v0: Initial revision. Babu Moger (2): config: Add new CONFIG_PROVE_LOCKING_SMALL lockdep: Keep the static allocations sm

[PATCH v2 1/2] config: Add new CONFIG_PROVE_LOCKING_SMALL

2016-09-26 Thread Babu Moger
s sections. With PROVE_LOCKING feature, the kernel size could grow beyond this limit and causing system bootup issues. With this option, kernel limits the size of the entries of lock_chains, stack_trace etc. so that kernel fits in required size limit. This is only visible for sparc. Signed-off-by: Babu Moger

Re: [PATCH v2 1/2] config: Add new CONFIG_PROVE_LOCKING_SMALL

2016-09-27 Thread Babu Moger
On 9/27/2016 6:40 AM, Peter Zijlstra wrote: On Tue, Sep 27, 2016 at 06:46:25AM +0200, Sam Ravnborg wrote: Since this is only relevant for sparc, and for sparc this is "select"ed, then there is limited/no gain having this as a visible menu config option. How about adding just a simple

Re: [PATCH v2 1/2] config: Add new CONFIG_PROVE_LOCKING_SMALL

2016-09-27 Thread Babu Moger
On 9/27/2016 10:43 AM, Sam Ravnborg wrote: On Tue, Sep 27, 2016 at 09:51:40AM -0500, Babu Moger wrote: On 9/27/2016 6:40 AM, Peter Zijlstra wrote: On Tue, Sep 27, 2016 at 06:46:25AM +0200, Sam Ravnborg wrote: Since this is only relevant for sparc, and for sparc this is "sele

[PATCH v3 0/2] Ajust lockdep static allocations for sparc

2016-09-27 Thread Babu Moger
Peter Zijlstra, keeping the default as is. Introduced new config variable CONFIG_PROVE_LOCKING_SMALL to handle sparc specific case. v0: Initial revision. Babu Moger (2): config: Adding the new config parameter CONFIG_PROVE_LOCKING_SMALL for sparc lockdep: Limit static alloc

[PATCH v3 1/2] config: Adding the new config parameter CONFIG_PROVE_LOCKING_SMALL for sparc

2016-09-27 Thread Babu Moger
row beyond this limit and causing system boot-up issues. With this option, kernel limits the size of the entries of lock_chains, stack_trace etc., so that kernel fits in required size limit. This is not visible to user and only used for sparc. Signed-off-by: Babu Moger --- arch/sparc/Kconfig |

[PATCH v3 2/2] lockdep: Limit static allocations if PROVE_LOCKING_SMALL is defined

2016-09-27 Thread Babu Moger
Reduce the size of data structure for lockdep entries by half if PROVE_LOCKING_SMALL if defined. This is used only for sparc. Signed-off-by: Babu Moger --- kernel/locking/lockdep_internals.h | 20 +--- 1 files changed, 17 insertions(+), 3 deletions(-) diff --git a/kernel

Re: [PATCH v2 1/2] watchdog: Introduce arch_watchdog_nmi_enable and arch_watchdog_nmi_disable

2016-10-21 Thread Babu Moger
Don, On 10/21/2016 2:19 PM, Andrew Morton wrote: On Fri, 21 Oct 2016 11:11:14 -0400 Don Zickus wrote: On Thu, Oct 20, 2016 at 08:25:27PM -0700, Andrew Morton wrote: On Thu, 20 Oct 2016 12:14:14 -0400 Don Zickus wrote: -static int watchdog_nmi_enable(unsigned int cpu) { return 0; }

[PATCH v2 RESEND] drivers/usb: Skip auto handoff for TI and RENESAS usb controllers

2016-10-21 Thread Babu Moger
Never seen XHCI auto handoff working on TI and RENESAS cards. Eventually, we force handoff. This code forces the handoff unconditionally. It saves 5 seconds boot time for each card. Signed-off-by: Babu Moger --- v2: Made changes per comments from Greg KH. Extra space removal in assignment

Re: [PATCH v2 1/2] watchdog: Introduce arch_watchdog_nmi_enable and arch_watchdog_nmi_disable

2016-10-17 Thread Babu Moger
Don, On 10/17/2016 12:31 PM, Don Zickus wrote: On Thu, Oct 13, 2016 at 01:38:01PM -0700, Babu Moger wrote: Currently we do not have a way to enable/disable arch specific watchdog handlers if it was implemented by any of the architectures. This patch introduces new functions

[PATCH v3 0/2] Introduce arch specific nmi enable, disable handlers

2016-10-18 Thread Babu Moger
: Initial version. Discussion thread here http://www.mail-archive.com/linux-kernel@vger.kernel.org/msg1245427.html Babu Moger (2): watchdog: Introduce arch_watchdog_nmi_enable and arch_watchdog_nmi_disable sparc: Implement arch_watchdog_nmi_enable and arch_watchdog_nmi_disable arch/sparc

[PATCH v3 1/2] watchdog: Introduce arch_watchdog_nmi_enable and arch_watchdog_nmi_disable

2016-10-18 Thread Babu Moger
handlers. These functions are defined as weak as architectures can override their definitions to enable/disable nmi watchdog behaviour. Signed-off-by: Babu Moger --- kernel/watchdog.c | 69 +++- 1 files changed, 46 insertions(+), 23 deletions

[PATCH v3 2/2] sparc: Implement arch_watchdog_nmi_enable and arch_watchdog_nmi_disable

2016-10-18 Thread Babu Moger
watchdogs using proc or sysctl interface. Example commands. To enable: echo 1 > /proc/sys/kernel/nmi_watchdog To disable: echo 0 > /proc/sys/kernel/nmi_watchdog It can also achieved using the sysctl parameter kernel.nmi_watchdog Signed-off-by: Babu Moger --- arch/sparc/kernel/nmi.c

<    1   2   3   4   5   6   >