From cfcad1d390273c0d49132ec5c1accf3b6ed72447 Mon Sep 17 00:00:00 2001 From: Mark Kettenis Date: Tue, 1 Jan 2019 15:54:34 +0000 Subject: Add RK3399 TSADC clock. --- sys/dev/fdt/rkclock.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'sys/dev/fdt/rkclock.c') diff --git a/sys/dev/fdt/rkclock.c b/sys/dev/fdt/rkclock.c index 7c8036daedb..80fb368b999 100644 --- a/sys/dev/fdt/rkclock.c +++ b/sys/dev/fdt/rkclock.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rkclock.c,v 1.39 2019/01/01 14:41:46 kettenis Exp $ */ +/* $OpenBSD: rkclock.c,v 1.40 2019/01/01 15:54:33 kettenis Exp $ */ /* * Copyright (c) 2017, 2018 Mark Kettenis * @@ -1480,6 +1480,11 @@ struct rkclock rk3399_clocks[] = { /* RK3399_PLL_PPLL */ 0, /* RK3399_USB_480M */ 0, RK3399_XIN24M } }, + { + RK3399_CLK_TSADC, RK3399_CRU_CLKSEL_CON(27), + SEL(15, 15), DIV(9, 0), + { RK3399_XIN24M, RK3399_CLK_32K } + }, { RK3399_CLK_UART0, RK3399_CRU_CLKSEL_CON(33), SEL(9, 8), 0, @@ -1828,6 +1833,8 @@ rk3399_get_frequency(void *cookie, uint32_t *cells) return rk3399_get_armclk(sc, RK3399_CRU_CLKSEL_CON(2)); case RK3399_XIN24M: return 24000000; + case RK3399_CLK_32K: + return 32768; default: break; } -- cgit v1.2.3