io: tls: Add qio_channel_tls_bye
authorFabiano Rosas <farosas@suse.de>
Wed, 5 Feb 2025 16:15:00 +0000 (13:15 -0300)
committerFabiano Rosas <farosas@suse.de>
Fri, 14 Feb 2025 18:19:03 +0000 (15:19 -0300)
commit30ee88622edfa962154222b4a674361488ed823b
tree3f2e72a45ffb16a842797ab78244c1445d3ec663
parentab1cb3683bd0462695a75aa9a8c1d07731caf304
io: tls: Add qio_channel_tls_bye

Add a task dispatcher for gnutls_bye similar to the
qio_channel_tls_handshake_task(). The gnutls_bye() call might be
interrupted and so it needs to be rescheduled.

The migration code will make use of this to help the migration
destination identify a premature EOF. Once the session termination is
in place, any EOF that happens before the source issued gnutls_bye()
will be considered an error.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Acked-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
include/io/channel-tls.h
io/channel-tls.c
io/trace-events