mirror of
git://git.openwrt.org/openwrt/openwrt.git
synced 2024-12-23 15:12:50 +00:00
30cff7c3b0
Removed upstreamed patches: layerscape/patches-5.4/302-dts-0083-arm64-ls1028a-qds-correct-bus-of-rtc.patch[1] All other patches automatically rebased. 1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.4.174&id=65816c1034769e714edb70f59a33bc5472d9e55f Build system: x86_64 Build-tested: ramips/mt7621 Signed-off-by: John Audia <graysky@archlinux.us>
51 lines
1.6 KiB
Diff
51 lines
1.6 KiB
Diff
--- a/arch/mips/bcm63xx/clk.c
|
|
+++ b/arch/mips/bcm63xx/clk.c
|
|
@@ -430,6 +430,23 @@ static struct clk clk_pcie = {
|
|
};
|
|
|
|
/*
|
|
+ * NAND clock
|
|
+ */
|
|
+static void nand_set(struct clk *clk, int enable)
|
|
+{
|
|
+ if (BCMCPU_IS_6362())
|
|
+ bcm_hwclock_set(CKCTL_6362_NAND_EN, enable);
|
|
+ else if (BCMCPU_IS_6368())
|
|
+ bcm_hwclock_set(CKCTL_6368_NAND_EN, enable);
|
|
+ else if (BCMCPU_IS_63268())
|
|
+ bcm_hwclock_set(CKCTL_63268_NAND_EN, enable);
|
|
+}
|
|
+
|
|
+static struct clk clk_nand = {
|
|
+ .set = nand_set,
|
|
+};
|
|
+
|
|
+/*
|
|
* Internal peripheral clock
|
|
*/
|
|
static struct clk clk_periph = {
|
|
@@ -624,6 +641,7 @@ static struct clk_lookup bcm6362_clks[]
|
|
CLKDEV_INIT("bcm63xx-hsspi.0", "pll", &clk_hsspi_pll),
|
|
CLKDEV_INIT("10001000.spi", "pll", &clk_hsspi_pll),
|
|
/* gated clocks */
|
|
+ CLKDEV_INIT(NULL, "nand", &clk_nand),
|
|
CLKDEV_INIT(NULL, "enetsw", &clk_enetsw),
|
|
CLKDEV_INIT(NULL, "usbh", &clk_usbh),
|
|
CLKDEV_INIT(NULL, "usbd", &clk_usbd),
|
|
@@ -641,6 +659,7 @@ static struct clk_lookup bcm6368_clks[]
|
|
CLKDEV_INIT("10000100.serial", "refclk", &clk_periph),
|
|
CLKDEV_INIT("10000120.serial", "refclk", &clk_periph),
|
|
/* gated clocks */
|
|
+ CLKDEV_INIT(NULL, "nand", &clk_nand),
|
|
CLKDEV_INIT(NULL, "enetsw", &clk_enetsw),
|
|
CLKDEV_INIT(NULL, "usbh", &clk_usbh),
|
|
CLKDEV_INIT(NULL, "usbd", &clk_usbd),
|
|
@@ -659,6 +678,7 @@ static struct clk_lookup bcm63268_clks[]
|
|
CLKDEV_INIT("bcm63xx-hsspi.0", "pll", &clk_hsspi_pll),
|
|
CLKDEV_INIT("10001000.spi", "pll", &clk_hsspi_pll),
|
|
/* gated clocks */
|
|
+ CLKDEV_INIT(NULL, "nand", &clk_nand),
|
|
CLKDEV_INIT(NULL, "enetsw", &clk_enetsw),
|
|
CLKDEV_INIT(NULL, "usbh", &clk_usbh),
|
|
CLKDEV_INIT(NULL, "usbd", &clk_usbd),
|