diff options
Diffstat (limited to 'common/recipes-kernel/linux/files/0937-drm-amd-powerplay-add-all-blocks-clockgating-support.patch')
-rw-r--r-- | common/recipes-kernel/linux/files/0937-drm-amd-powerplay-add-all-blocks-clockgating-support.patch | 126 |
1 files changed, 0 insertions, 126 deletions
diff --git a/common/recipes-kernel/linux/files/0937-drm-amd-powerplay-add-all-blocks-clockgating-support.patch b/common/recipes-kernel/linux/files/0937-drm-amd-powerplay-add-all-blocks-clockgating-support.patch deleted file mode 100644 index 77396154..00000000 --- a/common/recipes-kernel/linux/files/0937-drm-amd-powerplay-add-all-blocks-clockgating-support.patch +++ /dev/null @@ -1,126 +0,0 @@ -From a3e67c37baba1d9fb9fa3fa3a72fd9dbe9eab346 Mon Sep 17 00:00:00 2001 -From: Eric Huang <JinHuiEric.Huang@amd.com> -Date: Tue, 9 Feb 2016 16:26:00 -0500 -Subject: [PATCH 0937/1110] drm/amd/powerplay: add all blocks clockgating - support through SMU/powerplay -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -Reviewed-by: Alex Deucher <alexander.deucher@amd.com> -Acked-by: Christian König <christian.koenig@amd.com> -Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> ---- - drivers/gpu/drm/amd/powerplay/amd_powerplay.c | 81 +++++++++++++++++++++++ - drivers/gpu/drm/amd/powerplay/inc/amd_powerplay.h | 3 + - 2 files changed, 84 insertions(+) - -diff --git a/drivers/gpu/drm/amd/powerplay/amd_powerplay.c b/drivers/gpu/drm/amd/powerplay/amd_powerplay.c -index 9d22900..9c742e0 100644 ---- a/drivers/gpu/drm/amd/powerplay/amd_powerplay.c -+++ b/drivers/gpu/drm/amd/powerplay/amd_powerplay.c -@@ -180,6 +180,87 @@ static void pp_print_status(void *handle) - static int pp_set_clockgating_state(void *handle, - enum amd_clockgating_state state) - { -+ struct pp_hwmgr *hwmgr; -+ uint32_t msg_id, pp_state; -+ -+ if (handle == NULL) -+ return -EINVAL; -+ -+ hwmgr = ((struct pp_instance *)handle)->hwmgr; -+ -+ if (hwmgr == NULL || hwmgr->hwmgr_func == NULL || -+ hwmgr->hwmgr_func->update_clock_gatings == NULL) -+ return -EINVAL; -+ -+ if (state == AMD_CG_STATE_UNGATE) -+ pp_state = 0; -+ else -+ pp_state = PP_STATE_CG | PP_STATE_LS; -+ -+ /* Enable/disable GFX blocks clock gating through SMU */ -+ msg_id = PP_CG_MSG_ID(PP_GROUP_GFX, -+ PP_BLOCK_GFX_CG, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_GFX, -+ PP_BLOCK_GFX_3D, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_GFX, -+ PP_BLOCK_GFX_RLC, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_GFX, -+ PP_BLOCK_GFX_CP, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_GFX, -+ PP_BLOCK_GFX_MG, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ -+ /* Enable/disable System blocks clock gating through SMU */ -+ msg_id = PP_CG_MSG_ID(PP_GROUP_SYS, -+ PP_BLOCK_SYS_BIF, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_SYS, -+ PP_BLOCK_SYS_BIF, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_SYS, -+ PP_BLOCK_SYS_MC, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_SYS, -+ PP_BLOCK_SYS_ROM, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_SYS, -+ PP_BLOCK_SYS_DRM, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_SYS, -+ PP_BLOCK_SYS_HDP, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ msg_id = PP_CG_MSG_ID(PP_GROUP_SYS, -+ PP_BLOCK_SYS_SDMA, -+ PP_STATE_SUPPORT_CG | PP_STATE_SUPPORT_LS, -+ pp_state); -+ hwmgr->hwmgr_func->update_clock_gatings(hwmgr, &msg_id); -+ - return 0; - } - -diff --git a/drivers/gpu/drm/amd/powerplay/inc/amd_powerplay.h b/drivers/gpu/drm/amd/powerplay/inc/amd_powerplay.h -index bbe02ec..e5356cf 100644 ---- a/drivers/gpu/drm/amd/powerplay/inc/amd_powerplay.h -+++ b/drivers/gpu/drm/amd/powerplay/inc/amd_powerplay.h -@@ -288,6 +288,9 @@ struct pp_states_info { - - #define PP_BLOCK_GFX_CG 0x01 - #define PP_BLOCK_GFX_MG 0x02 -+#define PP_BLOCK_GFX_3D 0x04 -+#define PP_BLOCK_GFX_RLC 0x08 -+#define PP_BLOCK_GFX_CP 0x10 - #define PP_BLOCK_SYS_BIF 0x01 - #define PP_BLOCK_SYS_MC 0x02 - #define PP_BLOCK_SYS_ROM 0x04 --- -2.7.4 - |