3ce7d3
diff --git a/configure.in b/configure.in
3ce7d3
index 896e81c1ce..73b1c8ccbb 100644
3ce7d3
--- a/configure.in
3ce7d3
+++ b/configure.in
3ce7d3
@@ -4275,6 +4275,10 @@ if test "yes" = "$use_atomic"; then
bc5dde
 	AC_MSG_RESULT($arch)
bc5dde
 fi
bc5dde
 
bc5dde
+if test ! "$arch" = "x86_64" -a "$have_xaddq" = "yes"; then
bc5dde
+	AC_MSG_ERROR([XADDQ present but disabled by Fedora patch!])
bc5dde
+fi
bc5dde
+
3ce7d3
 if test "yes" = "$have_atomic"; then
bc5dde
 	AC_MSG_CHECKING([compiler support for inline assembly code])
bc5dde
 
3ce7d3
diff --git a/lib/isc/include/isc/platform.h.in b/lib/isc/include/isc/platform.h.in
3ce7d3
index 2ff522342f..58df86adb3 100644
3ce7d3
--- a/lib/isc/include/isc/platform.h.in
3ce7d3
+++ b/lib/isc/include/isc/platform.h.in
3ce7d3
@@ -289,19 +289,25 @@
bc5dde
  * If the "xaddq" operation (64bit xadd) is available on this architecture,
bc5dde
  * ISC_PLATFORM_HAVEXADDQ will be defined.
bc5dde
  */
bc5dde
-@ISC_PLATFORM_HAVEXADDQ@
3ce7d3
 
3ce7d3
 /*
3ce7d3
- * If the 32-bit "atomic swap" operation is available on this
3ce7d3
- * architecture, ISC_PLATFORM_HAVEATOMICSTORE" will be defined.
3ce7d3
+ * If the 64-bit "atomic swap" operation is available on this
3ce7d3
+ * architecture, ISC_PLATFORM_HAVEATOMICSTOREQ" will be defined.
3ce7d3
  */
3ce7d3
-@ISC_PLATFORM_HAVEATOMICSTORE@
3ce7d3
+
bc5dde
+#ifdef __x86_64__
bc5dde
+#define ISC_PLATFORM_HAVEXADDQ 1
3ce7d3
+#define ISC_PLATFORM_HAVEATOMICSTOREQ 1
bc5dde
+#else
bc5dde
+#undef ISC_PLATFORM_HAVEXADDQ
3ce7d3
+#undef ISC_PLATFORM_HAVEATOMICSTOREQ
bc5dde
+#endif
bc5dde
 
bc5dde
 /*
3ce7d3
- * If the 64-bit "atomic swap" operation is available on this
3ce7d3
+ * If the 32-bit "atomic swap" operation is available on this
3ce7d3
  * architecture, ISC_PLATFORM_HAVEATOMICSTORE" will be defined.
3ce7d3
  */
3ce7d3
-@ISC_PLATFORM_HAVEATOMICSTOREQ@
3ce7d3
+@ISC_PLATFORM_HAVEATOMICSTORE@
3ce7d3
 
3ce7d3
 /*
3ce7d3
  * If the "compare-and-exchange" operation is available on this architecture,