Received: from eggs.gnu.org ([2001:4830:134:3::10]:47198) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1byfcJ-0004iC-Mq for qemu-devel@nongnu.org; Mon, 24 Oct 2016 09:48:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1byfcI-0006iY-LO for qemu-devel@nongnu.org; Mon, 24 Oct 2016 09:48:43 -0400 Received: from mail-wm0-x243.google.com ([2a00:1450:400c:c09::243]:36084) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1byfcI-0006hg-Fk for qemu-devel@nongnu.org; Mon, 24 Oct 2016 09:48:42 -0400 Received: by mail-wm0-x243.google.com with SMTP id f193so9919893wmg.3 for ; Mon, 24 Oct 2016 06:48:42 -0700 (PDT) Sender: Paolo Bonzini From: Paolo Bonzini Date: Mon, 24 Oct 2016 15:47:31 +0200 Message-Id: <1477316855-42218-47-git-send-email-pbonzini@redhat.com> In-Reply-To: <1477316855-42218-1-git-send-email-pbonzini@redhat.com> References: <1477316855-42218-1-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [Qemu-devel] [PULL 46/50] char: remove unused qemu_chr_fe_event List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= From: Marc-André Lureau I introduced this function in d61b0c9a2f7f, but it isn't used. Furthermore, it was incomplete, as it would need to translate QEMU chr events to Spice port events. (presumably it was used in the follow-up NBD-spice series that was not completed: http://lists.gnu.org/archive/html/qemu-devel/2013-11/msg02024.html) Signed-off-by: Marc-André Lureau Message-Id: <20161022100951.19562-4-marcandre.lureau@redhat.com> Signed-off-by: Paolo Bonzini --- include/sysemu/char.h | 11 ----------- qemu-char.c | 9 --------- spice-qemu-char.c | 10 ---------- 3 files changed, 30 deletions(-) diff --git a/include/sysemu/char.h b/include/sysemu/char.h index de0d99b..6bad856 100644 --- a/include/sysemu/char.h +++ b/include/sysemu/char.h @@ -103,7 +103,6 @@ struct CharDriverState { void (*chr_accept_input)(struct CharDriverState *chr); void (*chr_set_echo)(struct CharDriverState *chr, bool echo); void (*chr_set_fe_open)(struct CharDriverState *chr, int fe_open); - void (*chr_fe_event)(struct CharDriverState *chr, int event); CharBackend *be; void *opaque; char *label; @@ -239,16 +238,6 @@ void qemu_chr_fe_set_echo(CharBackend *be, bool echo); void qemu_chr_fe_set_open(CharBackend *be, int fe_open); /** - * @qemu_chr_fe_event: - * - * Send an event from the front end to the back end. It does nothing - * without associated CharDriver. - * - * @event the event to send - */ -void qemu_chr_fe_event(CharBackend *be, int event); - -/** * @qemu_chr_fe_printf: * * Write to a character backend using a printf style interface. This diff --git a/qemu-char.c b/qemu-char.c index 3b98acf..9bd2e65 100644 --- a/qemu-char.c +++ b/qemu-char.c @@ -4226,15 +4226,6 @@ void qemu_chr_fe_set_open(CharBackend *be, int fe_open) } } -void qemu_chr_fe_event(CharBackend *be, int event) -{ - CharDriverState *chr = be->chr; - - if (chr && chr->chr_fe_event) { - chr->chr_fe_event(chr, event); - } -} - guint qemu_chr_fe_add_watch(CharBackend *be, GIOCondition cond, GIOFunc func, void *user_data) { diff --git a/spice-qemu-char.c b/spice-qemu-char.c index 930b8c5..89fae6d 100644 --- a/spice-qemu-char.c +++ b/spice-qemu-char.c @@ -236,15 +236,6 @@ static void spice_port_set_fe_open(struct CharDriverState *chr, int fe_open) #endif } -static void spice_chr_fe_event(struct CharDriverState *chr, int event) -{ -#if SPICE_SERVER_VERSION >= 0x000c02 - SpiceCharDriver *s = chr->opaque; - - spice_server_port_event(&s->sin, event); -#endif -} - static void print_allowed_subtypes(void) { const char** psubtype; @@ -292,7 +283,6 @@ static CharDriverState *chr_open(const char *subtype, chr->chr_free = spice_chr_free; chr->chr_set_fe_open = set_fe_open; chr->explicit_be_open = true; - chr->chr_fe_event = spice_chr_fe_event; chr->chr_accept_input = spice_chr_accept_input; QLIST_INSERT_HEAD(&spice_chars, s, next); -- 1.8.3.1