diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2017-09-13 14:04:14 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2017-09-13 14:04:14 -0400 |
| commit | f60a2abfdbf298a4722dfef331c38447fa18c4e3 (patch) | |
| tree | 1ac56db32fb1909aedefc21b1c62d0bbe5a13e68 /include | |
| parent | 561a8eb3e1d219f415597c76dae44b530b7f961a (diff) | |
| parent | 73c950da6ec523136090d6d4d6907a6ea8e8b67b (diff) | |
Merge tag 'clk-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux
Pull clk updates from Stephen Boyd:
"The diff is dominated by the Allwinner A10/A20 SoCs getting converted
to the sunxi-ng framework. Otherwise, the heavy hitters are various
drivers for SoCs like AT91, Amlogic, Renesas, and Rockchip. There are
some other new clk drivers in here too but overall this is just a
bunch of clk drivers for various different pieces of hardware and a
collection of non-critical fixes for clk drivers.
New Drivers:
- Allwinner R40 SoCs
- Renesas R-Car Gen3 USB 2.0 clock selector PHY
- Atmel AT91 audio PLL
- Uniphier PXs3 SoCs
- ARC HSDK Board PLLs
- AXS10X Board PLLs
- STMicroelectronics STM32H743 SoCs
Removed Drivers:
- Non-compiling mb86s7x support
Updates:
- Allwinner A10/A20 SoCs converted to sunxi-ng framework
- Allwinner H3 CPU clk fixes
- Renesas R-Car D3 SoC
- Renesas V2H and M3-W modules
- Samsung Exynos5420/5422/5800 audio fixes
- Rockchip fractional clk approximation fixes
- Rockchip rk3126 SoC support within the rk3128 driver
- Amlogic gxbb CEC32 and sd_emmc clks
- Amlogic meson8b reset controller support
- IDT VersaClock 5P49V5925/5P49V6901 support
- Qualcomm MSM8996 SMMU clks
- Various 'const' applications for struct clk_ops
- si5351 PLL reset bugfix
- Uniphier audio on LD11/LD20 and ethernet support on LD11/LD20/Pro4/PXs2
- Assorted Tegra clk driver fixes"
* tag 'clk-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux: (120 commits)
clk: si5351: fix PLL reset
ASoC: atmel-classd: remove aclk clock
ASoC: atmel-classd: remove aclk clock from DT binding
clk: at91: clk-generated: make gclk determine audio_pll rate
clk: at91: clk-generated: create function to find best_diff
clk: at91: add audio pll clock drivers
dt-bindings: clk: at91: add audio plls to the compatible list
clk: at91: clk-generated: remove useless divisor loop
clk: mb86s7x: Drop non-building driver
clk: ti: check for null return in strrchr to avoid null dereferencing
clk: Don't write error code into divider register
clk: uniphier: add video input subsystem clock
clk: uniphier: add audio system clock
clk: stm32h7: Add stm32h743 clock driver
clk: gate: expose clk_gate_ops::is_enabled
clk: nxp: clk-lpc32xx: rename clk_gate_is_enabled()
clk: uniphier: add PXs3 clock data
clk: hi6220: change watchdog clock source
clk: Kconfig: Name RK805 in Kconfig for COMMON_CLK_RK808
clk: cs2000: Add cs2000_set_saved_rate
...
Diffstat (limited to 'include')
| -rw-r--r-- | include/dt-bindings/clock/qcom,gcc-msm8996.h | 2 | ||||
| -rw-r--r-- | include/dt-bindings/clock/r8a77995-cpg-mssr.h | 57 | ||||
| -rw-r--r-- | include/dt-bindings/clock/rk3228-cru.h | 1 | ||||
| -rw-r--r-- | include/dt-bindings/clock/rv1108-cru.h | 8 | ||||
| -rw-r--r-- | include/dt-bindings/clock/stm32h7-clks.h | 165 | ||||
| -rw-r--r-- | include/dt-bindings/clock/sun4i-a10-ccu.h | 200 | ||||
| -rw-r--r-- | include/dt-bindings/clock/sun7i-a20-ccu.h | 53 | ||||
| -rw-r--r-- | include/dt-bindings/clock/sun8i-r40-ccu.h | 187 | ||||
| -rw-r--r-- | include/dt-bindings/mfd/stm32h7-rcc.h | 136 | ||||
| -rw-r--r-- | include/dt-bindings/reset/sun4i-a10-ccu.h | 69 | ||||
| -rw-r--r-- | include/dt-bindings/reset/sun8i-r40-ccu.h | 130 | ||||
| -rw-r--r-- | include/linux/clk-provider.h | 4 | ||||
| -rw-r--r-- | include/linux/clk/at91_pmc.h | 25 |
13 files changed, 1034 insertions, 3 deletions
diff --git a/include/dt-bindings/clock/qcom,gcc-msm8996.h b/include/dt-bindings/clock/qcom,gcc-msm8996.h index 1f5c42254798..75b07cf5eed0 100644 --- a/include/dt-bindings/clock/qcom,gcc-msm8996.h +++ b/include/dt-bindings/clock/qcom,gcc-msm8996.h | |||
| @@ -233,6 +233,8 @@ | |||
| 233 | #define GCC_PCIE_CLKREF_CLK 216 | 233 | #define GCC_PCIE_CLKREF_CLK 216 |
| 234 | #define GCC_RX2_USB2_CLKREF_CLK 217 | 234 | #define GCC_RX2_USB2_CLKREF_CLK 217 |
| 235 | #define GCC_RX1_USB2_CLKREF_CLK 218 | 235 | #define GCC_RX1_USB2_CLKREF_CLK 218 |
| 236 | #define GCC_HLOS1_VOTE_LPASS_CORE_SMMU_CLK 219 | ||
| 237 | #define GCC_HLOS1_VOTE_LPASS_ADSP_SMMU_CLK 220 | ||
| 236 | 238 | ||
| 237 | #define GCC_SYSTEM_NOC_BCR 0 | 239 | #define GCC_SYSTEM_NOC_BCR 0 |
| 238 | #define GCC_CONFIG_NOC_BCR 1 | 240 | #define GCC_CONFIG_NOC_BCR 1 |
diff --git a/include/dt-bindings/clock/r8a77995-cpg-mssr.h b/include/dt-bindings/clock/r8a77995-cpg-mssr.h new file mode 100644 index 000000000000..4e8ae3dee590 --- /dev/null +++ b/include/dt-bindings/clock/r8a77995-cpg-mssr.h | |||
| @@ -0,0 +1,57 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2017 Glider bvba | ||
| 3 | * | ||
| 4 | * This program is free software; you can redistribute it and/or modify | ||
| 5 | * it under the terms of the GNU General Public License as published by | ||
| 6 | * the Free Software Foundation; either version 2 of the License, or | ||
| 7 | * (at your option) any later version. | ||
| 8 | */ | ||
| 9 | #ifndef __DT_BINDINGS_CLOCK_R8A77995_CPG_MSSR_H__ | ||
| 10 | #define __DT_BINDINGS_CLOCK_R8A77995_CPG_MSSR_H__ | ||
| 11 | |||
| 12 | #include <dt-bindings/clock/renesas-cpg-mssr.h> | ||
| 13 | |||
| 14 | /* r8a77995 CPG Core Clocks */ | ||
| 15 | #define R8A77995_CLK_Z2 0 | ||
| 16 | #define R8A77995_CLK_ZG 1 | ||
| 17 | #define R8A77995_CLK_ZTR 2 | ||
| 18 | #define R8A77995_CLK_ZT 3 | ||
| 19 | #define R8A77995_CLK_ZX 4 | ||
| 20 | #define R8A77995_CLK_S0D1 5 | ||
| 21 | #define R8A77995_CLK_S1D1 6 | ||
| 22 | #define R8A77995_CLK_S1D2 7 | ||
| 23 | #define R8A77995_CLK_S1D4 8 | ||
| 24 | #define R8A77995_CLK_S2D1 9 | ||
| 25 | #define R8A77995_CLK_S2D2 10 | ||
| 26 | #define R8A77995_CLK_S2D4 11 | ||
| 27 | #define R8A77995_CLK_S3D1 12 | ||
| 28 | #define R8A77995_CLK_S3D2 13 | ||
| 29 | #define R8A77995_CLK_S3D4 14 | ||
| 30 | #define R8A77995_CLK_S1D4C 15 | ||
| 31 | #define R8A77995_CLK_S3D1C 16 | ||
| 32 | #define R8A77995_CLK_S3D2C 17 | ||
| 33 | #define R8A77995_CLK_S3D4C 18 | ||
| 34 | #define R8A77995_CLK_LB 19 | ||
| 35 | #define R8A77995_CLK_CL 20 | ||
| 36 | #define R8A77995_CLK_ZB3 21 | ||
| 37 | #define R8A77995_CLK_ZB3D2 22 | ||
| 38 | #define R8A77995_CLK_CR 23 | ||
| 39 | #define R8A77995_CLK_CRD2 24 | ||
| 40 | #define R8A77995_CLK_SD0H 25 | ||
| 41 | #define R8A77995_CLK_SD0 26 | ||
| 42 | #define R8A77995_CLK_SSP2 27 | ||
| 43 | #define R8A77995_CLK_SSP1 28 | ||
| 44 | #define R8A77995_CLK_RPC 29 | ||
| 45 | #define R8A77995_CLK_RPCD2 30 | ||
| 46 | #define R8A77995_CLK_ZA2 31 | ||
| 47 | #define R8A77995_CLK_ZA8 32 | ||
| 48 | #define R8A77995_CLK_Z2D 33 | ||
| 49 | #define R8A77995_CLK_CANFD 34 | ||
| 50 | #define R8A77995_CLK_MSO 35 | ||
| 51 | #define R8A77995_CLK_R 36 | ||
| 52 | #define R8A77995_CLK_OSC 37 | ||
| 53 | #define R8A77995_CLK_LV0 38 | ||
| 54 | #define R8A77995_CLK_LV1 39 | ||
| 55 | #define R8A77995_CLK_CP 40 | ||
| 56 | |||
| 57 | #endif /* __DT_BINDINGS_CLOCK_R8A77995_CPG_MSSR_H__ */ | ||
diff --git a/include/dt-bindings/clock/rk3228-cru.h b/include/dt-bindings/clock/rk3228-cru.h index 56f841c22801..55655ab0a4c4 100644 --- a/include/dt-bindings/clock/rk3228-cru.h +++ b/include/dt-bindings/clock/rk3228-cru.h | |||
| @@ -49,6 +49,7 @@ | |||
| 49 | #define SCLK_EMMC_DRV 117 | 49 | #define SCLK_EMMC_DRV 117 |
| 50 | #define SCLK_SDMMC_SAMPLE 118 | 50 | #define SCLK_SDMMC_SAMPLE 118 |
| 51 | #define SCLK_SDIO_SAMPLE 119 | 51 | #define SCLK_SDIO_SAMPLE 119 |
| 52 | #define SCLK_SDIO_SRC 120 | ||
| 52 | #define SCLK_EMMC_SAMPLE 121 | 53 | #define SCLK_EMMC_SAMPLE 121 |
| 53 | #define SCLK_VOP 122 | 54 | #define SCLK_VOP 122 |
| 54 | #define SCLK_HDMI_HDCP 123 | 55 | #define SCLK_HDMI_HDCP 123 |
diff --git a/include/dt-bindings/clock/rv1108-cru.h b/include/dt-bindings/clock/rv1108-cru.h index f269d833e41a..d8d0e0456dc2 100644 --- a/include/dt-bindings/clock/rv1108-cru.h +++ b/include/dt-bindings/clock/rv1108-cru.h | |||
| @@ -67,9 +67,9 @@ | |||
| 67 | #define SCLK_SPI 108 | 67 | #define SCLK_SPI 108 |
| 68 | #define SCLK_SARADC 109 | 68 | #define SCLK_SARADC 109 |
| 69 | #define SCLK_TSADC 110 | 69 | #define SCLK_TSADC 110 |
| 70 | #define SCLK_MACPHY_PRE 111 | 70 | #define SCLK_MAC_PRE 111 |
| 71 | #define SCLK_MACPHY 112 | 71 | #define SCLK_MAC 112 |
| 72 | #define SCLK_MACPHY_RX 113 | 72 | #define SCLK_MAC_RX 113 |
| 73 | #define SCLK_MAC_REF 114 | 73 | #define SCLK_MAC_REF 114 |
| 74 | #define SCLK_MAC_REFOUT 115 | 74 | #define SCLK_MAC_REFOUT 115 |
| 75 | #define SCLK_DSP_PFM 116 | 75 | #define SCLK_DSP_PFM 116 |
| @@ -110,6 +110,7 @@ | |||
| 110 | #define ACLK_CIF2 207 | 110 | #define ACLK_CIF2 207 |
| 111 | #define ACLK_CIF3 208 | 111 | #define ACLK_CIF3 208 |
| 112 | #define ACLK_PERI 209 | 112 | #define ACLK_PERI 209 |
| 113 | #define ACLK_GMAC 210 | ||
| 113 | 114 | ||
| 114 | /* pclk gates */ | 115 | /* pclk gates */ |
| 115 | #define PCLK_GPIO1 256 | 116 | #define PCLK_GPIO1 256 |
| @@ -141,6 +142,7 @@ | |||
| 141 | #define PCLK_EFUSE0 282 | 142 | #define PCLK_EFUSE0 282 |
| 142 | #define PCLK_EFUSE1 283 | 143 | #define PCLK_EFUSE1 283 |
| 143 | #define PCLK_WDT 284 | 144 | #define PCLK_WDT 284 |
| 145 | #define PCLK_GMAC 285 | ||
| 144 | 146 | ||
| 145 | /* hclk gates */ | 147 | /* hclk gates */ |
| 146 | #define HCLK_I2S0_8CH 320 | 148 | #define HCLK_I2S0_8CH 320 |
diff --git a/include/dt-bindings/clock/stm32h7-clks.h b/include/dt-bindings/clock/stm32h7-clks.h new file mode 100644 index 000000000000..6637272b3242 --- /dev/null +++ b/include/dt-bindings/clock/stm32h7-clks.h | |||
| @@ -0,0 +1,165 @@ | |||
| 1 | /* SYS, CORE AND BUS CLOCKS */ | ||
| 2 | #define SYS_D1CPRE 0 | ||
| 3 | #define HCLK 1 | ||
| 4 | #define PCLK1 2 | ||
| 5 | #define PCLK2 3 | ||
| 6 | #define PCLK3 4 | ||
| 7 | #define PCLK4 5 | ||
| 8 | #define HSI_DIV 6 | ||
| 9 | #define HSE_1M 7 | ||
| 10 | #define I2S_CKIN 8 | ||
| 11 | #define CK_DSI_PHY 9 | ||
| 12 | #define HSE_CK 10 | ||
| 13 | #define LSE_CK 11 | ||
| 14 | #define CSI_KER_DIV122 12 | ||
| 15 | #define RTC_CK 13 | ||
| 16 | #define CPU_SYSTICK 14 | ||
| 17 | |||
| 18 | /* OSCILLATOR BANK */ | ||
| 19 | #define OSC_BANK 18 | ||
| 20 | #define HSI_CK 18 | ||
| 21 | #define HSI_KER_CK 19 | ||
| 22 | #define CSI_CK 20 | ||
| 23 | #define CSI_KER_CK 21 | ||
| 24 | #define RC48_CK 22 | ||
| 25 | #define LSI_CK 23 | ||
| 26 | |||
| 27 | /* MCLOCK BANK */ | ||
| 28 | #define MCLK_BANK 28 | ||
| 29 | #define PER_CK 28 | ||
| 30 | #define PLLSRC 29 | ||
| 31 | #define SYS_CK 30 | ||
| 32 | #define TRACEIN_CK 31 | ||
| 33 | |||
| 34 | /* ODF BANK */ | ||
| 35 | #define ODF_BANK 32 | ||
| 36 | #define PLL1_P 32 | ||
| 37 | #define PLL1_Q 33 | ||
| 38 | #define PLL1_R 34 | ||
| 39 | #define PLL2_P 35 | ||
| 40 | #define PLL2_Q 36 | ||
| 41 | #define PLL2_R 37 | ||
| 42 | #define PLL3_P 38 | ||
| 43 | #define PLL3_Q 39 | ||
| 44 | #define PLL3_R 40 | ||
| 45 | |||
| 46 | /* MCO BANK */ | ||
| 47 | #define MCO_BANK 41 | ||
| 48 | #define MCO1 41 | ||
| 49 | #define MCO2 42 | ||
| 50 | |||
| 51 | /* PERIF BANK */ | ||
| 52 | #define PERIF_BANK 50 | ||
| 53 | #define D1SRAM1_CK 50 | ||
| 54 | #define ITCM_CK 51 | ||
| 55 | #define DTCM2_CK 52 | ||
| 56 | #define DTCM1_CK 53 | ||
| 57 | #define FLITF_CK 54 | ||
| 58 | #define JPGDEC_CK 55 | ||
| 59 | #define DMA2D_CK 56 | ||
| 60 | #define MDMA_CK 57 | ||
| 61 | #define USB2ULPI_CK 58 | ||
| 62 | #define USB1ULPI_CK 59 | ||
| 63 | #define ETH1RX_CK 60 | ||
| 64 | #define ETH1TX_CK 61 | ||
| 65 | #define ETH1MAC_CK 62 | ||
| 66 | #define ART_CK 63 | ||
| 67 | #define DMA2_CK 64 | ||
| 68 | #define DMA1_CK 65 | ||
| 69 | #define D2SRAM3_CK 66 | ||
| 70 | #define D2SRAM2_CK 67 | ||
| 71 | #define D2SRAM1_CK 68 | ||
| 72 | #define HASH_CK 69 | ||
| 73 | #define CRYPT_CK 70 | ||
| 74 | #define CAMITF_CK 71 | ||
| 75 | #define BKPRAM_CK 72 | ||
| 76 | #define HSEM_CK 73 | ||
| 77 | #define BDMA_CK 74 | ||
| 78 | #define CRC_CK 75 | ||
| 79 | #define GPIOK_CK 76 | ||
| 80 | #define GPIOJ_CK 77 | ||
| 81 | #define GPIOI_CK 78 | ||
| 82 | #define GPIOH_CK 79 | ||
| 83 | #define GPIOG_CK 80 | ||
| 84 | #define GPIOF_CK 81 | ||
| 85 | #define GPIOE_CK 82 | ||
| 86 | #define GPIOD_CK 83 | ||
| 87 | #define GPIOC_CK 84 | ||
| 88 | #define GPIOB_CK 85 | ||
| 89 | #define GPIOA_CK 86 | ||
| 90 | #define WWDG1_CK 87 | ||
| 91 | #define DAC12_CK 88 | ||
| 92 | #define WWDG2_CK 89 | ||
| 93 | #define TIM14_CK 90 | ||
| 94 | #define TIM13_CK 91 | ||
| 95 | #define TIM12_CK 92 | ||
| 96 | #define TIM7_CK 93 | ||
| 97 | #define TIM6_CK 94 | ||
| 98 | #define TIM5_CK 95 | ||
| 99 | #define TIM4_CK 96 | ||
| 100 | #define TIM3_CK 97 | ||
| 101 | #define TIM2_CK 98 | ||
| 102 | #define MDIOS_CK 99 | ||
| 103 | #define OPAMP_CK 100 | ||
| 104 | #define CRS_CK 101 | ||
| 105 | #define TIM17_CK 102 | ||
| 106 | #define TIM16_CK 103 | ||
| 107 | #define TIM15_CK 104 | ||
| 108 | #define TIM8_CK 105 | ||
| 109 | #define TIM1_CK 106 | ||
| 110 | #define TMPSENS_CK 107 | ||
| 111 | #define RTCAPB_CK 108 | ||
| 112 | #define VREF_CK 109 | ||
| 113 | #define COMP12_CK 110 | ||
| 114 | #define SYSCFG_CK 111 | ||
| 115 | |||
| 116 | /* KERNEL BANK */ | ||
| 117 | #define KERN_BANK 120 | ||
| 118 | #define SDMMC1_CK 120 | ||
| 119 | #define QUADSPI_CK 121 | ||
| 120 | #define FMC_CK 122 | ||
| 121 | #define USB2OTG_CK 123 | ||
| 122 | #define USB1OTG_CK 124 | ||
| 123 | #define ADC12_CK 125 | ||
| 124 | #define SDMMC2_CK 126 | ||
| 125 | #define RNG_CK 127 | ||
| 126 | #define ADC3_CK 128 | ||
| 127 | #define DSI_CK 129 | ||
| 128 | #define LTDC_CK 130 | ||
| 129 | #define USART8_CK 131 | ||
| 130 | #define USART7_CK 132 | ||
| 131 | #define HDMICEC_CK 133 | ||
| 132 | #define I2C3_CK 134 | ||
| 133 | #define I2C2_CK 135 | ||
| 134 | #define I2C1_CK 136 | ||
| 135 | #define UART5_CK 137 | ||
| 136 | #define UART4_CK 138 | ||
| 137 | #define USART3_CK 139 | ||
| 138 | #define USART2_CK 140 | ||
| 139 | #define SPDIFRX_CK 141 | ||
| 140 | #define SPI3_CK 142 | ||
| 141 | #define SPI2_CK 143 | ||
| 142 | #define LPTIM1_CK 144 | ||
| 143 | #define FDCAN_CK 145 | ||
| 144 | #define SWP_CK 146 | ||
| 145 | #define HRTIM_CK 147 | ||
| 146 | #define DFSDM1_CK 148 | ||
| 147 | #define SAI3_CK 149 | ||
| 148 | #define SAI2_CK 150 | ||
| 149 | #define SAI1_CK 151 | ||
| 150 | #define SPI5_CK 152 | ||
| 151 | #define SPI4_CK 153 | ||
| 152 | #define SPI1_CK 154 | ||
| 153 | #define USART6_CK 155 | ||
| 154 | #define USART1_CK 156 | ||
| 155 | #define SAI4B_CK 157 | ||
| 156 | #define SAI4A_CK 158 | ||
| 157 | #define LPTIM5_CK 159 | ||
| 158 | #define LPTIM4_CK 160 | ||
| 159 | #define LPTIM3_CK 161 | ||
| 160 | #define LPTIM2_CK 162 | ||
| 161 | #define I2C4_CK 163 | ||
| 162 | #define SPI6_CK 164 | ||
| 163 | #define LPUART1_CK 165 | ||
| 164 | |||
| 165 | #define STM32H7_MAX_CLKS 166 | ||
diff --git a/include/dt-bindings/clock/sun4i-a10-ccu.h b/include/dt-bindings/clock/sun4i-a10-ccu.h new file mode 100644 index 000000000000..c5a53f38d654 --- /dev/null +++ b/include/dt-bindings/clock/sun4i-a10-ccu.h | |||
| @@ -0,0 +1,200 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2017 Priit Laes <plaes@plaes.org> | ||
| 3 | * | ||
| 4 | * This file is dual-licensed: you can use it either under the terms | ||
| 5 | * of the GPL or the X11 license, at your option. Note that this dual | ||
| 6 | * licensing only applies to this file, and not this project as a | ||
| 7 | * whole. | ||
| 8 | * | ||
| 9 | * a) This file is free software; you can redistribute it and/or | ||
| 10 | * modify it under the terms of the GNU General Public License as | ||
| 11 | * published by the Free Software Foundation; either version 2 of the | ||
| 12 | * License, or (at your option) any later version. | ||
| 13 | * | ||
| 14 | * This file is distributed in the hope that it will be useful, | ||
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 17 | * GNU General Public License for more details. | ||
| 18 | * | ||
| 19 | * Or, alternatively, | ||
| 20 | * | ||
| 21 | * b) Permission is hereby granted, free of charge, to any person | ||
| 22 | * obtaining a copy of this software and associated documentation | ||
| 23 | * files (the "Software"), to deal in the Software without | ||
| 24 | * restriction, including without limitation the rights to use, | ||
| 25 | * copy, modify, merge, publish, distribute, sublicense, and/or | ||
| 26 | * sell copies of the Software, and to permit persons to whom the | ||
| 27 | * Software is furnished to do so, subject to the following | ||
| 28 | * conditions: | ||
| 29 | * | ||
| 30 | * The above copyright notice and this permission notice shall be | ||
| 31 | * included in all copies or substantial portions of the Software. | ||
| 32 | * | ||
| 33 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
| 34 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES | ||
| 35 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
| 36 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT | ||
| 37 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, | ||
| 38 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR | ||
| 39 | * OTHER DEALINGS IN THE SOFTWARE. | ||
| 40 | */ | ||
| 41 | |||
| 42 | #ifndef _DT_BINDINGS_CLK_SUN4I_A10_H_ | ||
| 43 | #define _DT_BINDINGS_CLK_SUN4I_A10_H_ | ||
| 44 | |||
| 45 | #define CLK_HOSC 1 | ||
| 46 | #define CLK_CPU 20 | ||
| 47 | |||
| 48 | /* AHB Gates */ | ||
| 49 | #define CLK_AHB_OTG 26 | ||
| 50 | #define CLK_AHB_EHCI0 27 | ||
| 51 | #define CLK_AHB_OHCI0 28 | ||
| 52 | #define CLK_AHB_EHCI1 29 | ||
| 53 | #define CLK_AHB_OHCI1 30 | ||
| 54 | #define CLK_AHB_SS 31 | ||
| 55 | #define CLK_AHB_DMA 32 | ||
| 56 | #define CLK_AHB_BIST 33 | ||
| 57 | #define CLK_AHB_MMC0 34 | ||
| 58 | #define CLK_AHB_MMC1 35 | ||
| 59 | #define CLK_AHB_MMC2 36 | ||
| 60 | #define CLK_AHB_MMC3 37 | ||
| 61 | #define CLK_AHB_MS 38 | ||
| 62 | #define CLK_AHB_NAND 39 | ||
| 63 | #define CLK_AHB_SDRAM 40 | ||
| 64 | #define CLK_AHB_ACE 41 | ||
| 65 | #define CLK_AHB_EMAC 42 | ||
| 66 | #define CLK_AHB_TS 43 | ||
| 67 | #define CLK_AHB_SPI0 44 | ||
| 68 | #define CLK_AHB_SPI1 45 | ||
| 69 | #define CLK_AHB_SPI2 46 | ||
| 70 | #define CLK_AHB_SPI3 47 | ||
| 71 | #define CLK_AHB_PATA 48 | ||
| 72 | #define CLK_AHB_SATA 49 | ||
| 73 | #define CLK_AHB_GPS 50 | ||
| 74 | #define CLK_AHB_HSTIMER 51 | ||
| 75 | #define CLK_AHB_VE 52 | ||
| 76 | #define CLK_AHB_TVD 53 | ||
| 77 | #define CLK_AHB_TVE0 54 | ||
| 78 | #define CLK_AHB_TVE1 55 | ||
| 79 | #define CLK_AHB_LCD0 56 | ||
| 80 | #define CLK_AHB_LCD1 57 | ||
| 81 | #define CLK_AHB_CSI0 58 | ||
| 82 | #define CLK_AHB_CSI1 59 | ||
| 83 | #define CLK_AHB_HDMI0 60 | ||
| 84 | #define CLK_AHB_HDMI1 61 | ||
| 85 | #define CLK_AHB_DE_BE0 62 | ||
| 86 | #define CLK_AHB_DE_BE1 63 | ||
| 87 | #define CLK_AHB_DE_FE0 64 | ||
| 88 | #define CLK_AHB_DE_FE1 65 | ||
| 89 | #define CLK_AHB_GMAC 66 | ||
| 90 | #define CLK_AHB_MP 67 | ||
| 91 | #define CLK_AHB_GPU 68 | ||
| 92 | |||
| 93 | /* APB0 Gates */ | ||
| 94 | #define CLK_APB0_CODEC 69 | ||
| 95 | #define CLK_APB0_SPDIF 70 | ||
| 96 | #define CLK_APB0_I2S0 71 | ||
| 97 | #define CLK_APB0_AC97 72 | ||
| 98 | #define CLK_APB0_I2S1 73 | ||
| 99 | #define CLK_APB0_PIO 74 | ||
| 100 | #define CLK_APB0_IR0 75 | ||
| 101 | #define CLK_APB0_IR1 76 | ||
| 102 | #define CLK_APB0_I2S2 77 | ||
| 103 | #define CLK_APB0_KEYPAD 78 | ||
| 104 | |||
| 105 | /* APB1 Gates */ | ||
| 106 | #define CLK_APB1_I2C0 79 | ||
| 107 | #define CLK_APB1_I2C1 80 | ||
| 108 | #define CLK_APB1_I2C2 81 | ||
| 109 | #define CLK_APB1_I2C3 82 | ||
| 110 | #define CLK_APB1_CAN 83 | ||
| 111 | #define CLK_APB1_SCR 84 | ||
| 112 | #define CLK_APB1_PS20 85 | ||
| 113 | #define CLK_APB1_PS21 86 | ||
| 114 | #define CLK_APB1_I2C4 87 | ||
| 115 | #define CLK_APB1_UART0 88 | ||
| 116 | #define CLK_APB1_UART1 89 | ||
| 117 | #define CLK_APB1_UART2 90 | ||
| 118 | #define CLK_APB1_UART3 91 | ||
| 119 | #define CLK_APB1_UART4 92 | ||
| 120 | #define CLK_APB1_UART5 93 | ||
| 121 | #define CLK_APB1_UART6 94 | ||
| 122 | #define CLK_APB1_UART7 95 | ||
| 123 | |||
| 124 | /* IP clocks */ | ||
| 125 | #define CLK_NAND 96 | ||
| 126 | #define CLK_MS 97 | ||
| 127 | #define CLK_MMC0 98 | ||
| 128 | #define CLK_MMC0_OUTPUT 99 | ||
| 129 | #define CLK_MMC0_SAMPLE 100 | ||
| 130 | #define CLK_MMC1 101 | ||
| 131 | #define CLK_MMC1_OUTPUT 102 | ||
| 132 | #define CLK_MMC1_SAMPLE 103 | ||
| 133 | #define CLK_MMC2 104 | ||
| 134 | #define CLK_MMC2_OUTPUT 105 | ||
| 135 | #define CLK_MMC2_SAMPLE 106 | ||
| 136 | #define CLK_MMC3 107 | ||
| 137 | #define CLK_MMC3_OUTPUT 108 | ||
| 138 | #define CLK_MMC3_SAMPLE 109 | ||
| 139 | #define CLK_TS 110 | ||
| 140 | #define CLK_SS 111 | ||
| 141 | #define CLK_SPI0 112 | ||
| 142 | #define CLK_SPI1 113 | ||
| 143 | #define CLK_SPI2 114 | ||
| 144 | #define CLK_PATA 115 | ||
| 145 | #define CLK_IR0 116 | ||
| 146 | #define CLK_IR1 117 | ||
| 147 | #define CLK_I2S0 118 | ||
| 148 | #define CLK_AC97 119 | ||
| 149 | #define CLK_SPDIF 120 | ||
| 150 | #define CLK_KEYPAD 121 | ||
| 151 | #define CLK_SATA 122 | ||
| 152 | #define CLK_USB_OHCI0 123 | ||
| 153 | #define CLK_USB_OHCI1 124 | ||
| 154 | #define CLK_USB_PHY 125 | ||
| 155 | #define CLK_GPS 126 | ||
| 156 | #define CLK_SPI3 127 | ||
| 157 | #define CLK_I2S1 128 | ||
| 158 | #define CLK_I2S2 129 | ||
| 159 | |||
| 160 | /* DRAM Gates */ | ||
| 161 | #define CLK_DRAM_VE 130 | ||
| 162 | #define CLK_DRAM_CSI0 131 | ||
| 163 | #define CLK_DRAM_CSI1 132 | ||
| 164 | #define CLK_DRAM_TS 133 | ||
| 165 | #define CLK_DRAM_TVD 134 | ||
| 166 | #define CLK_DRAM_TVE0 135 | ||
| 167 | #define CLK_DRAM_TVE1 136 | ||
| 168 | #define CLK_DRAM_OUT 137 | ||
| 169 | #define CLK_DRAM_DE_FE1 138 | ||
| 170 | #define CLK_DRAM_DE_FE0 139 | ||
| 171 | #define CLK_DRAM_DE_BE0 140 | ||
| 172 | #define CLK_DRAM_DE_BE1 141 | ||
| 173 | #define CLK_DRAM_MP 142 | ||
| 174 | #define CLK_DRAM_ACE 143 | ||
| 175 | |||
| 176 | /* Display Engine Clocks */ | ||
| 177 | #define CLK_DE_BE0 144 | ||
| 178 | #define CLK_DE_BE1 145 | ||
| 179 | #define CLK_DE_FE0 146 | ||
| 180 | #define CLK_DE_FE1 147 | ||
| 181 | #define CLK_DE_MP 148 | ||
| 182 | #define CLK_TCON0_CH0 149 | ||
| 183 | #define CLK_TCON1_CH0 150 | ||
| 184 | #define CLK_CSI_SCLK 151 | ||
| 185 | #define CLK_TVD_SCLK2 152 | ||
| 186 | #define CLK_TVD 153 | ||
| 187 | #define CLK_TCON0_CH1_SCLK2 154 | ||
| 188 | #define CLK_TCON0_CH1 155 | ||
| 189 | #define CLK_TCON1_CH1_SCLK2 156 | ||
| 190 | #define CLK_TCON1_CH1 157 | ||
| 191 | #define CLK_CSI0 158 | ||
| 192 | #define CLK_CSI1 159 | ||
| 193 | #define CLK_CODEC 160 | ||
| 194 | #define CLK_VE 161 | ||
| 195 | #define CLK_AVS 162 | ||
| 196 | #define CLK_ACE 163 | ||
| 197 | #define CLK_HDMI 164 | ||
| 198 | #define CLK_GPU 165 | ||
| 199 | |||
| 200 | #endif /* _DT_BINDINGS_CLK_SUN4I_A10_H_ */ | ||
diff --git a/include/dt-bindings/clock/sun7i-a20-ccu.h b/include/dt-bindings/clock/sun7i-a20-ccu.h new file mode 100644 index 000000000000..045a5178da0c --- /dev/null +++ b/include/dt-bindings/clock/sun7i-a20-ccu.h | |||
| @@ -0,0 +1,53 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2017 Priit Laes <plaes@plaes.org> | ||
| 3 | * | ||
| 4 | * This file is dual-licensed: you can use it either under the terms | ||
| 5 | * of the GPL or the X11 license, at your option. Note that this dual | ||
| 6 | * licensing only applies to this file, and not this project as a | ||
| 7 | * whole. | ||
| 8 | * | ||
| 9 | * a) This file is free software; you can redistribute it and/or | ||
| 10 | * modify it under the terms of the GNU General Public License as | ||
| 11 | * published by the Free Software Foundation; either version 2 of the | ||
| 12 | * License, or (at your option) any later version. | ||
| 13 | * | ||
| 14 | * This file is distributed in the hope that it will be useful, | ||
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 17 | * GNU General Public License for more details. | ||
| 18 | * | ||
| 19 | * Or, alternatively, | ||
| 20 | * | ||
| 21 | * b) Permission is hereby granted, free of charge, to any person | ||
| 22 | * obtaining a copy of this software and associated documentation | ||
| 23 | * files (the "Software"), to deal in the Software without | ||
| 24 | * restriction, including without limitation the rights to use, | ||
| 25 | * copy, modify, merge, publish, distribute, sublicense, and/or | ||
| 26 | * sell copies of the Software, and to permit persons to whom the | ||
| 27 | * Software is furnished to do so, subject to the following | ||
| 28 | * conditions: | ||
| 29 | * | ||
| 30 | * The above copyright notice and this permission notice shall be | ||
| 31 | * included in all copies or substantial portions of the Software. | ||
| 32 | * | ||
| 33 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
| 34 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES | ||
| 35 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
| 36 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT | ||
| 37 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, | ||
| 38 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR | ||
| 39 | * OTHER DEALINGS IN THE SOFTWARE. | ||
| 40 | */ | ||
| 41 | |||
| 42 | #ifndef _DT_BINDINGS_CLK_SUN7I_A20_H_ | ||
| 43 | #define _DT_BINDINGS_CLK_SUN7I_A20_H_ | ||
| 44 | |||
| 45 | #include <dt-bindings/clock/sun4i-a10-ccu.h> | ||
| 46 | |||
| 47 | #define CLK_MBUS 166 | ||
| 48 | #define CLK_HDMI1_SLOW 167 | ||
| 49 | #define CLK_HDMI1 168 | ||
| 50 | #define CLK_OUT_A 169 | ||
| 51 | #define CLK_OUT_B 170 | ||
| 52 | |||
| 53 | #endif /* _DT_BINDINGS_CLK_SUN7I_A20_H_ */ | ||
diff --git a/include/dt-bindings/clock/sun8i-r40-ccu.h b/include/dt-bindings/clock/sun8i-r40-ccu.h new file mode 100644 index 000000000000..4fa5f69fc297 --- /dev/null +++ b/include/dt-bindings/clock/sun8i-r40-ccu.h | |||
| @@ -0,0 +1,187 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2017 Icenowy Zheng <icenowy@aosc.io> | ||
| 3 | * | ||
| 4 | * This file is dual-licensed: you can use it either under the terms | ||
| 5 | * of the GPL or the X11 license, at your option. Note that this dual | ||
| 6 | * licensing only applies to this file, and not this project as a | ||
| 7 | * whole. | ||
| 8 | * | ||
| 9 | * a) This file is free software; you can redistribute it and/or | ||
| 10 | * modify it under the terms of the GNU General Public License as | ||
| 11 | * published by the Free Software Foundation; either version 2 of the | ||
| 12 | * License, or (at your option) any later version. | ||
| 13 | * | ||
| 14 | * This file is distributed in the hope that it will be useful, | ||
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 17 | * GNU General Public License for more details. | ||
| 18 | * | ||
| 19 | * Or, alternatively, | ||
| 20 | * | ||
| 21 | * b) Permission is hereby granted, free of charge, to any person | ||
| 22 | * obtaining a copy of this software and associated documentation | ||
| 23 | * files (the "Software"), to deal in the Software without | ||
| 24 | * restriction, including without limitation the rights to use, | ||
| 25 | * copy, modify, merge, publish, distribute, sublicense, and/or | ||
| 26 | * sell copies of the Software, and to permit persons to whom the | ||
| 27 | * Software is furnished to do so, subject to the following | ||
| 28 | * conditions: | ||
| 29 | * | ||
| 30 | * The above copyright notice and this permission notice shall be | ||
| 31 | * included in all copies or substantial portions of the Software. | ||
| 32 | * | ||
| 33 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
| 34 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES | ||
| 35 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
| 36 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT | ||
| 37 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, | ||
| 38 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING | ||
| 39 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR | ||
| 40 | * OTHER DEALINGS IN THE SOFTWARE. | ||
| 41 | */ | ||
| 42 | |||
| 43 | #ifndef _DT_BINDINGS_CLK_SUN8I_R40_H_ | ||
| 44 | #define _DT_BINDINGS_CLK_SUN8I_R40_H_ | ||
| 45 | |||
| 46 | #define CLK_CPU 24 | ||
| 47 | |||
| 48 | #define CLK_BUS_MIPI_DSI 29 | ||
| 49 | #define CLK_BUS_CE 30 | ||
| 50 | #define CLK_BUS_DMA 31 | ||
| 51 | #define CLK_BUS_MMC0 32 | ||
| 52 | #define CLK_BUS_MMC1 33 | ||
| 53 | #define CLK_BUS_MMC2 34 | ||
| 54 | #define CLK_BUS_MMC3 35 | ||
| 55 | #define CLK_BUS_NAND 36 | ||
| 56 | #define CLK_BUS_DRAM 37 | ||
| 57 | #define CLK_BUS_EMAC 38 | ||
| 58 | #define CLK_BUS_TS 39 | ||
| 59 | #define CLK_BUS_HSTIMER 40 | ||
| 60 | #define CLK_BUS_SPI0 41 | ||
| 61 | #define CLK_BUS_SPI1 42 | ||
| 62 | #define CLK_BUS_SPI2 43 | ||
| 63 | #define CLK_BUS_SPI3 44 | ||
| 64 | #define CLK_BUS_SATA 45 | ||
| 65 | #define CLK_BUS_OTG 46 | ||
| 66 | #define CLK_BUS_EHCI0 47 | ||
| 67 | #define CLK_BUS_EHCI1 48 | ||
| 68 | #define CLK_BUS_EHCI2 49 | ||
| 69 | #define CLK_BUS_OHCI0 50 | ||
| 70 | #define CLK_BUS_OHCI1 51 | ||
| 71 | #define CLK_BUS_OHCI2 52 | ||
| 72 | #define CLK_BUS_VE 53 | ||
| 73 | #define CLK_BUS_MP 54 | ||
| 74 | #define CLK_BUS_DEINTERLACE 55 | ||
| 75 | #define CLK_BUS_CSI0 56 | ||
| 76 | #define CLK_BUS_CSI1 57 | ||
| 77 | #define CLK_BUS_HDMI1 58 | ||
| 78 | #define CLK_BUS_HDMI0 59 | ||
| 79 | #define CLK_BUS_DE 60 | ||
| 80 | #define CLK_BUS_TVE0 61 | ||
| 81 | #define CLK_BUS_TVE1 62 | ||
| 82 | #define CLK_BUS_TVE_TOP 63 | ||
| 83 | #define CLK_BUS_GMAC 64 | ||
| 84 | #define CLK_BUS_GPU 65 | ||
| 85 | #define CLK_BUS_TVD0 66 | ||
| 86 | #define CLK_BUS_TVD1 67 | ||
| 87 | #define CLK_BUS_TVD2 68 | ||
| 88 | #define CLK_BUS_TVD3 69 | ||
| 89 | #define CLK_BUS_TVD_TOP 70 | ||
| 90 | #define CLK_BUS_TCON_LCD0 71 | ||
| 91 | #define CLK_BUS_TCON_LCD1 72 | ||
| 92 | #define CLK_BUS_TCON_TV0 73 | ||
| 93 | #define CLK_BUS_TCON_TV1 74 | ||
| 94 | #define CLK_BUS_TCON_TOP 75 | ||
| 95 | #define CLK_BUS_CODEC 76 | ||
| 96 | #define CLK_BUS_SPDIF 77 | ||
| 97 | #define CLK_BUS_AC97 78 | ||
| 98 | #define CLK_BUS_PIO 79 | ||
| 99 | #define CLK_BUS_IR0 80 | ||
| 100 | #define CLK_BUS_IR1 81 | ||
| 101 | #define CLK_BUS_THS 82 | ||
| 102 | #define CLK_BUS_KEYPAD 83 | ||
| 103 | #define CLK_BUS_I2S0 84 | ||
| 104 | #define CLK_BUS_I2S1 85 | ||
| 105 | #define CLK_BUS_I2S2 86 | ||
| 106 | #define CLK_BUS_I2C0 87 | ||
| 107 | #define CLK_BUS_I2C1 88 | ||
| 108 | #define CLK_BUS_I2C2 89 | ||
| 109 | #define CLK_BUS_I2C3 90 | ||
| 110 | #define CLK_BUS_CAN 91 | ||
| 111 | #define CLK_BUS_SCR 92 | ||
| 112 | #define CLK_BUS_PS20 93 | ||
| 113 | #define CLK_BUS_PS21 94 | ||
| 114 | #define CLK_BUS_I2C4 95 | ||
| 115 | #define CLK_BUS_UART0 96 | ||
| 116 | #define CLK_BUS_UART1 97 | ||
| 117 | #define CLK_BUS_UART2 98 | ||
| 118 | #define CLK_BUS_UART3 99 | ||
| 119 | #define CLK_BUS_UART4 100 | ||
| 120 | #define CLK_BUS_UART5 101 | ||
| 121 | #define CLK_BUS_UART6 102 | ||
| 122 | #define CLK_BUS_UART7 103 | ||
| 123 | #define CLK_BUS_DBG 104 | ||
| 124 | |||
| 125 | #define CLK_THS 105 | ||
| 126 | #define CLK_NAND 106 | ||
| 127 | #define CLK_MMC0 107 | ||
| 128 | #define CLK_MMC1 108 | ||
| 129 | #define CLK_MMC2 109 | ||
| 130 | #define CLK_MMC3 110 | ||
| 131 | #define CLK_TS 111 | ||
| 132 | #define CLK_CE 112 | ||
| 133 | #define CLK_SPI0 113 | ||
| 134 | #define CLK_SPI1 114 | ||
| 135 | #define CLK_SPI2 115 | ||
| 136 | #define CLK_SPI3 116 | ||
| 137 | #define CLK_I2S0 117 | ||
| 138 | #define CLK_I2S1 118 | ||
| 139 | #define CLK_I2S2 119 | ||
| 140 | #define CLK_AC97 120 | ||
| 141 | #define CLK_SPDIF 121 | ||
| 142 | #define CLK_KEYPAD 122 | ||
| 143 | #define CLK_SATA 123 | ||
| 144 | #define CLK_USB_PHY0 124 | ||
| 145 | #define CLK_USB_PHY1 125 | ||
| 146 | #define CLK_USB_PHY2 126 | ||
| 147 | #define CLK_USB_OHCI0 127 | ||
| 148 | #define CLK_USB_OHCI1 128 | ||
| 149 | #define CLK_USB_OHCI2 129 | ||
| 150 | #define CLK_IR0 130 | ||
| 151 | #define CLK_IR1 131 | ||
| 152 | |||
| 153 | #define CLK_DRAM_VE 133 | ||
| 154 | #define CLK_DRAM_CSI0 134 | ||
| 155 | #define CLK_DRAM_CSI1 135 | ||
| 156 | #define CLK_DRAM_TS 136 | ||
| 157 | #define CLK_DRAM_TVD 137 | ||
| 158 | #define CLK_DRAM_MP 138 | ||
| 159 | #define CLK_DRAM_DEINTERLACE 139 | ||
| 160 | #define CLK_DE 140 | ||
| 161 | #define CLK_MP 141 | ||
| 162 | #define CLK_TCON_LCD0 142 | ||
| 163 | #define CLK_TCON_LCD1 143 | ||
| 164 | #define CLK_TCON_TV0 144 | ||
| 165 | #define CLK_TCON_TV1 145 | ||
| 166 | #define CLK_DEINTERLACE 146 | ||
| 167 | #define CLK_CSI1_MCLK 147 | ||
| 168 | #define CLK_CSI_SCLK 148 | ||
| 169 | #define CLK_CSI0_MCLK 149 | ||
| 170 | #define CLK_VE 150 | ||
| 171 | #define CLK_CODEC 151 | ||
| 172 | #define CLK_AVS 152 | ||
| 173 | #define CLK_HDMI 153 | ||
| 174 | #define CLK_HDMI_SLOW 154 | ||
| 175 | |||
| 176 | #define CLK_DSI_DPHY 156 | ||
| 177 | #define CLK_TVE0 157 | ||
| 178 | #define CLK_TVE1 158 | ||
| 179 | #define CLK_TVD0 159 | ||
| 180 | #define CLK_TVD1 160 | ||
| 181 | #define CLK_TVD2 161 | ||
| 182 | #define CLK_TVD3 162 | ||
| 183 | #define CLK_GPU 163 | ||
| 184 | #define CLK_OUTA 164 | ||
| 185 | #define CLK_OUTB 165 | ||
| 186 | |||
| 187 | #endif /* _DT_BINDINGS_CLK_SUN8I_R40_H_ */ | ||
diff --git a/include/dt-bindings/mfd/stm32h7-rcc.h b/include/dt-bindings/mfd/stm32h7-rcc.h new file mode 100644 index 000000000000..461a8e04453a --- /dev/null +++ b/include/dt-bindings/mfd/stm32h7-rcc.h | |||
| @@ -0,0 +1,136 @@ | |||
| 1 | /* | ||
| 2 | * This header provides constants for the STM32H7 RCC IP | ||
| 3 | */ | ||
| 4 | |||
| 5 | #ifndef _DT_BINDINGS_MFD_STM32H7_RCC_H | ||
| 6 | #define _DT_BINDINGS_MFD_STM32H7_RCC_H | ||
| 7 | |||
| 8 | /* AHB3 */ | ||
| 9 | #define STM32H7_RCC_AHB3_MDMA 0 | ||
| 10 | #define STM32H7_RCC_AHB3_DMA2D 4 | ||
| 11 | #define STM32H7_RCC_AHB3_JPGDEC 5 | ||
| 12 | #define STM32H7_RCC_AHB3_FMC 12 | ||
| 13 | #define STM32H7_RCC_AHB3_QUADSPI 14 | ||
| 14 | #define STM32H7_RCC_AHB3_SDMMC1 16 | ||
| 15 | #define STM32H7_RCC_AHB3_CPU 31 | ||
| 16 | |||
| 17 | #define STM32H7_AHB3_RESET(bit) (STM32H7_RCC_AHB3_##bit + (0x7C * 8)) | ||
| 18 | |||
| 19 | /* AHB1 */ | ||
| 20 | #define STM32H7_RCC_AHB1_DMA1 0 | ||
| 21 | #define STM32H7_RCC_AHB1_DMA2 1 | ||
| 22 | #define STM32H7_RCC_AHB1_ADC12 5 | ||
| 23 | #define STM32H7_RCC_AHB1_ART 14 | ||
| 24 | #define STM32H7_RCC_AHB1_ETH1MAC 15 | ||
| 25 | #define STM32H7_RCC_AHB1_USB1OTG 25 | ||
| 26 | #define STM32H7_RCC_AHB1_USB2OTG 27 | ||
| 27 | |||
| 28 | #define STM32H7_AHB1_RESET(bit) (STM32H7_RCC_AHB1_##bit + (0x80 * 8)) | ||
| 29 | |||
| 30 | /* AHB2 */ | ||
| 31 | #define STM32H7_RCC_AHB2_CAMITF 0 | ||
| 32 | #define STM32H7_RCC_AHB2_CRYPT 4 | ||
| 33 | #define STM32H7_RCC_AHB2_HASH 5 | ||
| 34 | #define STM32H7_RCC_AHB2_RNG 6 | ||
| 35 | #define STM32H7_RCC_AHB2_SDMMC2 9 | ||
| 36 | |||
| 37 | #define STM32H7_AHB2_RESET(bit) (STM32H7_RCC_AHB2_##bit + (0x84 * 8)) | ||
| 38 | |||
| 39 | /* AHB4 */ | ||
| 40 | #define STM32H7_RCC_AHB4_GPIOA 0 | ||
| 41 | #define STM32H7_RCC_AHB4_GPIOB 1 | ||
| 42 | #define STM32H7_RCC_AHB4_GPIOC 2 | ||
| 43 | #define STM32H7_RCC_AHB4_GPIOD 3 | ||
| 44 | #define STM32H7_RCC_AHB4_GPIOE 4 | ||
| 45 | #define STM32H7_RCC_AHB4_GPIOF 5 | ||
| 46 | #define STM32H7_RCC_AHB4_GPIOG 6 | ||
| 47 | #define STM32H7_RCC_AHB4_GPIOH 7 | ||
| 48 | #define STM32H7_RCC_AHB4_GPIOI 8 | ||
| 49 | #define STM32H7_RCC_AHB4_GPIOJ 9 | ||
| 50 | #define STM32H7_RCC_AHB4_GPIOK 10 | ||
| 51 | #define STM32H7_RCC_AHB4_CRC 19 | ||
| 52 | #define STM32H7_RCC_AHB4_BDMA 21 | ||
| 53 | #define STM32H7_RCC_AHB4_ADC3 24 | ||
| 54 | #define STM32H7_RCC_AHB4_HSEM 25 | ||
| 55 | |||
| 56 | #define STM32H7_AHB4_RESET(bit) (STM32H7_RCC_AHB4_##bit + (0x88 * 8)) | ||
| 57 | |||
| 58 | /* APB3 */ | ||
| 59 | #define STM32H7_RCC_APB3_LTDC 3 | ||
| 60 | #define STM32H7_RCC_APB3_DSI 4 | ||
| 61 | |||
| 62 | #define STM32H7_APB3_RESET(bit) (STM32H7_RCC_APB3_##bit + (0x8C * 8)) | ||
| 63 | |||
| 64 | /* APB1L */ | ||
| 65 | #define STM32H7_RCC_APB1L_TIM2 0 | ||
| 66 | #define STM32H7_RCC_APB1L_TIM3 1 | ||
| 67 | #define STM32H7_RCC_APB1L_TIM4 2 | ||
| 68 | #define STM32H7_RCC_APB1L_TIM5 3 | ||
| 69 | #define STM32H7_RCC_APB1L_TIM6 4 | ||
| 70 | #define STM32H7_RCC_APB1L_TIM7 5 | ||
| 71 | #define STM32H7_RCC_APB1L_TIM12 6 | ||
| 72 | #define STM32H7_RCC_APB1L_TIM13 7 | ||
| 73 | #define STM32H7_RCC_APB1L_TIM14 8 | ||
| 74 | #define STM32H7_RCC_APB1L_LPTIM1 9 | ||
| 75 | #define STM32H7_RCC_APB1L_SPI2 14 | ||
| 76 | #define STM32H7_RCC_APB1L_SPI3 15 | ||
| 77 | #define STM32H7_RCC_APB1L_SPDIF_RX 16 | ||
| 78 | #define STM32H7_RCC_APB1L_USART2 17 | ||
| 79 | #define STM32H7_RCC_APB1L_USART3 18 | ||
| 80 | #define STM32H7_RCC_APB1L_UART4 19 | ||
| 81 | #define STM32H7_RCC_APB1L_UART5 20 | ||
| 82 | #define STM32H7_RCC_APB1L_I2C1 21 | ||
| 83 | #define STM32H7_RCC_APB1L_I2C2 22 | ||
| 84 | #define STM32H7_RCC_APB1L_I2C3 23 | ||
| 85 | #define STM32H7_RCC_APB1L_HDMICEC 27 | ||
| 86 | #define STM32H7_RCC_APB1L_DAC12 29 | ||
| 87 | #define STM32H7_RCC_APB1L_USART7 30 | ||
| 88 | #define STM32H7_RCC_APB1L_USART8 31 | ||
| 89 | |||
| 90 | #define STM32H7_APB1L_RESET(bit) (STM32H7_RCC_APB1L_##bit + (0x90 * 8)) | ||
| 91 | |||
| 92 | /* APB1H */ | ||
| 93 | #define STM32H7_RCC_APB1H_CRS 1 | ||
| 94 | #define STM32H7_RCC_APB1H_SWP 2 | ||
| 95 | #define STM32H7_RCC_APB1H_OPAMP 4 | ||
| 96 | #define STM32H7_RCC_APB1H_MDIOS 5 | ||
| 97 | #define STM32H7_RCC_APB1H_FDCAN 8 | ||
| 98 | |||
| 99 | #define STM32H7_APB1H_RESET(bit) (STM32H7_RCC_APB1H_##bit + (0x94 * 8)) | ||
| 100 | |||
| 101 | /* APB2 */ | ||
| 102 | #define STM32H7_RCC_APB2_TIM1 0 | ||
| 103 | #define STM32H7_RCC_APB2_TIM8 1 | ||
| 104 | #define STM32H7_RCC_APB2_USART1 4 | ||
| 105 | #define STM32H7_RCC_APB2_USART6 5 | ||
| 106 | #define STM32H7_RCC_APB2_SPI1 12 | ||
| 107 | #define STM32H7_RCC_APB2_SPI4 13 | ||
| 108 | #define STM32H7_RCC_APB2_TIM15 16 | ||
| 109 | #define STM32H7_RCC_APB2_TIM16 17 | ||
| 110 | #define STM32H7_RCC_APB2_TIM17 18 | ||
| 111 | #define STM32H7_RCC_APB2_SPI5 20 | ||
| 112 | #define STM32H7_RCC_APB2_SAI1 22 | ||
| 113 | #define STM32H7_RCC_APB2_SAI2 23 | ||
| 114 | #define STM32H7_RCC_APB2_SAI3 24 | ||
| 115 | #define STM32H7_RCC_APB2_DFSDM1 28 | ||
| 116 | #define STM32H7_RCC_APB2_HRTIM 29 | ||
| 117 | |||
| 118 | #define STM32H7_APB2_RESET(bit) (STM32H7_RCC_APB2_##bit + (0x98 * 8)) | ||
| 119 | |||
| 120 | /* APB4 */ | ||
| 121 | #define STM32H7_RCC_APB4_SYSCFG 1 | ||
| 122 | #define STM32H7_RCC_APB4_LPUART1 3 | ||
| 123 | #define STM32H7_RCC_APB4_SPI6 5 | ||
| 124 | #define STM32H7_RCC_APB4_I2C4 7 | ||
| 125 | #define STM32H7_RCC_APB4_LPTIM2 9 | ||
| 126 | #define STM32H7_RCC_APB4_LPTIM3 10 | ||
| 127 | #define STM32H7_RCC_APB4_LPTIM4 11 | ||
| 128 | #define STM32H7_RCC_APB4_LPTIM5 12 | ||
| 129 | #define STM32H7_RCC_APB4_COMP12 14 | ||
| 130 | #define STM32H7_RCC_APB4_VREF 15 | ||
| 131 | #define STM32H7_RCC_APB4_SAI4 21 | ||
| 132 | #define STM32H7_RCC_APB4_TMPSENS 26 | ||
| 133 | |||
| 134 | #define STM32H7_APB4_RESET(bit) (STM32H7_RCC_APB4_##bit + (0x9C * 8)) | ||
| 135 | |||
| 136 | #endif /* _DT_BINDINGS_MFD_STM32H7_RCC_H */ | ||
diff --git a/include/dt-bindings/reset/sun4i-a10-ccu.h b/include/dt-bindings/reset/sun4i-a10-ccu.h new file mode 100644 index 000000000000..5f4480bedc8a --- /dev/null +++ b/include/dt-bindings/reset/sun4i-a10-ccu.h | |||
| @@ -0,0 +1,69 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2017 Priit Laes <plaes@plaes.org> | ||
| 3 | * | ||
| 4 | * This file is dual-licensed: you can use it either under the terms | ||
| 5 | * of the GPL or the X11 license, at your option. Note that this dual | ||
| 6 | * licensing only applies to this file, and not this project as a | ||
| 7 | * whole. | ||
| 8 | * | ||
| 9 | * a) This file is free software; you can redistribute it and/or | ||
| 10 | * modify it under the terms of the GNU General Public License as | ||
| 11 | * published by the Free Software Foundation; either version 2 of the | ||
| 12 | * License, or (at your option) any later version. | ||
| 13 | * | ||
| 14 | * This file is distributed in the hope that it will be useful, | ||
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 17 | * GNU General Public License for more details. | ||
| 18 | * | ||
| 19 | * Or, alternatively, | ||
| 20 | * | ||
| 21 | * b) Permission is hereby granted, free of charge, to any person | ||
| 22 | * obtaining a copy of this software and associated documentation | ||
| 23 | * files (the "Software"), to deal in the Software without | ||
| 24 | * restriction, including without limitation the rights to use, | ||
| 25 | * copy, modify, merge, publish, distribute, sublicense, and/or | ||
| 26 | * sell copies of the Software, and to permit persons to whom the | ||
| 27 | * Software is furnished to do so, subject to the following | ||
| 28 | * conditions: | ||
| 29 | * | ||
| 30 | * The above copyright notice and this permission notice shall be | ||
| 31 | * included in all copies or substantial portions of the Software. | ||
| 32 | * | ||
| 33 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
| 34 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES | ||
| 35 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
| 36 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT | ||
| 37 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, | ||
| 38 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING | ||
| 39 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR | ||
| 40 | * OTHER DEALINGS IN THE SOFTWARE. | ||
| 41 | */ | ||
| 42 | |||
| 43 | #ifndef _DT_BINDINGS_RST_SUN4I_A10_H | ||
| 44 | #define _DT_BINDINGS_RST_SUN4I_A10_H | ||
| 45 | |||
| 46 | #define RST_USB_PHY0 1 | ||
| 47 | #define RST_USB_PHY1 2 | ||
| 48 | #define RST_USB_PHY2 3 | ||
| 49 | #define RST_GPS 4 | ||
| 50 | #define RST_DE_BE0 5 | ||
| 51 | #define RST_DE_BE1 6 | ||
| 52 | #define RST_DE_FE0 7 | ||
| 53 | #define RST_DE_FE1 8 | ||
| 54 | #define RST_DE_MP 9 | ||
| 55 | #define RST_TVE0 10 | ||
| 56 | #define RST_TCON0 11 | ||
| 57 | #define RST_TVE1 12 | ||
| 58 | #define RST_TCON1 13 | ||
| 59 | #define RST_CSI0 14 | ||
| 60 | #define RST_CSI1 15 | ||
| 61 | #define RST_VE 16 | ||
| 62 | #define RST_ACE 17 | ||
| 63 | #define RST_LVDS 18 | ||
| 64 | #define RST_GPU 19 | ||
| 65 | #define RST_HDMI_H 20 | ||
| 66 | #define RST_HDMI_SYS 21 | ||
| 67 | #define RST_HDMI_AUDIO_DMA 22 | ||
| 68 | |||
| 69 | #endif /* DT_BINDINGS_RST_SUN4I_A10_H */ | ||
diff --git a/include/dt-bindings/reset/sun8i-r40-ccu.h b/include/dt-bindings/reset/sun8i-r40-ccu.h new file mode 100644 index 000000000000..c5ebcf6672e4 --- /dev/null +++ b/include/dt-bindings/reset/sun8i-r40-ccu.h | |||
| @@ -0,0 +1,130 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2017 Icenowy Zheng <icenowy@aosc.io> | ||
| 3 | * | ||
| 4 | * This file is dual-licensed: you can use it either under the terms | ||
| 5 | * of the GPL or the X11 license, at your option. Note that this dual | ||
| 6 | * licensing only applies to this file, and not this project as a | ||
| 7 | * whole. | ||
| 8 | * | ||
| 9 | * a) This file is free software; you can redistribute it and/or | ||
| 10 | * modify it under the terms of the GNU General Public License as | ||
| 11 | * published by the Free Software Foundation; either version 2 of the | ||
| 12 | * License, or (at your option) any later version. | ||
| 13 | * | ||
| 14 | * This file is distributed in the hope that it will be useful, | ||
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 17 | * GNU General Public License for more details. | ||
| 18 | * | ||
| 19 | * Or, alternatively, | ||
| 20 | * | ||
| 21 | * b) Permission is hereby granted, free of charge, to any person | ||
| 22 | * obtaining a copy of this software and associated documentation | ||
| 23 | * files (the "Software"), to deal in the Software without | ||
| 24 | * restriction, including without limitation the rights to use, | ||
| 25 | * copy, modify, merge, publish, distribute, sublicense, and/or | ||
| 26 | * sell copies of the Software, and to permit persons to whom the | ||
| 27 | * Software is furnished to do so, subject to the following | ||
| 28 | * conditions: | ||
| 29 | * | ||
| 30 | * The above copyright notice and this permission notice shall be | ||
| 31 | * included in all copies or substantial portions of the Software. | ||
| 32 | * | ||
| 33 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
| 34 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES | ||
| 35 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
| 36 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT | ||
| 37 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, | ||
| 38 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING | ||
| 39 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR | ||
| 40 | * OTHER DEALINGS IN THE SOFTWARE. | ||
| 41 | */ | ||
| 42 | |||
| 43 | #ifndef _DT_BINDINGS_RST_SUN8I_R40_H_ | ||
| 44 | #define _DT_BINDINGS_RST_SUN8I_R40_H_ | ||
| 45 | |||
| 46 | #define RST_USB_PHY0 0 | ||
| 47 | #define RST_USB_PHY1 1 | ||
| 48 | #define RST_USB_PHY2 2 | ||
| 49 | |||
| 50 | #define RST_DRAM 3 | ||
| 51 | #define RST_MBUS 4 | ||
| 52 | |||
| 53 | #define RST_BUS_MIPI_DSI 5 | ||
| 54 | #define RST_BUS_CE 6 | ||
| 55 | #define RST_BUS_DMA 7 | ||
| 56 | #define RST_BUS_MMC0 8 | ||
| 57 | #define RST_BUS_MMC1 9 | ||
| 58 | #define RST_BUS_MMC2 10 | ||
| 59 | #define RST_BUS_MMC3 11 | ||
| 60 | #define RST_BUS_NAND 12 | ||
| 61 | #define RST_BUS_DRAM 13 | ||
| 62 | #define RST_BUS_EMAC 14 | ||
| 63 | #define RST_BUS_TS 15 | ||
| 64 | #define RST_BUS_HSTIMER 16 | ||
| 65 | #define RST_BUS_SPI0 17 | ||
| 66 | #define RST_BUS_SPI1 18 | ||
| 67 | #define RST_BUS_SPI2 19 | ||
| 68 | #define RST_BUS_SPI3 20 | ||
| 69 | #define RST_BUS_SATA 21 | ||
| 70 | #define RST_BUS_OTG 22 | ||
| 71 | #define RST_BUS_EHCI0 23 | ||
| 72 | #define RST_BUS_EHCI1 24 | ||
| 73 | #define RST_BUS_EHCI2 25 | ||
| 74 | #define RST_BUS_OHCI0 26 | ||
| 75 | #define RST_BUS_OHCI1 27 | ||
| 76 | #define RST_BUS_OHCI2 28 | ||
| 77 | #define RST_BUS_VE 29 | ||
| 78 | #define RST_BUS_MP 30 | ||
| 79 | #define RST_BUS_DEINTERLACE 31 | ||
| 80 | #define RST_BUS_CSI0 32 | ||
| 81 | #define RST_BUS_CSI1 33 | ||
| 82 | #define RST_BUS_HDMI0 34 | ||
| 83 | #define RST_BUS_HDMI1 35 | ||
| 84 | #define RST_BUS_DE 36 | ||
| 85 | #define RST_BUS_TVE0 37 | ||
| 86 | #define RST_BUS_TVE1 38 | ||
| 87 | #define RST_BUS_TVE_TOP 39 | ||
| 88 | #define RST_BUS_GMAC 40 | ||
| 89 | #define RST_BUS_GPU 41 | ||
| 90 | #define RST_BUS_TVD0 42 | ||
| 91 | #define RST_BUS_TVD1 43 | ||
| 92 | #define RST_BUS_TVD2 44 | ||
| 93 | #define RST_BUS_TVD3 45 | ||
| 94 | #define RST_BUS_TVD_TOP 46 | ||
| 95 | #define RST_BUS_TCON_LCD0 47 | ||
| 96 | #define RST_BUS_TCON_LCD1 48 | ||
| 97 | #define RST_BUS_TCON_TV0 49 | ||
| 98 | #define RST_BUS_TCON_TV1 50 | ||
| 99 | #define RST_BUS_TCON_TOP 51 | ||
| 100 | #define RST_BUS_DBG 52 | ||
| 101 | #define RST_BUS_LVDS 53 | ||
| 102 | #define RST_BUS_CODEC 54 | ||
| 103 | #define RST_BUS_SPDIF 55 | ||
| 104 | #define RST_BUS_AC97 56 | ||
| 105 | #define RST_BUS_IR0 57 | ||
| 106 | #define RST_BUS_IR1 58 | ||
| 107 | #define RST_BUS_THS 59 | ||
| 108 | #define RST_BUS_KEYPAD 60 | ||
| 109 | #define RST_BUS_I2S0 61 | ||
| 110 | #define RST_BUS_I2S1 62 | ||
| 111 | #define RST_BUS_I2S2 63 | ||
| 112 | #define RST_BUS_I2C0 64 | ||
| 113 | #define RST_BUS_I2C1 65 | ||
| 114 | #define RST_BUS_I2C2 66 | ||
| 115 | #define RST_BUS_I2C3 67 | ||
| 116 | #define RST_BUS_CAN 68 | ||
| 117 | #define RST_BUS_SCR 69 | ||
| 118 | #define RST_BUS_PS20 70 | ||
| 119 | #define RST_BUS_PS21 71 | ||
| 120 | #define RST_BUS_I2C4 72 | ||
| 121 | #define RST_BUS_UART0 73 | ||
| 122 | #define RST_BUS_UART1 74 | ||
| 123 | #define RST_BUS_UART2 75 | ||
| 124 | #define RST_BUS_UART3 76 | ||
| 125 | #define RST_BUS_UART4 77 | ||
| 126 | #define RST_BUS_UART5 78 | ||
| 127 | #define RST_BUS_UART6 79 | ||
| 128 | #define RST_BUS_UART7 80 | ||
| 129 | |||
| 130 | #endif /* _DT_BINDINGS_RST_SUN8I_R40_H_ */ | ||
diff --git a/include/linux/clk-provider.h b/include/linux/clk-provider.h index c59c62571e4f..5100ec1b5d55 100644 --- a/include/linux/clk-provider.h +++ b/include/linux/clk-provider.h | |||
| @@ -343,6 +343,7 @@ struct clk_hw *clk_hw_register_gate(struct device *dev, const char *name, | |||
| 343 | u8 clk_gate_flags, spinlock_t *lock); | 343 | u8 clk_gate_flags, spinlock_t *lock); |
| 344 | void clk_unregister_gate(struct clk *clk); | 344 | void clk_unregister_gate(struct clk *clk); |
| 345 | void clk_hw_unregister_gate(struct clk_hw *hw); | 345 | void clk_hw_unregister_gate(struct clk_hw *hw); |
| 346 | int clk_gate_is_enabled(struct clk_hw *hw); | ||
| 346 | 347 | ||
| 347 | struct clk_div_table { | 348 | struct clk_div_table { |
| 348 | unsigned int val; | 349 | unsigned int val; |
| @@ -565,6 +566,9 @@ struct clk_fractional_divider { | |||
| 565 | u8 nwidth; | 566 | u8 nwidth; |
| 566 | u32 nmask; | 567 | u32 nmask; |
| 567 | u8 flags; | 568 | u8 flags; |
| 569 | void (*approximation)(struct clk_hw *hw, | ||
| 570 | unsigned long rate, unsigned long *parent_rate, | ||
| 571 | unsigned long *m, unsigned long *n); | ||
| 568 | spinlock_t *lock; | 572 | spinlock_t *lock; |
| 569 | }; | 573 | }; |
| 570 | 574 | ||
diff --git a/include/linux/clk/at91_pmc.h b/include/linux/clk/at91_pmc.h index 17f413bbbedf..6aca5ce8a99a 100644 --- a/include/linux/clk/at91_pmc.h +++ b/include/linux/clk/at91_pmc.h | |||
| @@ -185,4 +185,29 @@ | |||
| 185 | #define AT91_PMC_PCR_EN (0x1 << 28) /* Enable */ | 185 | #define AT91_PMC_PCR_EN (0x1 << 28) /* Enable */ |
| 186 | #define AT91_PMC_PCR_GCKEN (0x1 << 29) /* GCK Enable */ | 186 | #define AT91_PMC_PCR_GCKEN (0x1 << 29) /* GCK Enable */ |
| 187 | 187 | ||
| 188 | #define AT91_PMC_AUDIO_PLL0 0x14c | ||
| 189 | #define AT91_PMC_AUDIO_PLL_PLLEN (1 << 0) | ||
| 190 | #define AT91_PMC_AUDIO_PLL_PADEN (1 << 1) | ||
| 191 | #define AT91_PMC_AUDIO_PLL_PMCEN (1 << 2) | ||
| 192 | #define AT91_PMC_AUDIO_PLL_RESETN (1 << 3) | ||
| 193 | #define AT91_PMC_AUDIO_PLL_ND_OFFSET 8 | ||
| 194 | #define AT91_PMC_AUDIO_PLL_ND_MASK (0x7f << AT91_PMC_AUDIO_PLL_ND_OFFSET) | ||
| 195 | #define AT91_PMC_AUDIO_PLL_ND(n) ((n) << AT91_PMC_AUDIO_PLL_ND_OFFSET) | ||
| 196 | #define AT91_PMC_AUDIO_PLL_QDPMC_OFFSET 16 | ||
| 197 | #define AT91_PMC_AUDIO_PLL_QDPMC_MASK (0x7f << AT91_PMC_AUDIO_PLL_QDPMC_OFFSET) | ||
| 198 | #define AT91_PMC_AUDIO_PLL_QDPMC(n) ((n) << AT91_PMC_AUDIO_PLL_QDPMC_OFFSET) | ||
| 199 | |||
| 200 | #define AT91_PMC_AUDIO_PLL1 0x150 | ||
| 201 | #define AT91_PMC_AUDIO_PLL_FRACR_MASK 0x3fffff | ||
| 202 | #define AT91_PMC_AUDIO_PLL_QDPAD_OFFSET 24 | ||
| 203 | #define AT91_PMC_AUDIO_PLL_QDPAD_MASK (0x7f << AT91_PMC_AUDIO_PLL_QDPAD_OFFSET) | ||
| 204 | #define AT91_PMC_AUDIO_PLL_QDPAD(n) ((n) << AT91_PMC_AUDIO_PLL_QDPAD_OFFSET) | ||
| 205 | #define AT91_PMC_AUDIO_PLL_QDPAD_DIV_OFFSET AT91_PMC_AUDIO_PLL_QDPAD_OFFSET | ||
| 206 | #define AT91_PMC_AUDIO_PLL_QDPAD_DIV_MASK (0x3 << AT91_PMC_AUDIO_PLL_QDPAD_DIV_OFFSET) | ||
| 207 | #define AT91_PMC_AUDIO_PLL_QDPAD_DIV(n) ((n) << AT91_PMC_AUDIO_PLL_QDPAD_DIV_OFFSET) | ||
| 208 | #define AT91_PMC_AUDIO_PLL_QDPAD_EXTDIV_OFFSET 26 | ||
| 209 | #define AT91_PMC_AUDIO_PLL_QDPAD_EXTDIV_MAX 0x1f | ||
| 210 | #define AT91_PMC_AUDIO_PLL_QDPAD_EXTDIV_MASK (AT91_PMC_AUDIO_PLL_QDPAD_EXTDIV_MAX << AT91_PMC_AUDIO_PLL_QDPAD_EXTDIV_OFFSET) | ||
| 211 | #define AT91_PMC_AUDIO_PLL_QDPAD_EXTDIV(n) ((n) << AT91_PMC_AUDIO_PLL_QDPAD_EXTDIV_OFFSET) | ||
| 212 | |||
| 188 | #endif | 213 | #endif |
