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

Re: [Xen-devel] [PATCH v5 6/9] ioreq-server: add support for multiple servers



>>> On 07.05.14 at 14:37, <Paul.Durrant@xxxxxxxxxx> wrote:
>> From: Jan Beulich [mailto:JBeulich@xxxxxxxx]
>> >>> On 07.05.14 at 14:25, <Paul.Durrant@xxxxxxxxxx> wrote:
>> >> From: Jan Beulich [mailto:JBeulich@xxxxxxxx]
>> >> >>> On 07.05.14 at 14:06, <Paul.Durrant@xxxxxxxxxx> wrote:
>> >> >> From: Jan Beulich [mailto:JBeulich@xxxxxxxx]
>> >> >> >>> On 01.05.14 at 14:08, <paul.durrant@xxxxxxxxxx> wrote:
>> >> >> > +static int hvm_access_cfc(
>> >> >> > +    int dir, uint32_t port, uint32_t bytes, uint32_t *val)
>> >> >> > +{
>> >> >> > +    struct vcpu *curr = current;
>> >> >> > +    struct hvm_domain *hd = &curr->domain->arch.hvm_domain;
>> >> >> > +    int rc;
>> >> >> > +
>> >> >> > +    BUG_ON(port < 0xcfc);
>> >> >> > +    port -= 0xcfc;
>> >> >> > +
>> >> >> > +    spin_lock(&hd->pci_lock);
>> >> >> > +
>> >> >> > +    if ( hd->pci_cf8 & (1 << 31) ) {
>> >> >> > +        /* Fall through to an emulator */
>> >> >> > +        rc = X86EMUL_UNHANDLEABLE;
>> >> >> > +    } else {
>> >> >> > +        /* Config access disabled */
>> >> >>
>> >> >> Why does this not also get passed through to an emulator?
>> >> >>
>> >> >
>> >> > I was trying to be consistent with QEMU here. It squashes any data
>> >> accesses
>> >> > if cf8 has the top bit set.
>> >>
>> >> But afaict with that dropped the entire function can go away.
>> >>
>> >
>> > Yes, it can. Do you not think it would be a good idea to be consistent with
>> > QEMU though?
>> 
>> By removing the function you're going to be consistent with qemu,
>> because you're going to have qemu supply the data.
>> 
> 
> Yes, true, in select_ioreq_server() I could just pass cfc accesses to the 
> default emulator if cf8 has the top bit set.

I continue to fail to see why you make this dependent on the value
of the top bit - just have any accesses to port 0xCFC be handled by
the emulator responsible for the respective device.

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.