CLEANUP: fd/threads: remove the now unused fdtab_lock
It was only used to protect maxfd computation and is not needed
anymore.
diff --git a/include/common/hathreads.h b/include/common/hathreads.h
index cfcb48e..fe1ee23 100644
--- a/include/common/hathreads.h
+++ b/include/common/hathreads.h
@@ -203,7 +203,6 @@
enum lock_label {
THREAD_SYNC_LOCK = 0,
- FDTAB_LOCK,
FDCACHE_LOCK,
FD_LOCK,
POLL_LOCK,
diff --git a/include/proto/fd.h b/include/proto/fd.h
index 76d4c7e..c9449ff 100644
--- a/include/proto/fd.h
+++ b/include/proto/fd.h
@@ -40,7 +40,6 @@
extern THREAD_LOCAL int *fd_updt; // FD updates list
extern THREAD_LOCAL int fd_nbupdt; // number of updates in the list
-__decl_hathreads(extern HA_SPINLOCK_T __attribute__((aligned(64))) fdtab_lock); /* global lock to protect fdtab array */
__decl_hathreads(extern HA_RWLOCK_T __attribute__((aligned(64))) fdcache_lock); /* global lock to protect fd_cache array */
__decl_hathreads(extern HA_SPINLOCK_T __attribute__((aligned(64))) poll_lock); /* global lock to protect poll info */
diff --git a/src/fd.c b/src/fd.c
index 1fa170b..9398364 100644
--- a/src/fd.c
+++ b/src/fd.c
@@ -174,7 +174,6 @@
THREAD_LOCAL int *fd_updt = NULL; // FD updates list
THREAD_LOCAL int fd_nbupdt = 0; // number of updates in the list
-__decl_hathreads(HA_SPINLOCK_T fdtab_lock); /* global lock to protect fdtab array */
__decl_hathreads(HA_RWLOCK_T fdcache_lock); /* global lock to protect fd_cache array */
__decl_hathreads(HA_SPINLOCK_T poll_lock); /* global lock to protect poll info */
@@ -332,7 +331,6 @@
for (p = 0; p < global.maxsock; p++)
HA_SPIN_INIT(&fdtab[p].lock);
- HA_SPIN_INIT(&fdtab_lock);
HA_RWLOCK_INIT(&fdcache_lock);
HA_SPIN_INIT(&poll_lock);
do {
@@ -381,7 +379,6 @@
free(fdinfo); fdinfo = NULL;
free(fdtab); fdtab = NULL;
- HA_SPIN_DESTROY(&fdtab_lock);
HA_RWLOCK_DESTROY(&fdcache_lock);
HA_SPIN_DESTROY(&poll_lock);
}