vhost: fail backend intialization early
commitaebf81680bf49c5953d7ae9ebb7b98c0f4dad8f3
authorIgor Mammedov <imammedo@redhat.com>
Tue, 6 Oct 2015 08:37:29 +0000 (6 10:37 +0200)
committerMichael S. Tsirkin <mst@redhat.com>
Thu, 22 Oct 2015 11:34:48 +0000 (22 14:34 +0300)
treedf7c202f4f0791b499a640b09eb0c9f85b619262
parent3fad87881e55aaff659408dcf25fa204f89a7896
vhost: fail backend intialization early

Don't initialize vhost backend if memslots number exceeds the supported
limit. This prevents failures down the road when backend
is actually started.

[MST: rewrite commit log]

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/virtio/vhost.c