REORG: include: split mini-clist into haproxy/list and list-t.h
Half of the users of this include only need the type definitions and
not the manipulation macros nor the inline functions. Moves the various
types into mini-clist-t.h makes the files cleaner. The other one had all
its includes grouped at the top. A few files continued to reference it
without using it and were cleaned.
In addition it was about time that we'd rename that file, it's not
"mini" anymore and contains a bit more than just circular lists.
diff --git a/contrib/hpack/decode.c b/contrib/hpack/decode.c
index ce3b484..8dbb6f1 100644
--- a/contrib/hpack/decode.c
+++ b/contrib/hpack/decode.c
@@ -20,7 +20,6 @@
#include <unistd.h>
#include <common/chunk.h>
#include <common/hpack-dec.h>
-#include <common/mini-clist.h>
#define MAX_RQ_SIZE 65536
#define MAX_HDR_NUM 1000
diff --git a/contrib/mod_defender/spoa.c b/contrib/mod_defender/spoa.c
index 079e880..530b42d 100644
--- a/contrib/mod_defender/spoa.c
+++ b/contrib/mod_defender/spoa.c
@@ -31,7 +31,7 @@
#include <event2/event_struct.h>
#include <event2/thread.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/chunk.h>
#include <proto/spoe.h>
diff --git a/contrib/modsecurity/spoa.c b/contrib/modsecurity/spoa.c
index 20916fd..ded8a6f 100644
--- a/contrib/modsecurity/spoa.c
+++ b/contrib/modsecurity/spoa.c
@@ -36,7 +36,7 @@
#include <event2/event_struct.h>
#include <event2/thread.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/chunk.h>
#include <proto/spoe.h>
diff --git a/contrib/prometheus-exporter/service-prometheus.c b/contrib/prometheus-exporter/service-prometheus.c
index a31aa15..6afa43f 100644
--- a/contrib/prometheus-exporter/service-prometheus.c
+++ b/contrib/prometheus-exporter/service-prometheus.c
@@ -18,7 +18,7 @@
#include <common/buffer.h>
#include <common/htx.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <types/global.h>
diff --git a/include/common/cfgparse.h b/include/common/cfgparse.h
index 8ecb771..86f87bf 100644
--- a/include/common/cfgparse.h
+++ b/include/common/cfgparse.h
@@ -23,7 +23,7 @@
#define _COMMON_CFGPARSE_H
#include <haproxy/api.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <proto/log.h>
#include <proto/proxy.h>
diff --git a/include/common/memory.h b/include/common/memory.h
index 8b03daf..d80b486 100644
--- a/include/common/memory.h
+++ b/include/common/memory.h
@@ -29,7 +29,7 @@
#include <unistd.h>
#include <haproxy/api.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/hathreads.h>
/* On architectures supporting threads and double-word CAS, we can implement
diff --git a/include/haproxy/list-t.h b/include/haproxy/list-t.h
new file mode 100644
index 0000000..dd8493e
--- /dev/null
+++ b/include/haproxy/list-t.h
@@ -0,0 +1,73 @@
+/*
+ * include/haproxy/list-t.h
+ * Circular list manipulation types definitions
+ *
+ * Copyright (C) 2002-2020 Willy Tarreau - w@1wt.eu
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, version 2.1
+ * exclusively.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef _HAPROXY_LIST_T_H
+#define _HAPROXY_LIST_T_H
+
+
+/* these are circular or bidirectionnal lists only. Each list pointer points to
+ * another list pointer in a structure, and not the structure itself. The
+ * pointer to the next element MUST be the first one so that the list is easily
+ * cast as a single linked list or pointer.
+ */
+struct list {
+ struct list *n; /* next */
+ struct list *p; /* prev */
+};
+
+/* This is similar to struct list, but we want to be sure the compiler will
+ * yell at you if you use macroes for one when you're using the other. You have
+ * to expicitely cast if that's really what you want to do.
+ */
+struct mt_list {
+ struct mt_list *next;
+ struct mt_list *prev;
+};
+
+
+/* a back-ref is a pointer to a target list entry. It is used to detect when an
+ * element being deleted is currently being tracked by another user. The best
+ * example is a user dumping the session table. The table does not fit in the
+ * output buffer so we have to set a mark on a session and go on later. But if
+ * that marked session gets deleted, we don't want the user's pointer to go in
+ * the wild. So we can simply link this user's request to the list of this
+ * session's users, and put a pointer to the list element in ref, that will be
+ * used as the mark for next iteration.
+ */
+struct bref {
+ struct list users;
+ struct list *ref; /* pointer to the target's list entry */
+};
+
+/* a word list is a generic list with a pointer to a string in each element. */
+struct wordlist {
+ struct list list;
+ char *s;
+};
+
+/* this is the same as above with an additional pointer to a condition. */
+struct cond_wordlist {
+ struct list list;
+ void *cond;
+ char *s;
+};
+
+#endif /* _HAPROXY_LIST_T_H */
diff --git a/include/common/mini-clist.h b/include/haproxy/list.h
similarity index 94%
rename from include/common/mini-clist.h
rename to include/haproxy/list.h
index 188d118..0281aa1 100644
--- a/include/common/mini-clist.h
+++ b/include/haproxy/list.h
@@ -1,8 +1,8 @@
/*
- * include/common/mini-clist.h
- * Circular list manipulation macros and structures.
+ * include/haproxy/list.h
+ * Circular list manipulation macros and functions.
*
- * Copyright (C) 2002-2014 Willy Tarreau - w@1wt.eu
+ * Copyright (C) 2002-2020 Willy Tarreau - w@1wt.eu
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -19,56 +19,12 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef _COMMON_MINI_CLIST_H
-#define _COMMON_MINI_CLIST_H
+#ifndef _HAPROXY_LIST_H
+#define _HAPROXY_LIST_H
-
-/* these are circular or bidirectionnal lists only. Each list pointer points to
- * another list pointer in a structure, and not the structure itself. The
- * pointer to the next element MUST be the first one so that the list is easily
- * cast as a single linked list or pointer.
- */
-struct list {
- struct list *n; /* next */
- struct list *p; /* prev */
-};
-
-/* This is similar to struct list, but we want to be sure the compiler will
- * yell at you if you use macroes for one when you're using the other. You have
- * to expicitely cast if that's really what you want to do.
- */
-struct mt_list {
- struct mt_list *next;
- struct mt_list *prev;
-};
-
-
-/* a back-ref is a pointer to a target list entry. It is used to detect when an
- * element being deleted is currently being tracked by another user. The best
- * example is a user dumping the session table. The table does not fit in the
- * output buffer so we have to set a mark on a session and go on later. But if
- * that marked session gets deleted, we don't want the user's pointer to go in
- * the wild. So we can simply link this user's request to the list of this
- * session's users, and put a pointer to the list element in ref, that will be
- * used as the mark for next iteration.
- */
-struct bref {
- struct list users;
- struct list *ref; /* pointer to the target's list entry */
-};
-
-/* a word list is a generic list with a pointer to a string in each element. */
-struct wordlist {
- struct list list;
- char *s;
-};
-
-/* this is the same as above with an additional pointer to a condition. */
-struct cond_wordlist {
- struct list list;
- void *cond;
- char *s;
-};
+#include <haproxy/api.h>
+#include <haproxy/list-t.h>
+#include <common/hathreads.h>
/* First undefine some macros which happen to also be defined on OpenBSD,
* in sys/queue.h, used by sys/event.h
@@ -257,15 +213,13 @@
&item->member != (list_head); \
item = back, back = LIST_ELEM(back->member.p, typeof(back), member))
-#include <haproxy/api.h>
-#include <common/hathreads.h>
-#define MT_LIST_BUSY ((struct mt_list *)1)
/*
* Locked version of list manipulation macros.
* It is OK to use those concurrently from multiple threads, as long as the
* list is only used with the locked variants.
*/
+#define MT_LIST_BUSY ((struct mt_list *)1)
/*
* Add an item at the beginning of a list.
@@ -733,4 +687,4 @@
}
-#endif /* _COMMON_MINI_CLIST_H */
+#endif /* _HAPROXY_LIST_H */
diff --git a/include/proto/applet.h b/include/proto/applet.h
index ea8bc0b..aaa4903 100644
--- a/include/proto/applet.h
+++ b/include/proto/applet.h
@@ -26,7 +26,7 @@
#include <haproxy/api.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <types/applet.h>
#include <proto/task.h>
diff --git a/include/proto/http_rules.h b/include/proto/http_rules.h
index 27c4b6a..84f302d 100644
--- a/include/proto/http_rules.h
+++ b/include/proto/http_rules.h
@@ -23,7 +23,7 @@
#define _PROTO_HTTP_RULES_H
#include <haproxy/api.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <types/action.h>
#include <types/proxy.h>
diff --git a/include/proto/queue.h b/include/proto/queue.h
index 8ef9179..9bec9b4 100644
--- a/include/proto/queue.h
+++ b/include/proto/queue.h
@@ -24,7 +24,6 @@
#include <haproxy/api.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
#include <types/proxy.h>
#include <types/queue.h>
diff --git a/include/proto/shctx.h b/include/proto/shctx.h
index 25bf377..76f498f 100644
--- a/include/proto/shctx.h
+++ b/include/proto/shctx.h
@@ -14,7 +14,7 @@
#ifndef SHCTX_H
#define SHCTX_H
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <types/shctx.h>
#include <inttypes.h>
diff --git a/include/proto/sink.h b/include/proto/sink.h
index d30f30a..c0c75c3 100644
--- a/include/proto/sink.h
+++ b/include/proto/sink.h
@@ -22,7 +22,7 @@
#ifndef _PROTO_SINK_H
#define _PROTO_SINK_H
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <types/sink.h>
extern struct list sink_list;
diff --git a/include/proto/task.h b/include/proto/task.h
index a42431a..944ada5 100644
--- a/include/proto/task.h
+++ b/include/proto/task.h
@@ -27,7 +27,7 @@
#include <haproxy/api.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/ticks.h>
#include <common/hathreads.h>
diff --git a/include/proto/trace.h b/include/proto/trace.h
index f43faf5..1447940 100644
--- a/include/proto/trace.h
+++ b/include/proto/trace.h
@@ -25,7 +25,7 @@
#include <haproxy/api.h>
#include <common/buffer.h>
#include <import/ist.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <types/log.h>
#include <types/sink.h>
#include <types/trace.h>
diff --git a/include/types/acl.h b/include/types/acl.h
index 748f361..7afa3d8 100644
--- a/include/types/acl.h
+++ b/include/types/acl.h
@@ -23,7 +23,7 @@
#define _TYPES_ACL_H
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <types/arg.h>
#include <types/auth.h>
diff --git a/include/types/arg.h b/include/types/arg.h
index 60fd007..366c09e 100644
--- a/include/types/arg.h
+++ b/include/types/arg.h
@@ -26,7 +26,7 @@
#include <netinet/in.h>
#include <common/chunk.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <types/vars.h>
#include <types/protocol_buffers.h>
diff --git a/include/types/auth.h b/include/types/auth.h
index c10aced..f9b56f1 100644
--- a/include/types/auth.h
+++ b/include/types/auth.h
@@ -14,7 +14,7 @@
#define _TYPES_AUTH_H
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <types/auth.h>
diff --git a/include/types/checks.h b/include/types/checks.h
index 6d07c9a..3ea4a06 100644
--- a/include/types/checks.h
+++ b/include/types/checks.h
@@ -18,7 +18,7 @@
#include <common/standard.h>
#include <import/ist.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/regex.h>
#include <haproxy/buf-t.h>
diff --git a/include/types/cli.h b/include/types/cli.h
index 8a44124..41753c5 100644
--- a/include/types/cli.h
+++ b/include/types/cli.h
@@ -20,7 +20,7 @@
#ifndef _TYPES_CLI_H
#define _TYPES_CLI_H
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <types/applet.h>
/* Access level for a stats socket */
diff --git a/include/types/dns.h b/include/types/dns.h
index 06afda8..84a8219 100644
--- a/include/types/dns.h
+++ b/include/types/dns.h
@@ -24,7 +24,7 @@
#include <import/eb32tree.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/hathreads.h>
#include <types/connection.h>
diff --git a/include/types/fcgi-app.h b/include/types/fcgi-app.h
index 7fb20ee..c88dda3 100644
--- a/include/types/fcgi-app.h
+++ b/include/types/fcgi-app.h
@@ -25,7 +25,7 @@
#include <haproxy/api-t.h>
#include <import/ist.h>
#include <common/fcgi.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/regex.h>
#include <import/ebistree.h>
diff --git a/include/types/filters.h b/include/types/filters.h
index 5de4eee..2e06b83 100644
--- a/include/types/filters.h
+++ b/include/types/filters.h
@@ -22,7 +22,7 @@
#define _TYPES_FILTERS_H
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
struct http_msg;
struct proxy;
diff --git a/include/types/listener.h b/include/types/listener.h
index 7374dc8..4314209 100644
--- a/include/types/listener.h
+++ b/include/types/listener.h
@@ -30,7 +30,7 @@
#include <haproxy/openssl-compat.h>
#endif
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/hathreads.h>
#include <types/obj_type.h>
diff --git a/include/types/log.h b/include/types/log.h
index 2c2ac02..301c2bf 100644
--- a/include/types/log.h
+++ b/include/types/log.h
@@ -27,7 +27,7 @@
#include <netinet/in.h>
#include <haproxy/api-t.h>
#include <common/hathreads.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <types/ring.h>
#define NB_LOG_FACILITIES 24
diff --git a/include/types/pattern.h b/include/types/pattern.h
index f1468b3..1a3e076 100644
--- a/include/types/pattern.h
+++ b/include/types/pattern.h
@@ -23,7 +23,7 @@
#define _TYPES_PATTERN_H
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/regex.h>
#include <types/sample.h>
diff --git a/include/types/peers.h b/include/types/peers.h
index 7461347..b3e1e44 100644
--- a/include/types/peers.h
+++ b/include/types/peers.h
@@ -28,7 +28,7 @@
#include <arpa/inet.h>
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/regex.h>
#include <import/eb32tree.h>
diff --git a/include/types/protocol.h b/include/types/protocol.h
index edda61c..0c49068 100644
--- a/include/types/protocol.h
+++ b/include/types/protocol.h
@@ -26,7 +26,7 @@
#include <sys/socket.h>
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <import/eb32tree.h>
/* some pointer types referenced below */
diff --git a/include/types/proxy.h b/include/types/proxy.h
index c75f0b6..f7bdd30 100644
--- a/include/types/proxy.h
+++ b/include/types/proxy.h
@@ -30,7 +30,7 @@
#include <haproxy/api-t.h>
#include <common/chunk.h>
#include <common/http.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/regex.h>
#include <common/hathreads.h>
diff --git a/include/types/queue.h b/include/types/queue.h
index b0800f3..9333468 100644
--- a/include/types/queue.h
+++ b/include/types/queue.h
@@ -23,7 +23,7 @@
#define _TYPES_QUEUE_H
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/hathreads.h>
#include <types/server.h>
diff --git a/include/types/sample.h b/include/types/sample.h
index bb6b092..618be08 100644
--- a/include/types/sample.h
+++ b/include/types/sample.h
@@ -28,7 +28,7 @@
#include <haproxy/buf-t.h>
#include <common/http.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
struct arg;
diff --git a/include/types/server.h b/include/types/server.h
index c8e5bb6..1737f80 100644
--- a/include/types/server.h
+++ b/include/types/server.h
@@ -26,7 +26,7 @@
#include <arpa/inet.h>
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/api.h>
#include <common/hathreads.h>
#include <haproxy/openssl-compat.h>
diff --git a/include/types/session.h b/include/types/session.h
index fb6b621..57ee52a 100644
--- a/include/types/session.h
+++ b/include/types/session.h
@@ -29,7 +29,7 @@
#include <arpa/inet.h>
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <types/obj_type.h>
#include <types/proxy.h>
diff --git a/include/types/signal.h b/include/types/signal.h
index 661347a..838aefd 100644
--- a/include/types/signal.h
+++ b/include/types/signal.h
@@ -17,7 +17,7 @@
#include <signal.h>
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/standard.h>
/* flags for -> flags */
diff --git a/include/types/spoe.h b/include/types/spoe.h
index eaa0ef0..85f8b43 100644
--- a/include/types/spoe.h
+++ b/include/types/spoe.h
@@ -25,7 +25,7 @@
#include <sys/time.h>
#include <common/buffer.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/hathreads.h>
#include <types/filters.h>
diff --git a/include/types/ssl_ckch.h b/include/types/ssl_ckch.h
index a63ec1d..a410810 100644
--- a/include/types/ssl_ckch.h
+++ b/include/types/ssl_ckch.h
@@ -33,7 +33,7 @@
#define _TYPES_SSL_CKCH_H
#ifdef USE_OPENSSL
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <haproxy/openssl-compat.h>
/* This is used to preload the certificate, private key
diff --git a/include/types/ssl_crtlist.h b/include/types/ssl_crtlist.h
index 2879d74..ed8c135 100644
--- a/include/types/ssl_crtlist.h
+++ b/include/types/ssl_crtlist.h
@@ -25,7 +25,7 @@
#include <import/ebmbtree.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
/* forward declarations for structures below */
struct bind_conf;
diff --git a/include/types/ssl_sock.h b/include/types/ssl_sock.h
index be58aa8..d62e4dd 100644
--- a/include/types/ssl_sock.h
+++ b/include/types/ssl_sock.h
@@ -33,7 +33,7 @@
#include <common/buffer.h>
#include <common/hathreads.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <haproxy/openssl-compat.h>
/* ***** READ THIS before adding code here! *****
diff --git a/include/types/stream.h b/include/types/stream.h
index e450c63..37bdb96 100644
--- a/include/types/stream.h
+++ b/include/types/stream.h
@@ -29,7 +29,7 @@
#include <arpa/inet.h>
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <types/channel.h>
#include <types/filters.h>
diff --git a/include/types/task.h b/include/types/task.h
index 01756ea..fe945df 100644
--- a/include/types/task.h
+++ b/include/types/task.h
@@ -25,7 +25,7 @@
#include <sys/time.h>
#include <haproxy/api-t.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <import/eb32sctree.h>
#include <import/eb32tree.h>
diff --git a/include/types/trace.h b/include/types/trace.h
index ad9d7b6..c119ab3 100644
--- a/include/types/trace.h
+++ b/include/types/trace.h
@@ -25,7 +25,7 @@
#include <haproxy/api-t.h>
#include <common/buffer.h>
#include <import/ist.h>
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <types/sink.h>
/* the macros below define an optional type for each of the 4 args passed to
diff --git a/include/types/vars.h b/include/types/vars.h
index a72469f..91fcf07 100644
--- a/include/types/vars.h
+++ b/include/types/vars.h
@@ -1,7 +1,7 @@
#ifndef _TYPES_VARS_H
#define _TYPES_VARS_H
-#include <common/mini-clist.h>
+#include <haproxy/list-t.h>
#include <common/hathreads.h>
#include <types/sample.h>
diff --git a/src/acl.c b/src/acl.c
index 5b25fce..14a0e0b 100644
--- a/src/acl.c
+++ b/src/acl.c
@@ -15,7 +15,7 @@
#include <string.h>
#include <haproxy/api.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/uri_auth.h>
diff --git a/src/action.c b/src/action.c
index 0854208..cb897b6 100644
--- a/src/action.c
+++ b/src/action.c
@@ -12,7 +12,7 @@
#include <haproxy/api.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <proto/action.h>
diff --git a/src/applet.c b/src/applet.c
index 5f06d6a..88be447 100644
--- a/src/applet.c
+++ b/src/applet.c
@@ -14,7 +14,7 @@
#include <stdlib.h>
#include <haproxy/api.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <proto/applet.h>
#include <proto/channel.h>
#include <proto/stream.h>
diff --git a/src/checks.c b/src/checks.c
index de182db..5dbbeca 100644
--- a/src/checks.c
+++ b/src/checks.c
@@ -33,7 +33,7 @@
#include <haproxy/api.h>
#include <common/cfgparse.h>
#include <common/chunk.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/time.h>
#include <common/hathreads.h>
diff --git a/src/cli.c b/src/cli.c
index a0118dc..4b9c31f 100644
--- a/src/cli.c
+++ b/src/cli.c
@@ -29,7 +29,7 @@
#include <haproxy/api.h>
#include <common/cfgparse.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/ticks.h>
#include <common/time.h>
diff --git a/src/flt_http_comp.c b/src/flt_http_comp.c
index abec6b3..9ca51e5 100644
--- a/src/flt_http_comp.c
+++ b/src/flt_http_comp.c
@@ -14,7 +14,7 @@
#include <common/buffer.h>
#include <common/cfgparse.h>
#include <common/htx.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <types/compression.h>
diff --git a/src/haproxy.c b/src/haproxy.c
index 79a28ac..a1dff0c 100644
--- a/src/haproxy.c
+++ b/src/haproxy.c
@@ -86,7 +86,7 @@
#include <common/chunk.h>
#include <haproxy/errors.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/namespace.h>
#include <common/net_helper.h>
#include <haproxy/openssl-compat.h>
diff --git a/src/listener.c b/src/listener.c
index a1b6ae4..c035ed8 100644
--- a/src/listener.c
+++ b/src/listener.c
@@ -21,7 +21,7 @@
#include <haproxy/api.h>
#include <common/cfgparse.h>
#include <haproxy/errors.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/time.h>
diff --git a/src/memory.c b/src/memory.c
index 961a292..2caf13d 100644
--- a/src/memory.c
+++ b/src/memory.c
@@ -20,7 +20,7 @@
#include <common/cfgparse.h>
#include <common/hathreads.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <types/activity.h>
diff --git a/src/mux_fcgi.c b/src/mux_fcgi.c
index 7ff3932..87c84fb 100644
--- a/src/mux_fcgi.c
+++ b/src/mux_fcgi.c
@@ -16,7 +16,7 @@
#include <common/h1.h>
#include <common/htx.h>
#include <import/ist.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/net_helper.h>
#include <types/proxy.h>
diff --git a/src/mworker.c b/src/mworker.c
index 95c06bb..4b2a7af 100644
--- a/src/mworker.c
+++ b/src/mworker.c
@@ -19,7 +19,7 @@
#include <haproxy/api.h>
#include <common/cfgparse.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <haproxy/version.h>
#include <types/cli.h>
diff --git a/src/proto_sockpair.c b/src/proto_sockpair.c
index c95d5d4..b627724 100644
--- a/src/proto_sockpair.c
+++ b/src/proto_sockpair.c
@@ -28,7 +28,7 @@
#include <haproxy/api.h>
#include <haproxy/errors.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/time.h>
#include <haproxy/version.h>
diff --git a/src/proto_tcp.c b/src/proto_tcp.c
index 9233288..9d87515 100644
--- a/src/proto_tcp.c
+++ b/src/proto_tcp.c
@@ -32,7 +32,7 @@
#include <haproxy/api.h>
#include <haproxy/errors.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/namespace.h>
diff --git a/src/proto_uxst.c b/src/proto_uxst.c
index 648f3a3..ae68a8d 100644
--- a/src/proto_uxst.c
+++ b/src/proto_uxst.c
@@ -28,7 +28,7 @@
#include <haproxy/api.h>
#include <haproxy/errors.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/time.h>
#include <haproxy/version.h>
diff --git a/src/protocol.c b/src/protocol.c
index 3a11bdd..4909ee1 100644
--- a/src/protocol.c
+++ b/src/protocol.c
@@ -15,7 +15,7 @@
#include <haproxy/api.h>
#include <haproxy/errors.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <proto/protocol.h>
diff --git a/src/shctx.c b/src/shctx.c
index bfca085..113828a 100644
--- a/src/shctx.c
+++ b/src/shctx.c
@@ -15,7 +15,7 @@
#include <arpa/inet.h>
#include <import/ebmbtree.h>
#include <types/global.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include "proto/shctx.h"
#if !defined (USE_PRIVATE_CACHE)
diff --git a/src/sink.c b/src/sink.c
index 7eb283f..9ed75ac 100644
--- a/src/sink.c
+++ b/src/sink.c
@@ -21,7 +21,7 @@
#include <haproxy/api.h>
#include <common/cfgparse.h>
#include <import/ist.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/time.h>
#include <proto/cli.h>
#include <proto/log.h>
diff --git a/src/stats.c b/src/stats.c
index 05dc223..e7a1e76 100644
--- a/src/stats.c
+++ b/src/stats.c
@@ -30,7 +30,7 @@
#include <common/http.h>
#include <common/htx.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/ticks.h>
#include <common/time.h>
diff --git a/src/stick_table.c b/src/stick_table.c
index 37131f6..dc2ef4f 100644
--- a/src/stick_table.c
+++ b/src/stick_table.c
@@ -17,7 +17,7 @@
#include <haproxy/api.h>
#include <common/cfgparse.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/net_helper.h>
#include <common/standard.h>
#include <common/time.h>
diff --git a/src/task.c b/src/task.c
index a116b2e..fc09787 100644
--- a/src/task.c
+++ b/src/task.c
@@ -14,7 +14,7 @@
#include <haproxy/api.h>
#include <common/memory.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/time.h>
#include <import/eb32sctree.h>
diff --git a/src/tcp_rules.c b/src/tcp_rules.c
index 0be4ecd..1943018 100644
--- a/src/tcp_rules.c
+++ b/src/tcp_rules.c
@@ -11,7 +11,7 @@
*/
#include <haproxy/api.h>
#include <common/cfgparse.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <common/standard.h>
#include <common/ticks.h>
#include <common/time.h>
diff --git a/src/trace.c b/src/trace.c
index 3f6ff05..a0b9648 100644
--- a/src/trace.c
+++ b/src/trace.c
@@ -21,7 +21,7 @@
#include <haproxy/api.h>
#include <common/buffer.h>
#include <import/ist.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <proto/cli.h>
#include <proto/log.h>
#include <proto/sink.h>
diff --git a/src/vars.c b/src/vars.c
index a213657..227c94b 100644
--- a/src/vars.c
+++ b/src/vars.c
@@ -3,7 +3,7 @@
#include <haproxy/api.h>
#include <common/cfgparse.h>
#include <common/http.h>
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
#include <types/vars.h>
diff --git a/tests/test-list.c b/tests/test-list.c
index d95800e..5e54f60 100644
--- a/tests/test-list.c
+++ b/tests/test-list.c
@@ -2,7 +2,7 @@
#include <stdio.h>
#include <stdlib.h>
#define USE_THREAD
-#include <common/mini-clist.h>
+#include <haproxy/list.h>
/* Stress test the mt_lists.
* Compile from the haproxy directory with :