Skip to content

Commit dd8437c

Browse files
guoren83palmer-dabbelt
authored andcommitted
riscv: atomic: Cleanup unnecessary definition
The cmpxchg32 & cmpxchg32_local are not used in Linux anymore. So clean up asm/cmpxchg.h. Signed-off-by: Guo Ren <[email protected]> Signed-off-by: Guo Ren <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Palmer Dabbelt <[email protected]>
1 parent 19bc59b commit dd8437c

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

arch/riscv/include/asm/cmpxchg.h

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -348,18 +348,6 @@
348348
#define arch_cmpxchg_local(ptr, o, n) \
349349
(__cmpxchg_relaxed((ptr), (o), (n), sizeof(*(ptr))))
350350

351-
#define cmpxchg32(ptr, o, n) \
352-
({ \
353-
BUILD_BUG_ON(sizeof(*(ptr)) != 4); \
354-
arch_cmpxchg((ptr), (o), (n)); \
355-
})
356-
357-
#define cmpxchg32_local(ptr, o, n) \
358-
({ \
359-
BUILD_BUG_ON(sizeof(*(ptr)) != 4); \
360-
arch_cmpxchg_relaxed((ptr), (o), (n)) \
361-
})
362-
363351
#define arch_cmpxchg64(ptr, o, n) \
364352
({ \
365353
BUILD_BUG_ON(sizeof(*(ptr)) != 8); \

0 commit comments

Comments
 (0)