]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
CLEANUP: channel: Remove the unused flag CF_WAKE_CONNECT
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 16 Jul 2019 12:43:08 +0000 (14:43 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 19 Jul 2019 07:24:12 +0000 (09:24 +0200)
This flag is tested or cleared but never set anymore.

contrib/debug/flags.c
include/types/channel.h
src/cli.c
src/stream.c

index dc4c044673340fd2737ee7383390a685bca8e7fe..0e67155a8a2b1640809052e75d0bd070cda0327f 100644 (file)
@@ -97,7 +97,6 @@ void show_chn_flags(unsigned int f)
        SHOW_FLAG(f, CF_READ_NOEXP);
        SHOW_FLAG(f, CF_SHUTR_NOW);
        SHOW_FLAG(f, CF_SHUTR);
-       SHOW_FLAG(f, CF_WAKE_CONNECT);
        SHOW_FLAG(f, CF_READ_ERROR);
        SHOW_FLAG(f, CF_READ_TIMEOUT);
        SHOW_FLAG(f, CF_READ_PARTIAL);
index 2d79c11f7542756cb0092c91afc6acaa8283a565..4bcc3b954a6bad084023c1237d2aa23b9afec622 100644 (file)
@@ -57,7 +57,7 @@
 #define CF_READ_ERROR     0x00000008  /* unrecoverable error on producer side */
 #define CF_READ_ACTIVITY  (CF_READ_NULL|CF_READ_PARTIAL|CF_READ_ERROR)
 
-#define CF_WAKE_CONNECT   0x00000010  /* wake the task up after connect succeeds */
+/* unused: 0x00000010 */
 #define CF_SHUTR          0x00000020  /* producer has already shut down */
 #define CF_SHUTR_NOW      0x00000040  /* the producer must shut down for reads ASAP */
 #define CF_READ_NOEXP     0x00000080  /* producer should not expire */
index 9a9f80f9056e1b145e493155032d4584e85de341..ce33f60a3f2d236ae7e7fb86b1b32b45e673277c 100644 (file)
--- a/src/cli.c
+++ b/src/cli.c
@@ -2324,7 +2324,7 @@ int pcli_wait_for_response(struct stream *s, struct channel *rep, int an_bit)
                s->si[1].conn_retries = 0;  /* used for logging too */
                s->si[1].exp       = TICK_ETERNITY;
                s->si[1].flags    &= SI_FL_ISBACK | SI_FL_DONT_WAKE; /* we're in the context of process_stream */
-               s->req.flags &= ~(CF_SHUTW|CF_SHUTW_NOW|CF_AUTO_CONNECT|CF_WRITE_ERROR|CF_STREAMER|CF_STREAMER_FAST|CF_NEVER_WAIT|CF_WAKE_CONNECT|CF_WROTE_DATA);
+               s->req.flags &= ~(CF_SHUTW|CF_SHUTW_NOW|CF_AUTO_CONNECT|CF_WRITE_ERROR|CF_STREAMER|CF_STREAMER_FAST|CF_NEVER_WAIT|CF_WROTE_DATA);
                s->res.flags &= ~(CF_SHUTR|CF_SHUTR_NOW|CF_READ_ATTACHED|CF_READ_ERROR|CF_READ_NOEXP|CF_STREAMER|CF_STREAMER_FAST|CF_WRITE_PARTIAL|CF_NEVER_WAIT|CF_WROTE_DATA|CF_READ_NULL);
                s->flags &= ~(SF_DIRECT|SF_ASSIGNED|SF_ADDR_SET|SF_BE_ASSIGNED|SF_FORCE_PRST|SF_IGNORE_PRST);
                s->flags &= ~(SF_CURR_SESS|SF_REDIRECTABLE|SF_SRV_REUSED);
index 396100525ffe543bbdf6cdc788a9273b68eca49c..918da5e9d683ff82fb54ac1934209464e46136c7 100644 (file)
@@ -905,15 +905,6 @@ static void sess_establish(struct stream *s)
                si->err_type = SI_ET_DATA_ERR;
        }
 
-       /* If the request channel is waiting for the connect(), we mark the read
-        * side as attached on the response channel and we wake up it once. So
-        * it will have a chance to forward data now.
-        */
-       if (req->flags & CF_WAKE_CONNECT) {
-               req->flags |= CF_WAKE_ONCE;
-               req->flags &= ~CF_WAKE_CONNECT;
-       }
-
        if (objt_server(s->target))
                health_adjust(objt_server(s->target), HANA_STATUS_L4_OK);