qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] virtio: set virtio-net/virtio-mmio host feature


From: Mario Smarduch
Subject: Re: [Qemu-devel] [PATCH] virtio: set virtio-net/virtio-mmio host features
Date: Thu, 20 Feb 2014 15:17:05 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130804 Thunderbird/17.0.8

On 02/20/2014 02:47 PM, Peter Maydell wrote:
> On 20 February 2014 22:36, Mario Smarduch <address@hidden> wrote:
>> On 02/20/2014 02:10 PM, Peter Maydell wrote:
>>> On 20 February 2014 21:59, Mario Smarduch <address@hidden> wrote:
>>>> On 02/20/2014 11:35 AM, Peter Maydell wrote:
>>>>> On 20 February 2014 19:09, Mario Smarduch <address@hidden> wrote:
>>>>>> host features since you don't know what virtio device will be plugged
>>>>>> in later.
>>>>>
>>>>> I think this function is the right place to set these properties,
>>>>> yes. What I'm saying is that I don't see why you're doing it
>>>>> this way rather than using the existing per-backend hook.
>>>>> Maybe there's a reason not to use that hook, but you don't say.
>>>>>
>>>>
>>>> Appears virtio-net beckend hooks are common to several transports,
>>>> and would require virtio-mmio exception to set the host_features.
>>>> If I'm missing something please recommend.
>>>
>>> Yes, they're supposed to be common across transports, because
>>> the backend isn't supposed to care about which transport in
>>> particular. If there's a condition where the backend needs to
>>> do something which only happens for one transport, maybe we
>>> need a new hook.
>>
>> So something like set_transport_features(...) in VirtiIODeviceClass,
>> and call it from the realize hook where you can access
>> the virtio-mmio transport class instance.
> 
> Not sure. You should probably also look at whether connecting
> a virtio-pci transport to a virtio-net backend gets these feature
> bits wrong (that's different from instantiating a single virtio-net-pci
> device). I suspect they both get this wrong and this isn't particularly
> virtio-mmio specific.
> 
> thanks
> -- PMM
> 

It appears separate pci transport/virtio-net backend have the same issue.
I'll look at this closer for a more generic solution.

Thanks,
  Mario




reply via email to

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