aboutsummaryrefslogtreecommitdiff
path: root/hw/char/etraxfs_ser.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/char/etraxfs_ser.c')
-rw-r--r--hw/char/etraxfs_ser.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/hw/char/etraxfs_ser.c b/hw/char/etraxfs_ser.c
index 99c4801ba6..d812954345 100644
--- a/hw/char/etraxfs_ser.c
+++ b/hw/char/etraxfs_ser.c
@@ -128,7 +128,7 @@ ser_write(void *opaque, hwaddr addr,
case RW_DOUT:
/* XXX this blocks entire thread. Rewrite to use
* qemu_chr_fe_write and background I/O callbacks */
- qemu_chr_fe_write_all(s->chr.chr, &ch, 1);
+ qemu_chr_fe_write_all(&s->chr, &ch, 1);
s->regs[R_INTR] |= 3;
s->pending_tx = 1;
s->regs[addr] = value;
@@ -232,9 +232,9 @@ static void etraxfs_ser_realize(DeviceState *dev, Error **errp)
ETRAXSerial *s = ETRAX_SERIAL(dev);
if (s->chr.chr) {
- qemu_chr_add_handlers(s->chr.chr,
- serial_can_receive, serial_receive,
- serial_event, s);
+ qemu_chr_fe_set_handlers(&s->chr,
+ serial_can_receive, serial_receive,
+ serial_event, s, NULL);
}
}