Commit 5c12a6ef authored by Paul Burton's avatar Paul Burton

MIPS: barrier: Remove fast_mb() Octeon #ifdef'ery

The definition of fast_mb() is the same in both the Octeon & non-Octeon
cases, so remove the duplication & define it only once.
Signed-off-by: default avatarPaul Burton <paul.burton@mips.com>
Cc: linux-mips@vger.kernel.org
Cc: Huacai Chen <chenhc@lemote.com>
Cc: Jiaxun Yang <jiaxun.yang@flygoat.com>
Cc: linux-kernel@vger.kernel.org
parent 05e6da74
...@@ -38,6 +38,8 @@ static inline void wmb(void) ...@@ -38,6 +38,8 @@ static inline void wmb(void)
} }
#define wmb wmb #define wmb wmb
#define fast_mb() __sync()
#define __fast_iob() \ #define __fast_iob() \
__asm__ __volatile__( \ __asm__ __volatile__( \
".set push\n\t" \ ".set push\n\t" \
...@@ -49,10 +51,8 @@ static inline void wmb(void) ...@@ -49,10 +51,8 @@ static inline void wmb(void)
: "m" (*(int *)CKSEG1) \ : "m" (*(int *)CKSEG1) \
: "memory") : "memory")
#ifdef CONFIG_CPU_CAVIUM_OCTEON #ifdef CONFIG_CPU_CAVIUM_OCTEON
# define fast_mb() __sync()
# define fast_iob() do { } while (0) # define fast_iob() do { } while (0)
#else /* ! CONFIG_CPU_CAVIUM_OCTEON */ #else /* ! CONFIG_CPU_CAVIUM_OCTEON */
# define fast_mb() __sync()
# ifdef CONFIG_SGI_IP28 # ifdef CONFIG_SGI_IP28
# define fast_iob() \ # define fast_iob() \
__asm__ __volatile__( \ __asm__ __volatile__( \
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment