summaryrefslogtreecommitdiff
path: root/arch/nds32
diff options
context:
space:
mode:
authorrick <rick@andestech.com>2017-05-17 02:59:20 (GMT)
committerAndes <uboot@andestech.com>2017-05-22 06:05:40 (GMT)
commitf5076f869855045e527de7f1367c65f55a2b1448 (patch)
treef436ab387b72ae4a2215400de844c97a7f8049e7 /arch/nds32
parent86132af799d51e8e94d87dc56a071f325f369e0c (diff)
downloadu-boot-f5076f869855045e527de7f1367c65f55a2b1448.tar.xz
nds32: Support AG101P timer DM.
Support AG101P timer device tree flow. Signed-off-by: rick <rick@andestech.com>
Diffstat (limited to 'arch/nds32')
-rw-r--r--arch/nds32/cpu/n1213/ag101/timer.c3
-rw-r--r--arch/nds32/dts/ag101p.dts8
2 files changed, 10 insertions, 1 deletions
diff --git a/arch/nds32/cpu/n1213/ag101/timer.c b/arch/nds32/cpu/n1213/ag101/timer.c
index 758b354..0c03a10 100644
--- a/arch/nds32/cpu/n1213/ag101/timer.c
+++ b/arch/nds32/cpu/n1213/ag101/timer.c
@@ -8,7 +8,7 @@
*
* SPDX-License-Identifier: GPL-2.0+
*/
-
+#ifndef CONFIG_TIMER
#include <common.h>
#include <asm/io.h>
#include <faraday/fttmr010.h>
@@ -189,3 +189,4 @@ ulong get_tbclk(void)
return CONFIG_SYS_CLK_FREQ;
#endif
}
+#endif /* CONFIG_TIMER */
diff --git a/arch/nds32/dts/ag101p.dts b/arch/nds32/dts/ag101p.dts
index 2baa3dc..91314b5 100644
--- a/arch/nds32/dts/ag101p.dts
+++ b/arch/nds32/dts/ag101p.dts
@@ -13,6 +13,7 @@
/* bootargs = "console=ttyS0,38400n8 earlyprintk=uart8250-32bit,0x99600000 debug bootmem_debug memblock=debug loglevel=7"; */
bootargs = "console=ttyS0,38400n8 earlyprintk=uart8250-32bit,0x99600000 debug loglevel=7";
stdout-path = "uart0:38400n8";
+ tick-timer = &timer0;
};
memory@0 {
@@ -46,4 +47,11 @@
no-loopback-test = <1>;
};
+ timer0: timer@98400000 {
+ compatible = "andestech,attmr010";
+ reg = <0x98400000 0x1000>;
+ interrupts = <19 4>;
+ clock-frequency = <15000000>;
+ };
+
};