ODROID-HC4: cpufreq: add to use kernel parameter to set max cpufreq
authorDongjin Kim <tobetter@gmail.com>
Wed, 7 Oct 2020 03:10:32 +0000 (12:10 +0900)
committerDongjin Kim <tobetter@gmail.com>
Wed, 7 Oct 2020 03:11:08 +0000 (12:11 +0900)
Signed-off-by: Dongjin Kim <tobetter@gmail.com>
Change-Id: I5ce9b4b69e4f436f183292764149950d74131900

drivers/amlogic/cpufreq/meson-cpufreq.c

index 0a42197..4fa91da 100644 (file)
@@ -599,7 +599,8 @@ static int meson_cpufreq_init(struct cpufreq_policy *policy)
        }
 
 #ifdef CONFIG_ARCH_MESON64_ODROID_COMMON
-       if (board_is_odroidn2() || board_is_odroidc4()) {
+       if (board_is_odroidn2() || board_is_odroidc4()
+                       || board_is_odroidhc4()) {
                int i = 0;
 
                max_freq[cur_cluster] = min(max_freq[cur_cluster],
@@ -725,7 +726,7 @@ __setup("max_freq_a53=", get_max_freq_a53);
 
 static int __init get_max_freq_a55(char *str)
 {
-       if (board_is_odroidc4())
+       if (board_is_odroidc4() || board_is_odroidhc4())
                return get_max_freq_cortex(0, str);
        return -EINVAL;
 }
@@ -842,7 +843,7 @@ static int meson_cpufreq_probe(struct platform_device *pdev)
                        max_freq[1] = (is_meson_g12b_cpu() && is_meson_rev_a())
                                ? N2_A73_DEFAULT : N2PLUS_A73_DEFAULT;
                }
-       } else if (board_is_odroidc4()) {
+       } else if (board_is_odroidc4() || board_is_odroidhc4()) {
                if (!max_freq[0])
                        max_freq[0] = C4_A55_DEFAULT;
        }