mirror of https://gitee.com/openkylin/linux.git
arch,mn10300: Convert smp_mb__*()
mn10300 fully relies on asm-generic/barrier.h and therefore its smp_mb() is barrier(). We can use the default implementation. Signed-off-by: Peter Zijlstra <peterz@infradead.org> Acked-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Link: http://lkml.kernel.org/n/tip-wotyeoj99h1dpojjeest2jbk@git.kernel.org Cc: David Howells <dhowells@redhat.com> Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: linux-am33-list@redhat.com Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org>
This commit is contained in:
parent
91bbefe6b0
commit
9424cdf0fc
|
@ -13,6 +13,7 @@
|
||||||
|
|
||||||
#include <asm/irqflags.h>
|
#include <asm/irqflags.h>
|
||||||
#include <asm/cmpxchg.h>
|
#include <asm/cmpxchg.h>
|
||||||
|
#include <asm/barrier.h>
|
||||||
|
|
||||||
#ifndef CONFIG_SMP
|
#ifndef CONFIG_SMP
|
||||||
#include <asm-generic/atomic.h>
|
#include <asm-generic/atomic.h>
|
||||||
|
@ -234,12 +235,6 @@ static inline void atomic_set_mask(unsigned long mask, unsigned long *addr)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Atomic operations are already serializing on MN10300??? */
|
|
||||||
#define smp_mb__before_atomic_dec() barrier()
|
|
||||||
#define smp_mb__after_atomic_dec() barrier()
|
|
||||||
#define smp_mb__before_atomic_inc() barrier()
|
|
||||||
#define smp_mb__after_atomic_inc() barrier()
|
|
||||||
|
|
||||||
#endif /* __KERNEL__ */
|
#endif /* __KERNEL__ */
|
||||||
#endif /* CONFIG_SMP */
|
#endif /* CONFIG_SMP */
|
||||||
#endif /* _ASM_ATOMIC_H */
|
#endif /* _ASM_ATOMIC_H */
|
||||||
|
|
|
@ -18,9 +18,7 @@
|
||||||
#define __ASM_BITOPS_H
|
#define __ASM_BITOPS_H
|
||||||
|
|
||||||
#include <asm/cpu-regs.h>
|
#include <asm/cpu-regs.h>
|
||||||
|
#include <asm/barrier.h>
|
||||||
#define smp_mb__before_clear_bit() barrier()
|
|
||||||
#define smp_mb__after_clear_bit() barrier()
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* set bit
|
* set bit
|
||||||
|
|
|
@ -78,9 +78,9 @@ void smp_flush_tlb(void *unused)
|
||||||
else
|
else
|
||||||
local_flush_tlb_page(flush_mm, flush_va);
|
local_flush_tlb_page(flush_mm, flush_va);
|
||||||
|
|
||||||
smp_mb__before_clear_bit();
|
smp_mb__before_atomic();
|
||||||
cpumask_clear_cpu(cpu_id, &flush_cpumask);
|
cpumask_clear_cpu(cpu_id, &flush_cpumask);
|
||||||
smp_mb__after_clear_bit();
|
smp_mb__after_atomic();
|
||||||
out:
|
out:
|
||||||
put_cpu();
|
put_cpu();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue