Revision ee4d45be

b/hw/virtio-serial-bus.c
335 335

  
336 336
static uint32_t get_features(VirtIODevice *vdev, uint32_t features)
337 337
{
338
    features |= (1 << VIRTIO_CONSOLE_F_MULTIPORT);
339

  
338
    VirtIOSerial *vser = DO_UPCAST(VirtIOSerial, vdev, vdev);
339
    if (vser->bus->max_nr_ports > 1) {
340
        features |= (1 << VIRTIO_CONSOLE_F_MULTIPORT);
341
    }
340 342
    return features;
341 343
}
342 344

  

Also available in: Unified diff