Re: [PATCH 06/67] hexagon: remove unused flush_write_buffers definition

2018-01-08 Thread Richard Kuo
On Fri, Dec 29, 2017 at 09:18:10AM +0100, Christoph Hellwig wrote:
> Signed-off-by: Christoph Hellwig <h...@lst.de>
> ---
>  arch/hexagon/include/asm/io.h | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/arch/hexagon/include/asm/io.h b/arch/hexagon/include/asm/io.h
> index 66f5e9a61efc..9e8621d94ee9 100644
> --- a/arch/hexagon/include/asm/io.h
> +++ b/arch/hexagon/include/asm/io.h
> @@ -330,8 +330,6 @@ static inline void outsl(unsigned long port, const void 
> *buffer, int count)
>   }
>  }
>  
> -#define flush_write_buffers() do { } while (0)
> -
>  #endif /* __KERNEL__ */
>  
>  #endif
> -- 
> 2.14.2
> 

For Hexagon:

Acked-by: Richard Kuo <r...@codeaurora.org>


-- 
Employee of Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, 
a Linux Foundation Collaborative Project


Re: [PATCH 31/44] hexagon: remove arch-specific dma_supported implementation

2017-06-15 Thread Richard Kuo
On Thu, Jun 08, 2017 at 03:25:56PM +0200, Christoph Hellwig wrote:
> This implementation is simply bogus - hexagon only has a simple
> direct mapped DMA implementation and thus doesn't care about the
> address.
> 
> Signed-off-by: Christoph Hellwig <h...@lst.de>
> ---
>  arch/hexagon/include/asm/dma-mapping.h | 2 --
>  arch/hexagon/kernel/dma.c  | 9 -
>  2 files changed, 11 deletions(-)
> 

Acked-by: Richard Kuo <r...@codeaurora.org>

-- 
Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, 
a Linux Foundation Collaborative Project


Re: [PATCH 17/44] hexagon: switch to use ->mapping_error for error reporting

2017-06-15 Thread Richard Kuo
On Thu, Jun 08, 2017 at 03:25:42PM +0200, Christoph Hellwig wrote:
> Signed-off-by: Christoph Hellwig <h...@lst.de>
> ---
>  arch/hexagon/include/asm/dma-mapping.h |  2 --
>  arch/hexagon/kernel/dma.c  | 12 +---
>  arch/hexagon/kernel/hexagon_ksyms.c|  1 -
>  3 files changed, 9 insertions(+), 6 deletions(-)
> 

Acked-by: Richard Kuo <r...@codeaurora.org>

-- 
Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, 
a Linux Foundation Collaborative Project


Re: [PATCH 1/1] arch Kconfig: remove references to IRQ_PER_CPU

2012-11-13 Thread Richard Kuo
On Tue, Nov 13, 2012 at 11:59:08AM +, James Hogan wrote:
 The IRQ_PER_CPU Kconfig symbol was removed in the following commit:
 
 Commit 6a58fb3bad099076f36f0f30f44507bc3275cdb6 (genirq: Remove
 CONFIG_IRQ_PER_CPU) merged in v2.6.39-rc1.
 
 But IRQ_PER_CPU wasn't removed from any of the architecture Kconfig
 files where it was defined or selected. It's completely unused so remove
 the remaining references.
 
 Signed-off-by: James Hogan james.ho...@imgtec.com
 Cc: Thomas Gleixner t...@linutronix.de
 Cc: Mike Frysinger vap...@gentoo.org
 Cc: Richard Kuo r...@codeaurora.org
 Cc: Tony Luck tony.l...@intel.com
 Cc: Fenghua Yu fenghua...@intel.com
 Cc: Ralf Baechle r...@linux-mips.org
 Cc: James E.J. Bottomley j...@parisc-linux.org
 Cc: Helge Deller del...@gmx.de
 Cc: Benjamin Herrenschmidt b...@kernel.crashing.org
 Cc: Paul Mackerras pau...@samba.org
 Cc: Paul Mundt let...@linux-sh.org
 ---
 Based on v3.7-rc5.
 
 Compile tested defconfigs for bfin, ia64, mips, parisc, powerpc, sh, but
 not hexagon.
 
 Grepped entire tree to check no references to CONFIG_IRQ_PER_CPU, and
 grepped arch/ for Kconfig files referencing IRQ_PER_CPU.
 
  arch/blackfin/Kconfig |1 -
  arch/hexagon/Kconfig  |1 -
  arch/ia64/Kconfig |1 -
  arch/mips/Kconfig |1 -
  arch/parisc/Kconfig   |1 -
  arch/powerpc/Kconfig  |1 -
  arch/sh/Kconfig   |3 ---
  7 files changed, 0 insertions(+), 9 deletions(-)
 

