1 1.1 jmcneill /* $NetBSD: rk3036-cru.h,v 1.1.1.3 2021/11/07 16:49:57 jmcneill Exp $ */ 2 1.1 jmcneill 3 1.1.1.2 skrll /* SPDX-License-Identifier: GPL-2.0-or-later */ 4 1.1 jmcneill /* 5 1.1 jmcneill * Copyright (c) 2015 Rockchip Electronics Co. Ltd. 6 1.1 jmcneill * Author: Xing Zheng <zhengxing (at) rock-chips.com> 7 1.1 jmcneill */ 8 1.1 jmcneill 9 1.1 jmcneill #ifndef _DT_BINDINGS_CLK_ROCKCHIP_RK3036_H 10 1.1 jmcneill #define _DT_BINDINGS_CLK_ROCKCHIP_RK3036_H 11 1.1 jmcneill 12 1.1 jmcneill /* core clocks */ 13 1.1 jmcneill #define PLL_APLL 1 14 1.1 jmcneill #define PLL_DPLL 2 15 1.1 jmcneill #define PLL_GPLL 3 16 1.1 jmcneill #define ARMCLK 4 17 1.1 jmcneill 18 1.1 jmcneill /* sclk gates (special clocks) */ 19 1.1 jmcneill #define SCLK_GPU 64 20 1.1 jmcneill #define SCLK_SPI 65 21 1.1 jmcneill #define SCLK_SDMMC 68 22 1.1 jmcneill #define SCLK_SDIO 69 23 1.1 jmcneill #define SCLK_EMMC 71 24 1.1 jmcneill #define SCLK_NANDC 76 25 1.1 jmcneill #define SCLK_UART0 77 26 1.1 jmcneill #define SCLK_UART1 78 27 1.1 jmcneill #define SCLK_UART2 79 28 1.1 jmcneill #define SCLK_I2S 82 29 1.1 jmcneill #define SCLK_SPDIF 83 30 1.1 jmcneill #define SCLK_TIMER0 85 31 1.1 jmcneill #define SCLK_TIMER1 86 32 1.1 jmcneill #define SCLK_TIMER2 87 33 1.1 jmcneill #define SCLK_TIMER3 88 34 1.1 jmcneill #define SCLK_OTGPHY0 93 35 1.1 jmcneill #define SCLK_LCDC 100 36 1.1 jmcneill #define SCLK_HDMI 109 37 1.1 jmcneill #define SCLK_HEVC 111 38 1.1 jmcneill #define SCLK_I2S_OUT 113 39 1.1 jmcneill #define SCLK_SDMMC_DRV 114 40 1.1 jmcneill #define SCLK_SDIO_DRV 115 41 1.1 jmcneill #define SCLK_EMMC_DRV 117 42 1.1 jmcneill #define SCLK_SDMMC_SAMPLE 118 43 1.1 jmcneill #define SCLK_SDIO_SAMPLE 119 44 1.1 jmcneill #define SCLK_EMMC_SAMPLE 121 45 1.1 jmcneill #define SCLK_PVTM_CORE 123 46 1.1 jmcneill #define SCLK_PVTM_GPU 124 47 1.1 jmcneill #define SCLK_PVTM_VIDEO 125 48 1.1 jmcneill #define SCLK_MAC 151 49 1.1 jmcneill #define SCLK_MACREF 152 50 1.1 jmcneill #define SCLK_MACPLL 153 51 1.1 jmcneill #define SCLK_SFC 160 52 1.1 jmcneill 53 1.1 jmcneill /* aclk gates */ 54 1.1 jmcneill #define ACLK_DMAC2 194 55 1.1 jmcneill #define ACLK_LCDC 197 56 1.1 jmcneill #define ACLK_VIO 203 57 1.1 jmcneill #define ACLK_VCODEC 208 58 1.1 jmcneill #define ACLK_CPU 209 59 1.1 jmcneill #define ACLK_PERI 210 60 1.1 jmcneill 61 1.1 jmcneill /* pclk gates */ 62 1.1 jmcneill #define PCLK_GPIO0 320 63 1.1 jmcneill #define PCLK_GPIO1 321 64 1.1 jmcneill #define PCLK_GPIO2 322 65 1.1 jmcneill #define PCLK_GRF 329 66 1.1 jmcneill #define PCLK_I2C0 332 67 1.1 jmcneill #define PCLK_I2C1 333 68 1.1 jmcneill #define PCLK_I2C2 334 69 1.1 jmcneill #define PCLK_SPI 338 70 1.1 jmcneill #define PCLK_UART0 341 71 1.1 jmcneill #define PCLK_UART1 342 72 1.1 jmcneill #define PCLK_UART2 343 73 1.1 jmcneill #define PCLK_PWM 350 74 1.1 jmcneill #define PCLK_TIMER 353 75 1.1 jmcneill #define PCLK_HDMI 360 76 1.1 jmcneill #define PCLK_CPU 362 77 1.1 jmcneill #define PCLK_PERI 363 78 1.1 jmcneill #define PCLK_DDRUPCTL 364 79 1.1 jmcneill #define PCLK_WDT 368 80 1.1 jmcneill #define PCLK_ACODEC 369 81 1.1 jmcneill 82 1.1 jmcneill /* hclk gates */ 83 1.1 jmcneill #define HCLK_OTG0 449 84 1.1 jmcneill #define HCLK_OTG1 450 85 1.1 jmcneill #define HCLK_NANDC 453 86 1.1.1.3 jmcneill #define HCLK_SFC 454 87 1.1 jmcneill #define HCLK_SDMMC 456 88 1.1 jmcneill #define HCLK_SDIO 457 89 1.1 jmcneill #define HCLK_EMMC 459 90 1.1 jmcneill #define HCLK_MAC 460 91 1.1 jmcneill #define HCLK_I2S 462 92 1.1 jmcneill #define HCLK_LCDC 465 93 1.1 jmcneill #define HCLK_ROM 467 94 1.1 jmcneill #define HCLK_VIO_BUS 472 95 1.1 jmcneill #define HCLK_VCODEC 476 96 1.1 jmcneill #define HCLK_CPU 477 97 1.1 jmcneill #define HCLK_PERI 478 98 1.1 jmcneill 99 1.1 jmcneill #define CLK_NR_CLKS (HCLK_PERI + 1) 100 1.1 jmcneill 101 1.1 jmcneill /* soft-reset indices */ 102 1.1 jmcneill #define SRST_CORE0 0 103 1.1 jmcneill #define SRST_CORE1 1 104 1.1 jmcneill #define SRST_CORE0_DBG 4 105 1.1 jmcneill #define SRST_CORE1_DBG 5 106 1.1 jmcneill #define SRST_CORE0_POR 8 107 1.1 jmcneill #define SRST_CORE1_POR 9 108 1.1 jmcneill #define SRST_L2C 12 109 1.1 jmcneill #define SRST_TOPDBG 13 110 1.1 jmcneill #define SRST_STRC_SYS_A 14 111 1.1 jmcneill #define SRST_PD_CORE_NIU 15 112 1.1 jmcneill 113 1.1 jmcneill #define SRST_TIMER2 16 114 1.1 jmcneill #define SRST_CPUSYS_H 17 115 1.1 jmcneill #define SRST_AHB2APB_H 19 116 1.1 jmcneill #define SRST_TIMER3 20 117 1.1 jmcneill #define SRST_INTMEM 21 118 1.1 jmcneill #define SRST_ROM 22 119 1.1 jmcneill #define SRST_PERI_NIU 23 120 1.1 jmcneill #define SRST_I2S 24 121 1.1 jmcneill #define SRST_DDR_PLL 25 122 1.1 jmcneill #define SRST_GPU_DLL 26 123 1.1 jmcneill #define SRST_TIMER0 27 124 1.1 jmcneill #define SRST_TIMER1 28 125 1.1 jmcneill #define SRST_CORE_DLL 29 126 1.1 jmcneill #define SRST_EFUSE_P 30 127 1.1 jmcneill #define SRST_ACODEC_P 31 128 1.1 jmcneill 129 1.1 jmcneill #define SRST_GPIO0 32 130 1.1 jmcneill #define SRST_GPIO1 33 131 1.1 jmcneill #define SRST_GPIO2 34 132 1.1 jmcneill #define SRST_UART0 39 133 1.1 jmcneill #define SRST_UART1 40 134 1.1 jmcneill #define SRST_UART2 41 135 1.1 jmcneill #define SRST_I2C0 43 136 1.1 jmcneill #define SRST_I2C1 44 137 1.1 jmcneill #define SRST_I2C2 45 138 1.1 jmcneill #define SRST_SFC 47 139 1.1 jmcneill 140 1.1 jmcneill #define SRST_PWM0 48 141 1.1 jmcneill #define SRST_DAP 51 142 1.1 jmcneill #define SRST_DAP_SYS 52 143 1.1 jmcneill #define SRST_GRF 55 144 1.1 jmcneill #define SRST_PERIPHSYS_A 57 145 1.1 jmcneill #define SRST_PERIPHSYS_H 58 146 1.1 jmcneill #define SRST_PERIPHSYS_P 59 147 1.1 jmcneill #define SRST_CPU_PERI 61 148 1.1 jmcneill #define SRST_EMEM_PERI 62 149 1.1 jmcneill #define SRST_USB_PERI 63 150 1.1 jmcneill 151 1.1 jmcneill #define SRST_DMA2 64 152 1.1 jmcneill #define SRST_MAC 66 153 1.1 jmcneill #define SRST_NANDC 68 154 1.1 jmcneill #define SRST_USBOTG0 69 155 1.1 jmcneill #define SRST_OTGC0 71 156 1.1 jmcneill #define SRST_USBOTG1 72 157 1.1 jmcneill #define SRST_OTGC1 74 158 1.1 jmcneill #define SRST_DDRMSCH 79 159 1.1 jmcneill 160 1.1 jmcneill #define SRST_MMC0 81 161 1.1 jmcneill #define SRST_SDIO 82 162 1.1 jmcneill #define SRST_EMMC 83 163 1.1 jmcneill #define SRST_SPI0 84 164 1.1 jmcneill #define SRST_WDT 86 165 1.1 jmcneill #define SRST_DDRPHY 88 166 1.1 jmcneill #define SRST_DDRPHY_P 89 167 1.1 jmcneill #define SRST_DDRCTRL 90 168 1.1 jmcneill #define SRST_DDRCTRL_P 91 169 1.1 jmcneill 170 1.1 jmcneill #define SRST_HDMI_P 96 171 1.1 jmcneill #define SRST_VIO_BUS_H 99 172 1.1 jmcneill #define SRST_UTMI0 103 173 1.1 jmcneill #define SRST_UTMI1 104 174 1.1 jmcneill #define SRST_USBPOR 105 175 1.1 jmcneill 176 1.1 jmcneill #define SRST_VCODEC_A 112 177 1.1 jmcneill #define SRST_VCODEC_H 113 178 1.1 jmcneill #define SRST_VIO1_A 114 179 1.1 jmcneill #define SRST_HEVC 115 180 1.1 jmcneill #define SRST_VCODEC_NIU_A 116 181 1.1 jmcneill #define SRST_LCDC1_A 117 182 1.1 jmcneill #define SRST_LCDC1_H 118 183 1.1 jmcneill #define SRST_LCDC1_D 119 184 1.1 jmcneill #define SRST_GPU 120 185 1.1 jmcneill #define SRST_GPU_NIU_A 122 186 1.1 jmcneill 187 1.1 jmcneill #define SRST_DBG_P 131 188 1.1 jmcneill 189 1.1 jmcneill #endif 190