From 7c41cdcd3bbee5d49de9d4821b15e49d155ff22b Mon Sep 17 00:00:00 2001 From: Viresh Kumar Date: Wed, 14 Jun 2023 15:29:32 +0530 Subject: OPP: Simplify the over-designed pstate <-> level dance While adding support for "performance states" in the OPP and genpd core, it was decided to set the `pstate` field via genpd's pm_genpd_opp_to_performance_state() helper, to allow platforms to set `pstate` even if they don't have a corresponding `level` field in the DT OPP tables (More details are present in commit 6e41766a6a50 ("PM / Domain: Implement of_genpd_opp_to_performance_state()")). Revisiting that five years later clearly suggests that it was over-designed as all current users are eventually using the `level` value only. The previous commit already added necessary checks to make sure pstate is only used for genpd tables. Lets now simplify this a little, and use `level` directly and remove `pstate` field altogether. Suggested-by: Ulf Hansson Signed-off-by: Viresh Kumar Reviewed-by: Ulf Hansson --- drivers/opp/debugfs.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'drivers/opp/debugfs.c') diff --git a/drivers/opp/debugfs.c b/drivers/opp/debugfs.c index 0cc21e2b42ff..17543c0aa5b6 100644 --- a/drivers/opp/debugfs.c +++ b/drivers/opp/debugfs.c @@ -156,9 +156,6 @@ void opp_debug_create_one(struct dev_pm_opp *opp, struct opp_table *opp_table) debugfs_create_ulong("clock_latency_ns", S_IRUGO, d, &opp->clock_latency_ns); - if (opp_table->is_genpd) - debugfs_create_u32("performance_state", S_IRUGO, d, &opp->pstate); - opp->of_name = of_node_full_name(opp->np); debugfs_create_str("of_name", S_IRUGO, d, (char **)&opp->of_name); -- cgit v1.2.3