mirror of
https://github.com/torvalds/linux.git
synced 2024-12-24 11:51:27 +00:00
b7d950b928
Baikal-T1 is supposed to be supplied with a high-frequency external oscillator. But in order to create signals suitable for each IP-block embedded into the SoC the oscillator output is primarily connected to a set of CCU PLLs. There are five of them to create clocks for the MIPS P5600 cores, an embedded DDR controller, SATA, Ethernet and PCIe domains. The last three domains though named by the biggest system interfaces in fact include nearly all of the rest SoC peripherals. Each of the PLLs is based on True Circuits TSMC CLN28HPM IP-core with an interface wrapper (so called safe PLL' clocks switcher) to simplify the PLL configuration procedure. This driver creates the of-based hardware clocks to use them then in the corresponding subsystems. In order to simplify the driver code we split the functionality up into the PLLs clocks operations and hardware clocks declaration/registration procedures. Even though the PLLs are based on the same IP-core, they may have some differences. In particular, some CCU PLLs support the output clock change without gating them (like CPU or PCIe PLLs), while the others don't, some CCU PLLs are critical and aren't supposed to be gated. In order to cover all of these cases the hardware clocks driver is designed with an info-descriptor pattern. So there are special static descriptors declared for each PLL, which is then used to create a hardware clock with proper operations. Additionally debugfs-files are provided for each PLL' field to make sure the implemented rate-PLLs-dividers calculation algorithm is correct. Signed-off-by: Serge Semin <Sergey.Semin@baikalelectronics.ru> Cc: Alexey Malahov <Alexey.Malahov@baikalelectronics.ru> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Rob Herring <robh+dt@kernel.org> Cc: linux-mips@vger.kernel.org Cc: devicetree@vger.kernel.org Link: https://lore.kernel.org/r/20200526222056.18072-4-Sergey.Semin@baikalelectronics.ru [sboyd@kernel.org: Silence sparse warning about initializing structs with NULL vs. integer] Signed-off-by: Stephen Boyd <sboyd@kernel.org>
125 lines
4.9 KiB
Makefile
125 lines
4.9 KiB
Makefile
# SPDX-License-Identifier: GPL-2.0
|
|
# common clock types
|
|
obj-$(CONFIG_HAVE_CLK) += clk-devres.o clk-bulk.o
|
|
obj-$(CONFIG_CLKDEV_LOOKUP) += clkdev.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk-divider.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk-fixed-factor.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk-fixed-rate.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk-gate.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk-multiplier.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk-mux.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk-composite.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk-fractional-divider.o
|
|
obj-$(CONFIG_COMMON_CLK) += clk-gpio.o
|
|
ifeq ($(CONFIG_OF), y)
|
|
obj-$(CONFIG_COMMON_CLK) += clk-conf.o
|
|
endif
|
|
|
|
# hardware specific clock types
|
|
# please keep this section sorted lexicographically by file path name
|
|
obj-$(CONFIG_MACH_ASM9260) += clk-asm9260.o
|
|
obj-$(CONFIG_COMMON_CLK_AXI_CLKGEN) += clk-axi-clkgen.o
|
|
obj-$(CONFIG_ARCH_AXXIA) += clk-axm5516.o
|
|
obj-$(CONFIG_COMMON_CLK_BD718XX) += clk-bd718x7.o
|
|
obj-$(CONFIG_COMMON_CLK_BM1880) += clk-bm1880.o
|
|
obj-$(CONFIG_COMMON_CLK_CDCE706) += clk-cdce706.o
|
|
obj-$(CONFIG_COMMON_CLK_CDCE925) += clk-cdce925.o
|
|
obj-$(CONFIG_ARCH_CLPS711X) += clk-clps711x.o
|
|
obj-$(CONFIG_COMMON_CLK_CS2000_CP) += clk-cs2000-cp.o
|
|
obj-$(CONFIG_ARCH_EFM32) += clk-efm32gg.o
|
|
obj-$(CONFIG_COMMON_CLK_FIXED_MMIO) += clk-fixed-mmio.o
|
|
obj-$(CONFIG_COMMON_CLK_FSL_SAI) += clk-fsl-sai.o
|
|
obj-$(CONFIG_COMMON_CLK_GEMINI) += clk-gemini.o
|
|
obj-$(CONFIG_COMMON_CLK_ASPEED) += clk-aspeed.o
|
|
obj-$(CONFIG_MACH_ASPEED_G6) += clk-ast2600.o
|
|
obj-$(CONFIG_ARCH_HIGHBANK) += clk-highbank.o
|
|
obj-$(CONFIG_CLK_HSDK) += clk-hsdk-pll.o
|
|
obj-$(CONFIG_COMMON_CLK_LOCHNAGAR) += clk-lochnagar.o
|
|
obj-$(CONFIG_COMMON_CLK_MAX77686) += clk-max77686.o
|
|
obj-$(CONFIG_COMMON_CLK_MAX9485) += clk-max9485.o
|
|
obj-$(CONFIG_ARCH_MILBEAUT_M10V) += clk-milbeaut.o
|
|
obj-$(CONFIG_ARCH_MOXART) += clk-moxart.o
|
|
obj-$(CONFIG_ARCH_NOMADIK) += clk-nomadik.o
|
|
obj-$(CONFIG_ARCH_NPCM7XX) += clk-npcm7xx.o
|
|
obj-$(CONFIG_ARCH_NSPIRE) += clk-nspire.o
|
|
obj-$(CONFIG_COMMON_CLK_OXNAS) += clk-oxnas.o
|
|
obj-$(CONFIG_COMMON_CLK_PALMAS) += clk-palmas.o
|
|
obj-$(CONFIG_CLK_LS1028A_PLLDIG) += clk-plldig.o
|
|
obj-$(CONFIG_COMMON_CLK_PWM) += clk-pwm.o
|
|
obj-$(CONFIG_CLK_QORIQ) += clk-qoriq.o
|
|
obj-$(CONFIG_COMMON_CLK_RK808) += clk-rk808.o
|
|
obj-$(CONFIG_COMMON_CLK_HI655X) += clk-hi655x.o
|
|
obj-$(CONFIG_COMMON_CLK_S2MPS11) += clk-s2mps11.o
|
|
obj-$(CONFIG_COMMON_CLK_SCMI) += clk-scmi.o
|
|
obj-$(CONFIG_COMMON_CLK_SCPI) += clk-scpi.o
|
|
obj-$(CONFIG_COMMON_CLK_SI5341) += clk-si5341.o
|
|
obj-$(CONFIG_COMMON_CLK_SI5351) += clk-si5351.o
|
|
obj-$(CONFIG_COMMON_CLK_SI514) += clk-si514.o
|
|
obj-$(CONFIG_COMMON_CLK_SI544) += clk-si544.o
|
|
obj-$(CONFIG_COMMON_CLK_SI570) += clk-si570.o
|
|
obj-$(CONFIG_COMMON_CLK_STM32F) += clk-stm32f4.o
|
|
obj-$(CONFIG_COMMON_CLK_STM32H7) += clk-stm32h7.o
|
|
obj-$(CONFIG_COMMON_CLK_STM32MP157) += clk-stm32mp1.o
|
|
obj-$(CONFIG_ARCH_TANGO) += clk-tango4.o
|
|
obj-$(CONFIG_CLK_TWL6040) += clk-twl6040.o
|
|
obj-$(CONFIG_ARCH_U300) += clk-u300.o
|
|
obj-$(CONFIG_ARCH_VT8500) += clk-vt8500.o
|
|
obj-$(CONFIG_COMMON_CLK_VC5) += clk-versaclock5.o
|
|
obj-$(CONFIG_COMMON_CLK_WM831X) += clk-wm831x.o
|
|
obj-$(CONFIG_COMMON_CLK_XGENE) += clk-xgene.o
|
|
|
|
# please keep this section sorted lexicographically by directory path name
|
|
obj-y += actions/
|
|
obj-y += analogbits/
|
|
obj-$(CONFIG_COMMON_CLK_AT91) += at91/
|
|
obj-$(CONFIG_ARCH_ARTPEC) += axis/
|
|
obj-$(CONFIG_ARC_PLAT_AXS10X) += axs10x/
|
|
obj-$(CONFIG_CLK_BAIKAL_T1) += baikal-t1/
|
|
obj-y += bcm/
|
|
obj-$(CONFIG_ARCH_BERLIN) += berlin/
|
|
obj-$(CONFIG_ARCH_DAVINCI) += davinci/
|
|
obj-$(CONFIG_H8300) += h8300/
|
|
obj-$(CONFIG_ARCH_HISI) += hisilicon/
|
|
obj-y += imgtec/
|
|
obj-y += imx/
|
|
obj-y += ingenic/
|
|
obj-$(CONFIG_ARCH_K3) += keystone/
|
|
obj-$(CONFIG_ARCH_KEYSTONE) += keystone/
|
|
obj-$(CONFIG_MACH_LOONGSON32) += loongson1/
|
|
obj-y += mediatek/
|
|
obj-$(CONFIG_ARCH_MESON) += meson/
|
|
obj-$(CONFIG_MACH_PIC32) += microchip/
|
|
ifeq ($(CONFIG_COMMON_CLK), y)
|
|
obj-$(CONFIG_ARCH_MMP) += mmp/
|
|
endif
|
|
obj-y += mvebu/
|
|
obj-$(CONFIG_ARCH_MXS) += mxs/
|
|
obj-$(CONFIG_COMMON_CLK_NXP) += nxp/
|
|
obj-$(CONFIG_MACH_PISTACHIO) += pistachio/
|
|
obj-$(CONFIG_COMMON_CLK_PXA) += pxa/
|
|
obj-$(CONFIG_COMMON_CLK_QCOM) += qcom/
|
|
obj-y += renesas/
|
|
obj-$(CONFIG_ARCH_ROCKCHIP) += rockchip/
|
|
obj-$(CONFIG_COMMON_CLK_SAMSUNG) += samsung/
|
|
obj-$(CONFIG_CLK_SIFIVE) += sifive/
|
|
obj-$(CONFIG_ARCH_SIRF) += sirf/
|
|
obj-$(CONFIG_ARCH_SOCFPGA) += socfpga/
|
|
obj-$(CONFIG_PLAT_SPEAR) += spear/
|
|
obj-$(CONFIG_ARCH_SPRD) += sprd/
|
|
obj-$(CONFIG_ARCH_STI) += st/
|
|
obj-$(CONFIG_ARCH_STRATIX10) += socfpga/
|
|
obj-$(CONFIG_ARCH_SUNXI) += sunxi/
|
|
obj-$(CONFIG_SUNXI_CCU) += sunxi-ng/
|
|
obj-$(CONFIG_ARCH_TEGRA) += tegra/
|
|
obj-y += ti/
|
|
obj-$(CONFIG_CLK_UNIPHIER) += uniphier/
|
|
obj-$(CONFIG_ARCH_U8500) += ux500/
|
|
obj-$(CONFIG_COMMON_CLK_VERSATILE) += versatile/
|
|
ifeq ($(CONFIG_COMMON_CLK), y)
|
|
obj-$(CONFIG_X86) += x86/
|
|
endif
|
|
obj-$(CONFIG_ARCH_ZX) += zte/
|
|
obj-$(CONFIG_ARCH_ZYNQ) += zynq/
|
|
obj-$(CONFIG_COMMON_CLK_ZYNQMP) += zynqmp/
|