• A
    virtio-pci: Replace modern_as with direct access to modern_bar · a93c8d82
    Alexey Kardashevskiy 提交于
    The modern bar is accessed now via yet another address space created just
    for that purpose and it does not really need FlatView and dispatch tree
    as it has a single memory region so it is just a waste of memory. Things
    get even worse when there are dozens or hundreds of virtio-pci devices -
    since these address spaces are global, changing any of them triggers
    rebuilding all address spaces.
    
    This replaces indirect accesses to the modern BAR with a simple lookup
    and direct calls to memory_region_dispatch_read/write.
    
    This is expected to save lots of memory at boot time after applying:
    [Qemu-devel] [PULL 00/32] Misc changes for 2017-09-22
    Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
    Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
    Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
    a93c8d82
virtio-pci.h 10.5 KB