[PATCH] drm/amd/amdgpu: S3 resume fail

Michel Dänzer michel at daenzer.net
Wed Aug 10 03:28:39 UTC 2016


On 10/08/16 12:24 PM, Michel Dänzer wrote:
> On 10/08/16 12:04 PM, jimqu wrote:
>> Doing S3 stress test, sometimes, driver can not get console lock. So use
>> console_trylock() to instead it.
> 
> This raises some questions:
> 
> 
>> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
>> index 087e520..bd5387d 100644
>> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
>> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
>> @@ -1889,9 +1889,6 @@ int amdgpu_resume_kms(struct drm_device *dev, bool resume, bool fbcon)
>>  	if (dev->switch_power_state == DRM_SWITCH_POWER_OFF)
>>  		return 0;
>>  
>> -	if (fbcon) {
>> -		console_lock();
>> -	}
> 
> What else is holding console_lock at this time?

Maybe something calls console_lock but not console_unlock? E.g. I see
some error cases in amdgpu_resume_kms were this could happen.


-- 
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer


More information about the amd-gfx mailing list