OSDN Git Service

drm/amd/amdgpu: Don't proceed in audio_fini if disabled (DCEv10)
authorTom St Denis <tom.stdenis@amd.com>
Thu, 3 Mar 2016 14:20:10 +0000 (09:20 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 8 Mar 2016 16:01:53 +0000 (11:01 -0500)
If audio is disabled we shouldn't proceed into the fini function.

Signed-off-by: Tom St Denis <tom.stdenis@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/dce_v10_0.c

index b8cb411..199b95f 100644 (file)
@@ -1668,6 +1668,9 @@ static void dce_v10_0_audio_fini(struct amdgpu_device *adev)
 {
        int i;
 
+       if (!amdgpu_audio)
+               return;
+
        if (!adev->mode_info.audio.enabled)
                return;