fn create_devices(
    cfg: &Config,
    vm: &mut impl VmArch,
    resources: &mut SystemAllocator,
    add_control_tube: &mut impl FnMut(AnyControlTube),
    vm_evt_wrtube: &SendTube,
    iommu_attached_endpoints: &mut BTreeMap<u32, Arc<Mutex<Box<dyn MemoryMapperTrait>>>>,
    usb_provider: DeviceProvider,
    render_server_fd: Option<SafeDescriptor>,
    iova_max_addr: &mut Option<u64>,
    registered_evt_q: &SendTube,
    vfio_container_manager: &mut VfioContainerManager,
    worker_process_pids: &mut BTreeSet<Pid>
) -> Result<Vec<(Box<dyn BusDeviceObj>, Option<Minijail>)>>