[PATCH xf86-video-amdgpu] Fix hang when entering into dpms-off mode

Liu, Aaron Aaron.Liu at amd.com
Fri Mar 1 06:37:12 UTC 2019


@Michel Dänzer,

I have reviewed your patch and verified it passed.

I couldn't merge this merge request to your master manually.
The log is below:
aaliu at lnx-aaliu:~/work/brahma/xf86-video-amdgpu-gitlab$ git push origin master
Username for 'https://gitlab.freedesktop.org': aaliu
Password for 'https://aaliu@gitlab.freedesktop.org': 
remote: HTTP Basic: Access denied
remote: You must use a personal access token with 'api' scope for Git over HTTP.
remote: You can generate one at https://gitlab.freedesktop.org/profile/personal_access_tokens
fatal: Authentication failed for 'https://gitlab.freedesktop.org/xorg/driver/xf86-video-amdgpu.git/'

BR,
Aaron Liu

> -----Original Message-----
> From: Michel Dänzer <michel at daenzer.net>
> Sent: Friday, March 01, 2019 12:36 AM
> To: Liu, Aaron <Aaron.Liu at amd.com>
> Cc: amd-gfx at lists.freedesktop.org
> Subject: Re: [PATCH xf86-video-amdgpu] Fix hang when entering into dpms-
> off mode
> 
> On 2019-02-28 1:05 p.m., Michel Dänzer wrote:
> > On 2019-02-28 3:52 a.m., Aaron Liu wrote:
> >>
> >> @@ -900,7 +900,12 @@ CARD32
> amdgpu_dri2_deferred_event(OsTimerPtr timer, CARD32 now, pointer data)
> >>  	delta_seq = delta_t * drmmode_crtc->dpms_last_fps;
> >>  	delta_seq /= 1000000;
> >>  	frame = (CARD64) drmmode_crtc->dpms_last_seq + delta_seq;
> >> -	if (event_info->drm_queue_seq)
> >> +	/*
> >> +	 * If CRTC is in DPMS off state, it can't use vblank_handler.
> >> +	 * Because drmmode_wait_vblank is not excuted in such as
> >> +	 * amdgpu_dri2_schedule_swap/amdgpu_dri2_schedule_wait_msc.
> >> +	 */
> >> +	if (event_info->drm_queue_seq && amdgpu_crtc_is_enabled(crtc))
> >>  		drmmode_crtc->drmmode->event_context.
> >>  			vblank_handler(pAMDGPUEnt->fd, frame, drm_now /
> 1000000,
> >>  				       drm_now % 1000000,
> >>
> >
> > This isn't a good solution I'm afraid, as it'll leave the struct
> > amdgpu_drm_queue_entry memory associated with
> > event_info->drm_queue_seq linked into the amdgpu_drm_queue list,
> which
> > would gradually slow down processing of that list.
> >
> >
> > I think I know what the issue is, I'll work on a fix in the afternoon.
> 
> Please test
> https://gitlab.freedesktop.org/xorg/driver/xf86-video-
> amdgpu/merge_requests/29
> .
> 
> 
> --
> Earthling Michel Dänzer               |              https://www.amd.com
> Libre software enthusiast             |             Mesa and X developer


More information about the amd-gfx mailing list