/* Change Logs: Date Author Notes  GuEe-GUI the first version  */
static int console_init()
/* Change Logs: Date Author Notes  GuEe-GUI the first version  */
static int console_init()
{
    rt_err_t status = RT_EOK;
    rt_device_t device = rt_device_find("virtio-console0");
    if (device != RT_NULL && rt_device_open(device, 0) == RT_EOK)
    {
        status = rt_device_control(device, VIRTIO_DEVICE_CTRL_CONSOLE_PORT_CREATE, RT_NULL);
    }
    if (device != RT_NULL)
    {
        rt_device_close(device);
    }
    return status;
}