CLENAUP: config: move CONFIG_HAP_LOCKLESS_POOLS out of config.h

The setting of CONFIG_HAP_LOCKLESS_POOLS depending on threads and
compat was done in config.h for use only in memory.h and memory.c
where other settings are dealt with. Further, the default pool cache
size was set there from a fixed value instead of being set from
defaults.h

Let's move the decision to enable lockless pools via
CONFIG_HAP_LOCKLESS_POOLS to memory.h, and set the default pool
cache size in defaults.h like other default settings.

This was the next-to-last setting in config.h.
diff --git a/include/common/memory.h b/include/common/memory.h
index 44a9dcb..7bcef94 100644
--- a/include/common/memory.h
+++ b/include/common/memory.h
@@ -34,6 +34,13 @@
 #include <common/hathreads.h>
 #include <common/initcall.h>
 
+/* On architectures supporting threads and double-word CAS, we can implement
+ * lock-less memory pools. This isn't supported for debugging modes however.
+ */
+#if defined(USE_THREAD) && defined(HA_HAVE_CAS_DW) && !defined(DEBUG_NO_LOCKLESS_POOLS) && !defined(DEBUG_UAF) && !defined(DEBUG_FAIL_ALLOC)
+#define CONFIG_HAP_LOCKLESS_POOLS
+#endif
+
 #ifndef DEBUG_DONT_SHARE_POOLS
 #define MEM_F_SHARED	0x1
 #else