Skip to content

Commit 40e6073

Browse files
guoren83palmer-dabbelt
authored andcommitted
riscv: qspinlock: Fixup _Q_PENDING_LOOPS definition
When CONFIG_RISCV_QUEUED_SPINLOCKS=y, the _Q_PENDING_LOOPS definition is missing. Add the _Q_PENDING_LOOPS definition for pure qspinlock usage. Fixes: ab83647 ("riscv: Add qspinlock support") Signed-off-by: Guo Ren <[email protected]> Signed-off-by: Guo Ren <[email protected]> Reviewed-by: Alexandre Ghiti <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Palmer Dabbelt <[email protected]>
1 parent 51356ce commit 40e6073

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

arch/riscv/include/asm/spinlock.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,11 @@
33
#ifndef __ASM_RISCV_SPINLOCK_H
44
#define __ASM_RISCV_SPINLOCK_H
55

6-
#ifdef CONFIG_RISCV_COMBO_SPINLOCKS
6+
#ifdef CONFIG_QUEUED_SPINLOCKS
77
#define _Q_PENDING_LOOPS (1 << 9)
8+
#endif
9+
10+
#ifdef CONFIG_RISCV_COMBO_SPINLOCKS
811

912
#define __no_arch_spinlock_redefine
1013
#include <asm/ticket_spinlock.h>

0 commit comments

Comments
 (0)