spinlock.h 472 B

123456789101112131415161718192021
  1. /* SPDX-License-Identifier: GPL-2.0-or-later */
  2. #ifndef __ASM_SPINLOCK_H
  3. #define __ASM_SPINLOCK_H
  4. #ifdef __KERNEL__
  5. #ifdef CONFIG_PPC_QUEUED_SPINLOCKS
  6. #include <asm/qspinlock.h>
  7. #include <asm/qrwlock.h>
  8. #else
  9. #include <asm/simple_spinlock.h>
  10. #endif
  11. /* See include/linux/spinlock.h */
  12. #define smp_mb__after_spinlock() smp_mb()
  13. #ifndef CONFIG_PARAVIRT_SPINLOCKS
  14. static inline void pv_spinlocks_init(void) { }
  15. #endif
  16. #endif /* __KERNEL__ */
  17. #endif /* __ASM_SPINLOCK_H */