drm/amdgpu:vega10: enable virtual display if set via module option
authorAlex Deucher <alexander.deucher@amd.com>
Wed, 22 Mar 2017 14:49:25 +0000 (10:49 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 30 Mar 2017 03:55:07 +0000 (23:55 -0400)
Enable virtual displays if the user has enabled them via the
kernel command line.  Useful in virtual or headless environments.

Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/soc15.c

index bc827737e0f41044cb633c9eafb806c7d9fbbda9..76adb1d69473d843f429115f0440f01e88d52e29 100644 (file)
@@ -486,7 +486,7 @@ int soc15_set_ip_blocks(struct amdgpu_device *adev)
                if (!amdgpu_sriov_vf(adev))
                        amdgpu_ip_block_add(adev, &psp_v3_1_ip_block);
                amdgpu_ip_block_add(adev, &amdgpu_pp_ip_block);
-               if (amdgpu_sriov_vf(adev))
+               if (adev->enable_virtual_display || amdgpu_sriov_vf(adev))
                        amdgpu_ip_block_add(adev, &dce_virtual_ip_block);
                amdgpu_ip_block_add(adev, &gfx_v9_0_ip_block);
                amdgpu_ip_block_add(adev, &sdma_v4_0_ip_block);