qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 3/8] virtio-serial-bus: Maintain guest and host


From: Amit Shah
Subject: Re: [Qemu-devel] [PATCH 3/8] virtio-serial-bus: Maintain guest and host port open/close state
Date: Thu, 24 Dec 2009 10:57:39 +0530
User-agent: Mutt/1.5.19 (2009-01-05)

On (Wed) Dec 23 2009 [17:14:28], Anthony Liguori wrote:
>
>> +    /*
>> +     * Items in struct VirtIOSerialPort.
>> +     */
>> +    QTAILQ_FOREACH(port,&s->ports, next) {
>> +        /*
>> +         * We put the port number because we may not have an active
>> +         * port at id 0 that's reserved for a console port, or in case
>> +         * of ports that might have gotten unplugged
>> +         */
>> +        qemu_put_be32s(f,&port->id);
>> +        qemu_put_byte(f, port->guest_connected);
>> +
>> +    }
>>   }
>
>
> I imagine this sort of thing is going to give Juan quite a head-ache  
> when it comes time to VMState conversion.

Juan has gone through this and he thinks it's fine; conversion to
vmstate shouldn't be a problem. Unless things have changed since then..

> Are there not separate qdev devices for each port?  Can't the state be  
> stored in that?

All the state here is common to all the ports so it makes sense to do it
here, in one place.

For any extra state the ports might have, they can do their own
save/restore.

                Amit




reply via email to

[Prev in Thread] Current Thread [Next in Thread]