From: Simon Glass <simon.glass@canonical.com> The atomic_add() and atomic64_add() functions are now provided by asm-generic/atomic.h so remove the duplicate declarations from ext4_uboot.h and the implementation from stub.c Co-developed-by: Claude <noreply@anthropic.com> Signed-off-by: Simon Glass <simon.glass@canonical.com> --- (no changes since v1) fs/ext4l/ext4_uboot.h | 4 ---- fs/ext4l/stub.c | 8 +------- 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/fs/ext4l/ext4_uboot.h b/fs/ext4l/ext4_uboot.h index 70ac403d9fd..4cfe9e6de89 100644 --- a/fs/ext4l/ext4_uboot.h +++ b/fs/ext4l/ext4_uboot.h @@ -2320,10 +2320,6 @@ void *kvzalloc(size_t size, gfp_t flags); #define kvmalloc(size, flags) kvzalloc(size, flags) unsigned long roundup_pow_of_two(unsigned long n); -/* Atomic operations - declarations for stub.c */ -void atomic_add(int val, atomic_t *v); -void atomic64_add(s64 val, atomic64_t *v); - /* Power of 2 check - declaration for stub.c */ int is_power_of_2(unsigned long n); diff --git a/fs/ext4l/stub.c b/fs/ext4l/stub.c index f072cb5713f..d328c6821a9 100644 --- a/fs/ext4l/stub.c +++ b/fs/ext4l/stub.c @@ -617,13 +617,7 @@ int percpu_init_rwsem(struct percpu_rw_semaphore *sem) return 0; } -/* Atomic operations */ -void atomic_add(int val, atomic_t *v) -{ - v->counter += val; -} - -/* atomic64_add is now a macro in ext4_uboot.h */ +/* atomic_add and atomic64_add are now in asm-generic/atomic.h */ /* Discard */ unsigned int bdev_max_discard_sectors(struct block_device *bdev) -- 2.43.0