• A
    vfio/pci: Foundation for new quirk structure · 8c4f2348
    Alex Williamson 提交于
    VFIOQuirk hosts a single memory region and a fixed set of data fields
    that try to handle all the quirk cases, but end up making those that
    don't exactly match really confusing.  This patch introduces a struct
    intended to provide more flexibility and simpler code.  VFIOQuirk is
    stripped to its basics, an opaque data pointer for quirk specific
    data and a pointer to an array of MemoryRegions with a counter.  This
    still allows us to have common teardown routines, but adds much
    greater flexibility to support multiple memory regions and quirk
    specific data structures that are easier to maintain.  The existing
    VFIOQuirk is transformed into VFIOLegacyQuirk, which further patches
    will eliminate entirely.
    Signed-off-by: NAlex Williamson <alex.williamson@redhat.com>
    8c4f2348
pci-quirks.c 32.9 KB