]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdgpu: optimize amdgpu driver load & resume time
authorShirish S <shirish.s@amd.com>
Thu, 25 May 2017 04:35:25 +0000 (10:05 +0530)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 31 May 2017 18:16:30 +0000 (14:16 -0400)
commit4358aa8e7f07359dfc098af31801cc6f4551ac25
tree622790fc39010cde773be740e6165595e041d81a
parent3bb9e28ce0777aa6cbf771ae9c609738bcb049dc
drm/amdgpu: optimize amdgpu driver load & resume time

amdgpu_device_resume() & amdgpu_device_init() have a high
time consuming call of amdgpu_late_init() which sets the
clock_gating state of all IP blocks and is blocking.
This patch defers only this setting of clock gating state
operation to post resume of amdgpu driver but ideally before
the UI comes up or in some cases post ui as well.

With this change the resume time of amdgpu_device comes down
from 1.299s to 0.199s which further helps in reducing the overall
system resume time.

V1: made the optimization applicable during driver load as well.

TEST:(For ChromiumOS on STONEY only)
* UI comes up
* amdgpu_late_init() call gets called consistently and no errors reported.

Signed-off-by: Shirish S <shirish.s@amd.com>
Reviewed-by: Huang Rui <ray.huang@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu.h
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c