include/asm-generic/qrwlock.h was trying to get arch_spin_is_locked via asm-generic/qspinlock.h. However, this does not work because architectures might be using queued rwlocks but not queued spinlocks (csky), or because they might be defining their own queued_* macros before including asm/qspinlock.h. To fix this, ensure that asm/spinlock.h always includes qrwlock.h after defining arch_spin_is_locked (either directly for csky, or via asm/qspinlock.h for other architectures). The only inclusion elsewhere is in kernel/locking/qrwlock.c. That one is really unnecessary because the file is only compiled in SMP configurations (config QUEUED_RWLOCKS depends on SMP) and in that case linux/spinlock.h already includes asm/qrwlock.h if needed, via asm/spinlock.h.
Showing the changes to kernel (1 of 6 files). Show all
Unified · Split
| @@ -12,7 +12,6 @@ · 11 unmodified lines | ||
| 12 | 12 | #include <linux/percpu.h> |
| 13 | 13 | #include <linux/hardirq.h> |
| 14 | 14 | #include <linux/spinlock.h> |
| 15 | −#include <asm/qrwlock.h> | |
| 16 | 15 | |
| 17 | 16 | /** |
| 18 | 17 | * queued_read_lock_slowpath - acquire read lock of a queue rwlock |