Hexagon's was commented out anyways, but thanks for pointing it out.

Acked-by: Richard Kuo r...@codeaurora.org

-- 

Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
hosted by The Linux Foundation
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH 1/2] atomic: Allow atomic_inc_not_zero to be overridden

2012-03-01 Thread Richard Kuo
On Thu, Mar 01, 2012 at 03:02:56PM -0800, Andrew Morton wrote:
 Please merge this via the ppc tree?
 
 
 And let's ask the hexagon maintainers to take a look at the definition
 in arch/hexagon/include/asm/atomic.h.  I assume that it can be removed,
 but that might cause problems with files which include asm/atomic.h
 directly.  I have found two such files in non-arch code and have queued
 fixes.  There are no such files in arch/hexagon code, so I think it's
 safe to zap the hexagon definition of atomic_inc_not_zero().

Just tested it; it's safe to zap the Hexagon definition of
atomic_inc_not_zero()...  I'm fine with this going in through some
other tree (still getting mine set up).


Thanks,
Richard Kuo




-- 

Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


[PATCH] powerpc: use rwsem.h from generic location

2011-11-30 Thread Richard Kuo
As of commit dd472da38, rwsem.h was moved into asm-generic.
This patch removes the arch file and points the build at
its new location.

Signed-off-by: Richard Kuo r...@codeaurora.org
---
 arch/powerpc/include/asm/Kbuild  |2 +
 arch/powerpc/include/asm/rwsem.h |  132 --
 2 files changed, 2 insertions(+), 132 deletions(-)
 delete mode 100644 arch/powerpc/include/asm/rwsem.h

diff --git a/arch/powerpc/include/asm/Kbuild b/arch/powerpc/include/asm/Kbuild
index d51df17..7e313f1 100644
--- a/arch/powerpc/include/asm/Kbuild
+++ b/arch/powerpc/include/asm/Kbuild
@@ -34,3 +34,5 @@ header-y += termios.h
 header-y += types.h
 header-y += ucontext.h
 header-y += unistd.h
