[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] virtio-pci: replace byte swap hack
From: |
Blue Swirl |
Subject: |
Re: [Qemu-devel] [PATCH] virtio-pci: replace byte swap hack |
Date: |
Sun, 6 Jan 2013 20:04:39 +0000 |
On Sun, Jan 6, 2013 at 6:25 PM, Andreas Färber <address@hidden> wrote:
> Am 06.01.2013 14:17, schrieb Alexander Graf:
>>
>> On 30.12.2012, at 13:55, Blue Swirl wrote:
>>
>>> Remove byte swaps by declaring the config space
>>> as native endian.
>>
>> This is wrong. Virtio-pci config space is split into 2 regions. One with
>> native endianness, the other one with little endian.
>
> Can that MemoryRegion be split in two?
Yes, but unfortunately the offset for the second region depends on if
MSIX is enabled or not. PCI layer manages these bits without the
device seeing any changes.
This could be handled by introducing a callback at PCI layer to inform
interested devices about changes to MSIX setup, or even generalized:
inform devices about changes within any set of bits specified by the
device.
>
> Andreas
>
> --
> SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
> GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
Re: [Qemu-devel] [PATCH] virtio-pci: replace byte swap hack, Blue Swirl, 2013/01/06