Skip to content

Commit e921a5f

Browse files
Lijo Lazaralexdeucher
authored andcommitted
drm/amd/pm: Deprecate print_clk_levels callback
Use emit_clk_levels instead. Also, remove the unused helper function for getting sysfs buffer offset. Signed-off-by: Lijo Lazar <lijo.lazar@amd.com> Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
1 parent 22d6d1b commit e921a5f

2 files changed

Lines changed: 0 additions & 22 deletions

File tree

drivers/gpu/drm/amd/pm/swsmu/inc/amdgpu_smu.h

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -829,15 +829,6 @@ struct pptable_funcs {
829829
*/
830830
int (*populate_umd_state_clk)(struct smu_context *smu);
831831

832-
/**
833-
* @print_clk_levels: Print DPM clock levels for a clock domain
834-
* to buffer. Star current level.
835-
*
836-
* Used for sysfs interfaces.
837-
* Return: Number of characters written to the buffer
838-
*/
839-
int (*print_clk_levels)(struct smu_context *smu, enum smu_clk_type clk_type, char *buf);
840-
841832
/**
842833
* @emit_clk_levels: Print DPM clock levels for a clock domain
843834
* to buffer using sysfs_emit_at. Star current level.

drivers/gpu/drm/amd/pm/swsmu/smu_cmn.h

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -187,19 +187,6 @@ int smu_cmn_get_combo_pptable(struct smu_context *smu);
187187
int smu_cmn_set_mp1_state(struct smu_context *smu,
188188
enum pp_mp1_state mp1_state);
189189

190-
/*
191-
* Helper function to make sysfs_emit_at() happy. Align buf to
192-
* the current page boundary and record the offset.
193-
*/
194-
static inline void smu_cmn_get_sysfs_buf(char **buf, int *offset)
195-
{
196-
if (!*buf || !offset)
197-
return;
198-
199-
*offset = offset_in_page(*buf);
200-
*buf -= *offset;
201-
}
202-
203190
bool smu_cmn_is_audio_func_enabled(struct amdgpu_device *adev);
204191
void smu_cmn_generic_soc_policy_desc(struct smu_dpm_policy *policy);
205192
void smu_cmn_generic_plpd_policy_desc(struct smu_dpm_policy *policy);

0 commit comments

Comments
 (0)