uint32_t flags)
 {
        int r, i;
-       bool runtime = false;
+       bool boco = false;
        u32 max_MBps;
 
        adev->shutdown = false;
        vga_client_register(adev->pdev, adev, NULL, amdgpu_device_vga_set_decode);
 
        if (amdgpu_device_supports_boco(ddev))
-               runtime = true;
-       if (!pci_is_thunderbolt_attached(adev->pdev))
+               boco = true;
+       if (amdgpu_has_atpx() &&
+           (amdgpu_is_atpx_hybrid() ||
+            amdgpu_has_atpx_dgpu_power_cntl()) &&
+           !pci_is_thunderbolt_attached(adev->pdev))
                vga_switcheroo_register_client(adev->pdev,
-                                              &amdgpu_switcheroo_ops, runtime);
-       if (runtime)
+                                              &amdgpu_switcheroo_ops, boco);
+       if (boco)
                vga_switcheroo_init_domain_pm_ops(adev->dev, &adev->vga_pm_domain);
 
        if (amdgpu_emu_mode == 1) {
 
 failed:
        amdgpu_vf_error_trans_all(adev);
-       if (runtime)
+       if (boco)
                vga_switcheroo_fini_domain_pm_ops(adev->dev);
 
        return r;
 
        kfree(adev->bios);
        adev->bios = NULL;
-       if (!pci_is_thunderbolt_attached(adev->pdev))
+       if (amdgpu_has_atpx() &&
+           (amdgpu_is_atpx_hybrid() ||
+            amdgpu_has_atpx_dgpu_power_cntl()) &&
+           !pci_is_thunderbolt_attached(adev->pdev))
                vga_switcheroo_unregister_client(adev->pdev);
-       if (adev->flags & AMD_IS_PX)
+       if (amdgpu_device_supports_boco(adev->ddev))
                vga_switcheroo_fini_domain_pm_ops(adev->dev);
        vga_client_register(adev->pdev, NULL, NULL, NULL);
        if (adev->rio_mem)