Skip to contentSkip to conversation

futex: Fix additional regressions

PATCH Applied Arnd Bergmann 2 participants 2 messages Dec 3, 2021 – Dec 11, 2021

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 futex: Fix additional regressions

From: Arnd Bergmann <[email protected]>

Naresh reported another architecture that was broken by the same typo that I already fixed for three architectures: mips also refers to the futex_atomic_op_inuser_local() function by the wrong name and runs into a missing closing '}' as well.

Going through the source tree I found that I also had the same typo in the documentation as well as the xtensa code, both of which ended up escaping the regression testing so far. In the case of xtensa, it appears that the broken code path is only used when building for platforms that are not supported by the default gcc configuration, so they are impossible to test for with my setup.

After going through these more carefully and fixing up the typos, I build-tested all architectures again to ensure I'm not introducing a new regression or missing one more obvious issue with my series.

Fixes 4e0d84634445 ("futex: Fix sparc32/m68k/nds32 build regression")
Fixes 3f2bedabb62c ("futex: Ensure futex_atomic_cmpxchg_inatomic() is present")
Cc Thomas Bogendoerfer <[email protected]>
Cc Chris Zankel <[email protected]>
Cc Max Filippov <[email protected]>
---
 arch/mips/include/asm/futex.h   | 6 +++---
 arch/xtensa/include/asm/futex.h | 2 +-
 include/asm-generic/futex.h     | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)
arch/mips/include/asm/futex.h +3 -3
index 9287110cb06d..8612a7e42d78 100644
@@ -86,9 +86,9 @@
 		: "memory");						\
 	} else {							\
 		/* fallback for non-SMP */				\
-		ret = arch_futex_atomic_op_inuser_local(op, oparg, oval,\
-							uaddr);	\
-	}
+		ret = futex_atomic_op_inuser_local(op, oparg, oval, uaddr);	\
+	}								\
+}
 
 static inline int
 arch_futex_atomic_op_inuser(int op, int oparg, int *oval, u32 __user *uaddr)
arch/xtensa/include/asm/futex.h +1 -1
index fe8f31575ab1..a6f7d7ab5950 100644
@@ -109,7 +109,7 @@ static inline int arch_futex_atomic_op_inuser(int op, int oparg, int *oval,
 
 	return ret;
 #else
-	return arch_futex_atomic_op_inuser_local(op, oparg, oval, uaddr);
+	return futex_atomic_op_inuser_local(op, oparg, oval, uaddr);
 #endif
 }
 
include/asm-generic/futex.h +1 -1
index 66d6843bfd02..2a19215baae5 100644
@@ -21,7 +21,7 @@
 #endif
 
 /**
- * arch_futex_atomic_op_inuser_local() - Atomic arithmetic operation with constant
+ * futex_atomic_op_inuser_local() - Atomic arithmetic operation with constant
  *			  argument and comparison of the previous
  *			  futex value with another constant.
  *
Signature · 1 line
2.29.2
merge bot Applied
#1 lore raw
The following commit has been merged into the locking/core branch of tip:

The following commit has been merged into the locking/core branch of tip:

Commit-ID:     0f09c274698590d508c43f924d9dffc7130b782d
Gitweb:        https://git.kernel.org/tip/0f09c274698590d508c43f924d9dffc7130b782d
Author:        Arnd Bergmann <[email protected]>
AuthorDate:    Fri, 03 Dec 2021 09:07:56 +01:00
Committer:     Thomas Gleixner <[email protected]>
CommitterDate: Sat, 11 Dec 2021 23:31:51 +01:00

futex: Fix additional regressions

Naresh reported another architecture that was broken by the same typo that was already fixed for three architectures: mips also refers to the futex_atomic_op_inuser_local() function by the wrong name and runs into a missing closing '}' as well.

Going through the source tree the same typo was found in the documentation as well as in the xtensa code, both of which ended up escaping the regression testing so far. In the case of xtensa, it appears that the broken code path is only used when building for platforms that are not supported by the default gcc configuration, so they are impossible to test for with default setups.

After going through these more carefully and fixing up the typos, all architectures have been build-tested again to ensure that this is now complete.

Fixes 4e0d84634445 ("futex: Fix sparc32/m68k/nds32 build regression")
Fixes 3f2bedabb62c ("futex: Ensure futex_atomic_cmpxchg_inatomic() is present")
---
 arch/mips/include/asm/futex.h   | 6 +++---
 arch/xtensa/include/asm/futex.h | 2 +-
 include/asm-generic/futex.h     | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)
arch/mips/include/asm/futex.h +3 -3
index 9287110..8612a7e 100644
@@ -86,9 +86,9 @@
 		: "memory");						\
 	} else {							\
 		/* fallback for non-SMP */				\
-		ret = arch_futex_atomic_op_inuser_local(op, oparg, oval,\
-							uaddr);	\
-	}
+		ret = futex_atomic_op_inuser_local(op, oparg, oval, uaddr);	\
+	}								\
+}
 
 static inline int
 arch_futex_atomic_op_inuser(int op, int oparg, int *oval, u32 __user *uaddr)
arch/xtensa/include/asm/futex.h +1 -1
index fe8f315..a6f7d7a 100644
@@ -109,7 +109,7 @@ static inline int arch_futex_atomic_op_inuser(int op, int oparg, int *oval,
 
 	return ret;
 #else
-	return arch_futex_atomic_op_inuser_local(op, oparg, oval, uaddr);
+	return futex_atomic_op_inuser_local(op, oparg, oval, uaddr);
 #endif
 }
 
include/asm-generic/futex.h +1 -1
index 66d6843..2a19215 100644
@@ -21,7 +21,7 @@
 #endif
 
 /**
- * arch_futex_atomic_op_inuser_local() - Atomic arithmetic operation with constant
+ * futex_atomic_op_inuser_local() - Atomic arithmetic operation with constant
  *			  argument and comparison of the previous
  *			  futex value with another constant.
  *