Skip to content

Commit b87dea3

Browse files
digetxchanwoochoi
authored andcommitted
PM / devfreq: tegra30: Constify structs
Constify unmodifiable structs, for consistency. Reviewed-by: Chanwoo Choi <[email protected]> Tested-by: Peter Geis <[email protected]> Signed-off-by: Dmitry Osipenko <[email protected]> Signed-off-by: Chanwoo Choi <[email protected]>
1 parent 61d9320 commit b87dea3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/devfreq/tegra30-devfreq.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ enum tegra_actmon_device {
108108
MCCPU,
109109
};
110110

111-
static struct tegra_devfreq_device_config actmon_device_configs[] = {
111+
static const struct tegra_devfreq_device_config actmon_device_configs[] = {
112112
{
113113
/* MCALL: All memory accesses (including from the CPUs) */
114114
.offset = 0x1c0,
@@ -177,7 +177,7 @@ struct tegra_actmon_emc_ratio {
177177
unsigned long emc_freq;
178178
};
179179

180-
static struct tegra_actmon_emc_ratio actmon_emc_ratios[] = {
180+
static const struct tegra_actmon_emc_ratio actmon_emc_ratios[] = {
181181
{ 1400000, KHZ_MAX },
182182
{ 1200000, 750000 },
183183
{ 1100000, 600000 },
@@ -295,7 +295,7 @@ static unsigned long actmon_cpu_to_emc_rate(struct tegra_devfreq *tegra,
295295
unsigned long cpu_freq)
296296
{
297297
unsigned int i;
298-
struct tegra_actmon_emc_ratio *ratio = actmon_emc_ratios;
298+
const struct tegra_actmon_emc_ratio *ratio = actmon_emc_ratios;
299299

300300
for (i = 0; i < ARRAY_SIZE(actmon_emc_ratios); i++, ratio++) {
301301
if (cpu_freq >= ratio->cpu_freq) {

0 commit comments

Comments
 (0)