dvfs: tegra21: Rename thermal safe maximum frequency
Alex Frid [Sat, 18 Oct 2014 02:17:34 +0000 (19:17 -0700)]
Renamed field and function operated on thermal safe maximum frequency
to make it clear that it is fmax at Vmin (not global fmax).

Change-Id: Ie2b5234e87dc5dc03ccdaeb2916f0b776e56b640
Signed-off-by: Alex Frid <afrid@nvidia.com>
Reviewed-on: http://git-master/r/559058
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>

drivers/gpu/nvgpu/gm20b/clk_gm20b.c
drivers/platform/tegra/dvfs.c
drivers/platform/tegra/tegra21_dvfs.c
include/linux/clk/tegra.h
include/linux/platform/tegra/dvfs.h

index 568d4dd..7229e16 100644 (file)
@@ -1105,7 +1105,7 @@ static int gm20b_init_clk_setup_sw(struct gk20a *g)
        clk->gpc_pll.id = GK20A_GPC_PLL;
        clk->gpc_pll.clk_in = clk_get_rate(ref) / KHZ;
 
-       safe_rate = tegra_dvfs_get_therm_safe_fmax(
+       safe_rate = tegra_dvfs_get_fmax_at_vmin_safe_t(
                clk_get_parent(clk->tegra_clk));
        safe_rate = safe_rate * (100 - DVFS_SAFE_MARGIN) / 100;
        dvfs_safe_max_freq = rate_gpu_to_gpc2clk(safe_rate);
index 83fcc40..6077874 100644 (file)
@@ -82,14 +82,14 @@ int tegra_dvfs_get_core_boot_level(void)
 }
 EXPORT_SYMBOL(tegra_dvfs_get_core_boot_level);
 
-unsigned long tegra_dvfs_get_therm_safe_fmax(struct clk *c)
+unsigned long tegra_dvfs_get_fmax_at_vmin_safe_t(struct clk *c)
 {
        if (!c->dvfs)
                return 0;
 
-       return c->dvfs->therm_safe_fmax;
+       return c->dvfs->fmax_at_vmin_safe_t;
 }
-EXPORT_SYMBOL(tegra_dvfs_get_therm_safe_fmax);
+EXPORT_SYMBOL(tegra_dvfs_get_fmax_at_vmin_safe_t);
 
 void tegra_dvfs_add_relationships(struct dvfs_relationship *rels, int n)
 {
index da05331..cfed03d 100644 (file)
@@ -968,7 +968,7 @@ static int __init set_gpu_dvfs_data(unsigned long max_freq,
 
        *max_freq_index = i - 1;
 
-       gpu_dvfs->therm_safe_fmax = d->freqs_mult *
+       gpu_dvfs->fmax_at_vmin_safe_t = d->freqs_mult *
                find_gpu_fmax_at_vmin(gpu_dvfs, thermal_ranges, i);
        return 0;
 }
index 4cee176..6cb642e 100644 (file)
@@ -170,7 +170,7 @@ int tegra_dvfs_get_core_override_floor(void);
 int tegra_dvfs_get_core_nominal_millivolts(void);
 int tegra_dvfs_get_core_boot_level(void);
 /* Get max rate safe at min voltage in all t-ranges; return zero if unknown */
-unsigned long tegra_dvfs_get_therm_safe_fmax(struct clk *c);
+unsigned long tegra_dvfs_get_fmax_at_vmin_safe_t(struct clk *c);
 
 unsigned long clk_get_rate_all_locked(struct clk *c);
 int tegra_dvfs_rail_disable_by_name(const char *reg_id);
index 5f880dc..2007265 100644 (file)
@@ -199,7 +199,7 @@ struct dvfs {
        /* Inidcates thermal DVFS on/off */
        bool therm_dvfs;
        /* Maximum rate safe at minimum voltage across all thermal ranges */
-       unsigned long therm_safe_fmax;
+       unsigned long fmax_at_vmin_safe_t;
 
        int cur_millivolts;
        unsigned long cur_rate;