]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
MINOR: mux_quic: Export the mux related flags
authorFrédéric Lécaille <flecaille@haproxy.com>
Mon, 20 Sep 2021 13:11:51 +0000 (15:11 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 23 Sep 2021 13:27:25 +0000 (15:27 +0200)
These flags should be available from the xprt which must be able to
wake up the mux when blocked.

include/haproxy/mux_quic-t.h
src/mux_quic.c

index 241aa60e4f6ea822b3f39ecc5e9f063722e309e3..18e2cec954899300bbd682b9fce1a12aaa9b65b7 100644 (file)
 #define OUQS_SF_TXBUF_MALLOC 0x00000001
 #define OUQS_SF_TXBUF_FULL   0x00000002
 
+/* Connection flags (32 bit), in qcc->flags */
+#define QC_CF_NONE              0x00000000
+
+/* Flags indicating why writing to the mux is blocked. */
+#define QC_CF_MUX_MALLOC        0x00000001  // mux blocked on lack of connection's mux buffer
+#define QC_CF_MUX_MFULL         0x00000002  // mux blocked on connection's mux buffer full
+#define QC_CF_MUX_BLOCK_ANY     0x00000003  // aggregate of the mux flags above
+
+/* Flags indicating why writing to the demux is blocked.
+ * The first two ones directly affect the ability for the mux to receive data
+ * from the connection. The other ones affect the mux's ability to demux
+ * received data.
+ */
+#define QC_CF_DEM_DFULL         0x00000004  // demux blocked on connection's demux buffer full
+
+#define QC_CF_DEM_MBUSY         0x00000008  // demux blocked on connection's mux side busy
+#define QC_CF_DEM_MROOM         0x00000010  // demux blocked on lack of room in mux buffer
+#define QC_CF_DEM_SALLOC        0x00000020  // demux blocked on lack of stream's request buffer
+#define QC_CF_DEM_SFULL         0x00000040  // demux blocked on stream request buffer full
+#define QC_CF_DEM_TOOMANY       0x00000100  // demux blocked waiting for some conn_streams to leave
+#define QC_CF_DEM_BLOCK_ANY     0x00000170  // aggregate of the demux flags above except DFULL
+
+/* other flags */
+#define QC_CF_IS_BACK           0x00008000  // this is an outgoing connection
+
 extern struct pool_head *pool_head_qcs;
 
 /* Stream types */
index b471bf54a19bd7d266360210597b6c6e70e4fa9d..8b96b6fd9ad4f5a4e21bdc999e52e28d2c18b762 100644 (file)
 /* dummy streams returned for closed, error, refused, idle and states */
 static const struct qcs *qc_closed_stream;
 
-/* Connection flags (32 bit), in qcc->flags */
-#define QC_CF_NONE              0x00000000
-
-/* Flags indicating why writing to the mux is blocked. */
-#define QC_CF_MUX_MALLOC        0x00000001  // mux blocked on lack of connection's mux buffer
-#define QC_CF_MUX_MFULL         0x00000002  // mux blocked on connection's mux buffer full
-#define QC_CF_MUX_BLOCK_ANY     0x00000003  // aggregate of the mux flags above
-
-/* Flags indicating why writing to the demux is blocked.
- * The first two ones directly affect the ability for the mux to receive data
- * from the connection. The other ones affect the mux's ability to demux
- * received data.
- */
-#define QC_CF_DEM_DFULL         0x00000004  // demux blocked on connection's demux buffer full
-
-#define QC_CF_DEM_MBUSY         0x00000008  // demux blocked on connection's mux side busy
-#define QC_CF_DEM_MROOM         0x00000010  // demux blocked on lack of room in mux buffer
-#define QC_CF_DEM_SALLOC        0x00000020  // demux blocked on lack of stream's request buffer
-#define QC_CF_DEM_SFULL         0x00000040  // demux blocked on stream request buffer full
-#define QC_CF_DEM_TOOMANY       0x00000100  // demux blocked waiting for some conn_streams to leave
-#define QC_CF_DEM_BLOCK_ANY     0x00000170  // aggregate of the demux flags above except DFULL
-
-/* other flags */
-#define QC_CF_IS_BACK           0x00008000  // this is an outgoing connection
-
 #define QC_SS_MASK(state) (1UL << (state))
 #define QC_SS_IDLE_BIT    (1UL << QC_SS_IDLE)
 #define QC_SS_RLOC_BIT    (1UL << QC_SS_RLOC)