Skip to content
  • Michael S. Tsirkin's avatar
    pci: fix migration path for devices behind bridges · a6a7005d
    Michael S. Tsirkin authored
    
    
    The device path used for migration is currently broken for
    for all devices behind a nested bridge.
    
    Replace this by a hierarchical list of slot/function numbers, walking
    the path from root down to device. Add :00 after the domain number
    so that if there are no nested bridges, this is compatible
    with what we have now.
    
    Note: as pointed out by Gleb, using openfirmware paths
    might be cleaner, doing this would break compatibility though,
    and the IDs used are not guest or user visible at all,
    so breaking the compatibility is probably not worth it.
    
    Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
    a6a7005d