Hi Yehuda, On 06/15/2015 06:52 PM, Yehuda Yitschak wrote: > > ________________________________________ > From: Eric Auger <eric.au...@linaro.org> > Sent: Monday, June 15, 2015 4:42 PM > To: Yehuda Yitschak; qemu-devel@nongnu.org > Cc: Yuval Caduri; Shadi Ammouri > Subject: Re: Assigning an eth port to a guest VM > > Hi Yehuda, > On 06/15/2015 01:01 PM, Yehuda Yitschak wrote: >>> Cc: Eric Auger >>> >>>> -----Original Message----- >>>> From: Yehuda Yitschak >>>> Sent: Monday, June 15, 2015 9:35 >>>> To: qemu-devel@nongnu.org >>>> Cc: Yuval Caduri; Shadi Ammouri >>>> Subject: Assigning an eth port to a guest VM >>>> >>>> Hello >>>> >>>> I would to ask your advice on how to assign a semi-virtualized Ethernet >>>> port >>>> to a guest VM >>>> >>>> The eth port's HW partially supports virtualization since the data path >>>> MMIO >>>> registers (which controls rx/tx operation) are duplicated per VM. >>>> So for the run-time operation the guest can directly access the MMIO >>>> registers, using VFIO-PLATFORM, and enjoy the performance benefit. >>>> >>>> However for the initial setup and occasional configuration the guest need >>>> to >>>> access control path registers which are shared for all guests. >>>> AFAIK this is usually done with HW emulation using trap & emulate with >>>> QEMU. >>>> So, to the best of my knowledge I need a mix of VFIO and HW emulation to >>>> get the port to work with device assignment , right ? >> Yes to me you're correct. >>>> >>>> Are there any standard methods for achieving this ? >>>> Is there an example for such an existing HW in QEMU ? >> Not yet unfortunately. To my knowledge the only platform devices that >> were assigned with QEMU VFIO platform were standalone duplicated >> devices, PL330, Calxeda Xgmac, SATA. So you are a trailblazer on that >> track. > > Thanks. It's good to know the diagnosis :-) > > BTW - i thought SR-IOV uses a somewhat similar concept. AFAIK each virtual > function (VF) gets > a set of registers enabling it to perform data path but most of the > configuration and management > operations are controlled by the host using the Physical Function PF driver. > Are you familiar with that ? I have the same understanding about PCI SR-IOV but unfortunately I am not sufficiently familiar with it to give you any advice.
> i know SR-IOV is not related to VFIO-PLATFORM but if the mixed of direct > access and emulation > exists there as well then maybe i can borrow some concepts I hope so. I am also interested in the topic! Best Regards Eric > > Best regards > > Yehuda > >> Best Regards >> >> Eric >>>> >>>> Thanks >>>> >>>> Yehuda Yitschak