From c6f10a5876a81f7a016714df06730c48210ee419 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Wed, 4 Feb 2015 18:33:06 +0100 Subject: serial: serial_hds_isa_init() shouldn't fail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It shouldn't fail, and no caller checks for failure. Make failure fatal. Maintainers of affected machines cc'ed. Cc: Richard Henderson Cc: Anthony Liguori Cc: "Michael S. Tsirkin" Cc: Aurelien Jarno Cc: Leon Alrae Cc: Blue Swirl Signed-off-by: Markus Armbruster Signed-off-by: Andreas Färber --- hw/char/serial-isa.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'hw') diff --git a/hw/char/serial-isa.c b/hw/char/serial-isa.c index 059ceb8b5f..f3db024d06 100644 --- a/hw/char/serial-isa.c +++ b/hw/char/serial-isa.c @@ -119,22 +119,16 @@ static void serial_register_types(void) type_init(serial_register_types) -static bool serial_isa_init(ISABus *bus, int index, CharDriverState *chr) +static void serial_isa_init(ISABus *bus, int index, CharDriverState *chr) { DeviceState *dev; ISADevice *isadev; - isadev = isa_try_create(bus, TYPE_ISA_SERIAL); - if (!isadev) { - return false; - } + isadev = isa_create(bus, TYPE_ISA_SERIAL); dev = DEVICE(isadev); qdev_prop_set_uint32(dev, "index", index); qdev_prop_set_chr(dev, "chardev", chr); - if (qdev_init(dev) < 0) { - return false; - } - return true; + qdev_init_nofail(dev); } void serial_hds_isa_init(ISABus *bus, int n) -- cgit v1.2.3