Commit 39ab61c6 authored by Marc-André Lureau's avatar Marc-André Lureau Committed by Paolo Bonzini
Browse files

char: remove explicit_fe_open, use a set_handlers argument



No need to keep explicit_fe_open around if it affects only a
qemu_chr_fe_set_handlers(). Use an additional argument instead.

Signed-off-by: default avatarMarc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20161022095318.17775-24-marcandre.lureau@redhat.com>
Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
parent 72ac8762
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -106,7 +106,7 @@ static void rng_egd_opened(RngBackend *b, Error **errp)

    /* FIXME we should resubmit pending requests when the CDS reconnects. */
    qemu_chr_fe_set_handlers(&s->chr, rng_egd_chr_can_read,
                             rng_egd_chr_read, NULL, s, NULL);
                             rng_egd_chr_read, NULL, s, NULL, true);
}

static void rng_egd_set_chardev(Object *obj, const char *value, Error **errp)
+1 −1
Original line number Diff line number Diff line
@@ -1779,7 +1779,7 @@ int gdbserver_start(const char *device)
    if (chr) {
        qemu_chr_fe_init(&s->chr, chr, &error_abort);
        qemu_chr_fe_set_handlers(&s->chr, gdb_chr_can_receive, gdb_chr_receive,
                                 gdb_chr_event, NULL, NULL);
                                 gdb_chr_event, NULL, NULL, true);
    }
    s->state = chr ? RS_IDLE : RS_INACTIVE;
    s->mon_chr = mon_chr;
+1 −1
Original line number Diff line number Diff line
@@ -1976,7 +1976,7 @@ static void pxa2xx_fir_realize(DeviceState *dev, Error **errp)
    PXA2xxFIrState *s = PXA2XX_FIR(dev);

    qemu_chr_fe_set_handlers(&s->chr, pxa2xx_fir_is_empty,
                             pxa2xx_fir_rx, pxa2xx_fir_event, s, NULL);
                             pxa2xx_fir_rx, pxa2xx_fir_event, s, NULL, true);
}

static bool pxa2xx_fir_vmstate_validate(void *opaque, int version_id)
+1 −1
Original line number Diff line number Diff line
@@ -1241,7 +1241,7 @@ static void strongarm_uart_init(Object *obj)
                             strongarm_uart_can_receive,
                             strongarm_uart_receive,
                             strongarm_uart_event,
                             s, NULL);
                             s, NULL, true);
}

static void strongarm_uart_reset(DeviceState *dev)
+1 −1
Original line number Diff line number Diff line
@@ -279,7 +279,7 @@ static void bcm2835_aux_realize(DeviceState *dev, Error **errp)
    BCM2835AuxState *s = BCM2835_AUX(dev);

    qemu_chr_fe_set_handlers(&s->chr, bcm2835_aux_can_receive,
                             bcm2835_aux_receive, NULL, s, NULL);
                             bcm2835_aux_receive, NULL, s, NULL, true);
}

static Property bcm2835_aux_props[] = {
Loading