+
+generic-y += rwsem.h
diff --git a/arch/powerpc/include/asm/rwsem.h b/arch/powerpc/include/asm/rwsem.h
deleted file mode 100644
index bb1e2cd..000
--- a/arch/powerpc/include/asm/rwsem.h
+++ /dev/null
@@ -1,132 +0,0 @@
-#ifndef _ASM_POWERPC_RWSEM_H
-#define _ASM_POWERPC_RWSEM_H
-
-#ifndef _LINUX_RWSEM_H
-#error Please don't include asm/rwsem.h directly, use linux/rwsem.h 
instead.
-#endif
-
-#ifdef __KERNEL__
-
-/*
- * R/W semaphores for PPC using the stuff in lib/rwsem.c.
- * Adapted largely from include/asm-i386/rwsem.h
- * by Paul Mackerras pau...@samba.org.
- */
-
-/*
- * the semaphore definition
- */
-#ifdef CONFIG_PPC64
-# define RWSEM_ACTIVE_MASK 0xL
-#else
-# define RWSEM_ACTIVE_MASK 0xL
-#endif
-
-#define RWSEM_UNLOCKED_VALUE   0xL
-#define RWSEM_ACTIVE_BIAS  0x0001L
-#define RWSEM_WAITING_BIAS (-RWSEM_ACTIVE_MASK-1)
-#define RWSEM_ACTIVE_READ_BIAS RWSEM_ACTIVE_BIAS
-#define RWSEM_ACTIVE_WRITE_BIAS(RWSEM_WAITING_BIAS + 
RWSEM_ACTIVE_BIAS)
-
-/*
- * lock for reading
- */
-static inline void __down_read(struct rw_semaphore *sem)
-{
-   if (unlikely(atomic_long_inc_return((atomic_long_t *)sem-count) = 0))
-   rwsem_down_read_failed(sem);
-}
-
-static inline int __down_read_trylock(struct rw_semaphore *sem)
-{
-   long tmp;
-
-   while ((tmp = sem-count) = 0) {
-   if (tmp == cmpxchg(sem-count, tmp,
-  tmp + RWSEM_ACTIVE_READ_BIAS)) {
-   return 1;
-   }
-   }
-   return 0;
-}
-
-/*
- * lock for writing
- */
-static inline void __down_write_nested(struct rw_semaphore *sem, int subclass)
-{
-   long tmp;
-
-   tmp = atomic_long_add_return(RWSEM_ACTIVE_WRITE_BIAS,
-(atomic_long_t *)sem-count);
-   if (unlikely(tmp != RWSEM_ACTIVE_WRITE_BIAS))
-   rwsem_down_write_failed(sem);
-}
-
-static inline void __down_write(struct rw_semaphore *sem)
-{
-   __down_write_nested(sem, 0);
-}
-
-static inline int __down_write_trylock(struct rw_semaphore *sem)
-{
-   long tmp;
-
-   tmp = cmpxchg(sem-count, RWSEM_UNLOCKED_VALUE,
- RWSEM_ACTIVE_WRITE_BIAS);
-   return tmp == RWSEM_UNLOCKED_VALUE;
-}
-
-/*
- * unlock after reading
- */
-static inline void __up_read(struct rw_semaphore *sem)
-{
-   long tmp;
-
-   tmp = atomic_long_dec_return((atomic_long_t *)sem-count);
-   if (unlikely(tmp  -1  (tmp  RWSEM_ACTIVE_MASK) == 0))
-   rwsem_wake(sem);
-}
-
-/*
- * unlock after writing
- */
-static inline void __up_write(struct rw_semaphore *sem)
-{
-   if (unlikely(atomic_long_sub_return(RWSEM_ACTIVE_WRITE_BIAS,
-(atomic_long_t *)sem-count)  0))
-   rwsem_wake(sem);
-}
-
-/*
- * implement atomic add functionality
- */
-static inline void rwsem_atomic_add(long delta, struct rw_semaphore *sem)
-{
-   atomic_long_add(delta, (atomic_long_t *)sem-count);
-}
-
-/*
- * downgrade write lock to read lock
- */
-static inline void __downgrade_write(struct rw_semaphore *sem)
-{
-   long tmp;
-
-   tmp = atomic_long_add_return(-RWSEM_WAITING_BIAS,
-(atomic_long_t *)sem-count);
-   if (tmp  0)
-   rwsem_downgrade_wake(sem);
-}
-
-/*
- * implement exchange and add functionality
- */
-static inline long rwsem_atomic_update(long delta, struct rw_semaphore *sem)
-{
-   return atomic_long_add_return(delta, (atomic_long_t *)sem-count);
-}
-
-#endif /* __KERNEL__ */
-#endif /* _ASM_POWERPC_RWSEM_H */
-- 
1.7.3
-- 

Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH-RFC 01/10] lib: move GENERIC_IOMAP to lib/Kconfig

2011-11-28 Thread Richard Kuo
On Thu, Nov 24, 2011 at 10:15:42PM +0200, Michael S. Tsirkin wrote:
 define GENERIC_IOMAP in a central location
 instead of all architectures. This will be helpful
 for the follow-up patch which makes it select
 other configs. Code is also a bit shorter this way.

For the Hexagon config,

Acked-by: Richard Kuo r...@codeaurora.org


-- 

Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev