Skip some initialization steps for GPU screens
PATCH 1/2 Skip some initialization steps for GPU screens
From: Michel Dänzer <[email protected]>
Xorg doesn't use the following functionality of GPU screens, so don't bother initializing it:
* DRI page flipping
* DRI3 / Present / SYNC fences
* XVideo / XvMC
* Root window with background None
---
This looks bigger than it is due to re-indenting lots of lines. It boils down to a few added (!radeon_is_gpu_scr(ee)n) checks.
src/radeon.h | 2 + src/radeon_kms.c | 111 ++++++++++++++++++++++++++++++------------------------- 2 files changed, 62 insertions(+), 51 deletions(-)
src/radeon.h +2 -0
@@ -183,8 +183,10 @@ typedef enum {#if XF86_CRTC_VERSION >=5 #define RADEON_PIXMAP_SHARING 1#define radeon_is_gpu_screen (screen) (screen)->isGPU +#define radeon_is_gpu_scrn (scrn) (scrn)->is_gpu#else #define radeon_is_gpu_screen (screen) 0 +#define radeon_is_gpu_scrn (scrn) 0#endif #define RADEON_VSYNC_TIMEOUT 20000/* Maximum wait for VSYNC (in usecs) */
src/radeon_kms.c +60 -51
144 lines not on this page · raw message
Signature · 6 lines
2.11.0 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): 20170308090339.30414-1-michel-otUistvHUpPR7s880joybQ@public.gmane.org
PATCH 2/2 Pass TRUE to drmmode_set_desired_modes the first time for GPU screens
From: Michel Dänzer <[email protected]>
This is the only place we call drmmode_set_desired_modes for GPU screens during server startup. Without this change, the display outputs of secondary GPUs may stay on even while Xorg isn't using them.
---
I recently made essentially the reverse change in the amdgpu driver, but realized later that this is needed for the reason described in the commit log.
src/radeon_kms.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
src/radeon_kms.c +2 -1
@@ -328,7 +328,8 @@ static Bool RADEONCreateScreenResources_KMS(ScreenPtr pScreen) } } -if (!drmmode_set_desired_modes (pScrn, &info->drmmode, FALSE)) +if (!drmmode_set_desired_modes (pScrn, &info->drmmode, +radeon_is_gpu_screen (pScreen)))return FALSE;drmmode_uevent_init (pScrn, &info->drmmode);
Signature · 6 lines
2.11.0 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): 20170308090339.30414-2-michel-otUistvHUpPR7s880joybQ@public.gmane.org
Alex Deucher
Reviewed-byRe: [PATCH xf86-video-ati 2/2] Pass TRUE to drmmode_set_desired_modes the first time for GPU screens
Quoted 7 lines · Michel Dänzer
From: Michel Dänzer <[email protected]>
This is the only place we call
drmmode_set_desired_modesfor GPU screens during server startup. Without this change, the display outputs of secondary GPUs may stay on even while Xorg isn't using them.Signed-off-by Michel Dänzer <[email protected]>
Series is:
Quoted 26 lines
---
I recently made essentially the reverse change in the amdgpu driver, but realized later that this is needed for the reason described in the commit log.
src/radeon_kms.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)src/radeon_kms.c +2
-2@@ -328,7 +328,8 @@ static Bool RADEONCreateScreenResources_KMS(ScreenPtr pScreen) } } -if (!drmmode_set_desired_modes (pScrn, &info->drmmode, FALSE)) +if (!drmmode_set_desired_modes (pScrn, &info->drmmode, +radeon_is_gpu_screen (pScreen)))return FALSE;drmmode_uevent_init (pScrn, &info->drmmode); --2.11.0
Quoted 4 lines
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx