diff options
author | xiaoqiang zhao <zxq_yx_007@163.com> | 2016-06-06 16:59:32 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2016-06-06 16:59:32 +0100 |
commit | 7bd43519da16633d88e9d2faf8077768a1b36ce9 (patch) | |
tree | c77fda93c13b71cbf15ff3cdc8caf4e153acd4fe /hw/arm/stm32f205_soc.c | |
parent | 746c3b3eba0d091d2e2d84b63ce4ca3186e212a7 (diff) |
hw/char: QOM'ify stm32f2xx_usart model
* drop qemu_char_get_next_serial and use chardev prop
* change affected board code to use the new way
Signed-off-by: xiaoqiang zhao <zxq_yx_007@163.com>
Message-id: 1465028065-5855-5-git-send-email-zxq_yx_007@163.com
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/arm/stm32f205_soc.c')
-rw-r--r-- | hw/arm/stm32f205_soc.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/arm/stm32f205_soc.c b/hw/arm/stm32f205_soc.c index 9c1dafbb19..de26b8caff 100644 --- a/hw/arm/stm32f205_soc.c +++ b/hw/arm/stm32f205_soc.c @@ -107,6 +107,7 @@ static void stm32f205_soc_realize(DeviceState *dev_soc, Error **errp) /* Attach UART (uses USART registers) and USART controllers */ for (i = 0; i < STM_NUM_USARTS; i++) { usartdev = DEVICE(&(s->usart[i])); + qdev_prop_set_chr(usartdev, "chardev", i < MAX_SERIAL_PORTS ? serial_hds[i] : NULL); object_property_set_bool(OBJECT(&s->usart[i]), true, "realized", &err); if (err != NULL) { error_propagate(errp, err); |