virtio_console: enable VQs early
authorMichael S. Tsirkin <mst@redhat.com>
Tue, 14 Oct 2014 23:52:31 +0000 (10:22 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Tue, 14 Oct 2014 23:55:03 +0000 (10:25 +1030)
commitf5866db64f341776c2d9ed48080f82459fea6a55
tree08491413923d1c821db0403d17920c15d238a4df
parent7a11370e5e6c26566904bb7f08281093a3002ff2
virtio_console: enable VQs early

virtio spec requires drivers to set DRIVER_OK before using VQs.
This is set automatically after probe returns, virtio console violated this
rule by adding inbufs, which causes the VQ to be used directly within
probe.

To fix, call virtio_device_ready before using VQs.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
drivers/char/virtio_console.c