mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-11-27 01:11:31 +00:00
drm/amd/powerplay: add interface to notify memory pool location (v2)
This patch adds interface to notify memory pool location for smu. It's to use msg SetSystemVirtualDramAddr and DramLogSetDramAddr can notify pool location. v2: add detailed info to describe this function Signed-off-by: Huang Rui <ray.huang@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
e65d45f2c7
commit
c56de9e828
2 changed files with 11 additions and 0 deletions
|
|
@ -262,6 +262,14 @@ static int smu_hw_init(void *handle)
|
|||
if (ret)
|
||||
goto failed;
|
||||
|
||||
/*
|
||||
* Use msg SetSystemVirtualDramAddr and DramLogSetDramAddr can notify
|
||||
* pool location.
|
||||
*/
|
||||
ret = smu_notify_memory_pool_location(smu);
|
||||
if (ret)
|
||||
goto failed;
|
||||
|
||||
mutex_unlock(&smu->mutex);
|
||||
|
||||
pr_info("SMU is initialized successfully!\n");
|
||||
|
|
|
|||
|
|
@ -48,6 +48,7 @@ struct smu_funcs
|
|||
int (*write_pptable)(struct smu_context *smu);
|
||||
int (*set_min_dcef_deep_sleep)(struct smu_context *smu);
|
||||
int (*set_tool_table_location)(struct smu_context *smu);
|
||||
int (*notify_memory_pool_location)(struct smu_context *smu);
|
||||
};
|
||||
|
||||
#define smu_init_microcode(smu) \
|
||||
|
|
@ -78,6 +79,8 @@ struct smu_funcs
|
|||
((smu)->funcs->set_min_dcef_deep_sleep ? (smu)->funcs->set_min_dcef_deep_sleep((smu)) : 0)
|
||||
#define smu_set_tool_table_location(smu) \
|
||||
((smu)->funcs->set_tool_table_location ? (smu)->funcs->set_tool_table_location((smu)) : 0)
|
||||
#define smu_notify_memory_pool_location(smu) \
|
||||
((smu)->funcs->notify_memory_pool_location ? (smu)->funcs->notify_memory_pool_location((smu)) : 0)
|
||||
|
||||
|
||||
extern const struct amd_ip_funcs smu_ip_funcs;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue