Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/evbarm/rockchip init cpufreq, remove cpu.frequency ...



details:   https://anonhg.NetBSD.org/src/rev/369aa3886030
branches:  trunk
changeset: 805460:369aa3886030
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Fri Jan 02 22:00:02 2015 +0000

description:
init cpufreq, remove cpu.frequency boot arg support

diffstat:

 sys/arch/evbarm/rockchip/rockchip_machdep.c |  14 ++++++--------
 1 files changed, 6 insertions(+), 8 deletions(-)

diffs (49 lines):

diff -r 51d8d78ee6c6 -r 369aa3886030 sys/arch/evbarm/rockchip/rockchip_machdep.c
--- a/sys/arch/evbarm/rockchip/rockchip_machdep.c       Fri Jan 02 21:59:29 2015 +0000
+++ b/sys/arch/evbarm/rockchip/rockchip_machdep.c       Fri Jan 02 22:00:02 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rockchip_machdep.c,v 1.13 2015/01/02 00:50:56 jmcneill Exp $ */
+/*     $NetBSD: rockchip_machdep.c,v 1.14 2015/01/02 22:00:02 jmcneill Exp $ */
 
 /*
  * Machine dependent functions for kernel setup for TI OSK5912 board.
@@ -125,7 +125,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rockchip_machdep.c,v 1.13 2015/01/02 00:50:56 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rockchip_machdep.c,v 1.14 2015/01/02 22:00:02 jmcneill Exp $");
 
 #include "opt_machdep.h"
 #include "opt_ddb.h"
@@ -468,7 +468,6 @@
 {
        psize_t ram_size = 0;
        char *ptr;
-       u_int cpufreq;
        *(volatile int *)CONSADDR_VA  = 0x40;   /* output '@' */
 #if 1
        rockchip_putchar('d');
@@ -600,11 +599,6 @@
                use_fb_console = true;
        }
 
-       if (get_bootconf_option(boot_args, "cpu.frequency",
-                   BOOTOPT_TYPE_INT, &cpufreq)) {
-               rockchip_apll_set_rate(cpufreq * 1000000);
-       }
-
        curcpu()->ci_data.cpu_cc_freq = rockchip_cpu_get_rate();
 
        return initarm_common(KERNEL_VM_BASE, KERNEL_VM_SIZE, NULL, 0);
@@ -736,6 +730,10 @@
                return;
        }
 
+       if (device_is_a(self, "cpu") && device_unit(self) == 0) {
+               rockchip_cpufreq_init();
+       }
+
 #ifdef CPU_CORTEXA9 
        /*
         * We need to tell the A9 Global/Watchdog Timer



Home | Main Index | Thread Index | Old Index