drm/amd/pm: wrapper for postponing some setup job after DAL initializatioa(V2)
So that ASIC specific actions can be added. V2: better namings Signed-off-by: Evan Quan <evan.quan@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
b836a274b7
commit
4bdd4d25ed
@ -600,6 +600,7 @@ struct pptable_funcs {
|
||||
int (*gfx_ulv_control)(struct smu_context *smu, bool enablement);
|
||||
int (*deep_sleep_control)(struct smu_context *smu, bool enablement);
|
||||
int (*get_fan_parameters)(struct smu_context *smu);
|
||||
int (*post_init)(struct smu_context *smu);
|
||||
};
|
||||
|
||||
typedef enum {
|
||||
|
@ -473,6 +473,12 @@ static int smu_late_init(void *handle)
|
||||
if (!smu->pm_enabled)
|
||||
return 0;
|
||||
|
||||
ret = smu_post_init(smu);
|
||||
if (ret) {
|
||||
dev_err(adev->dev, "Failed to post smu init!\n");
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret = smu_set_default_od_settings(smu);
|
||||
if (ret) {
|
||||
dev_err(adev->dev, "Failed to setup default OD settings!\n");
|
||||
|
@ -95,6 +95,7 @@
|
||||
#define smu_gfx_ulv_control(smu, enablement) smu_ppt_funcs(gfx_ulv_control, 0, smu, enablement)
|
||||
#define smu_deep_sleep_control(smu, enablement) smu_ppt_funcs(deep_sleep_control, 0, smu, enablement)
|
||||
#define smu_get_fan_parameters(smu) smu_ppt_funcs(get_fan_parameters, 0, smu)
|
||||
#define smu_post_init(smu) smu_ppt_funcs(post_init, 0, smu)
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user