aboutsummaryrefslogtreecommitdiff
path: root/drivers/misc
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2019-11-12 07:18:23 -0500
committerTom Rini <trini@konsulko.com>2019-11-12 07:18:23 -0500
commit5f7ff6d63eeb81ad2c071ff5f5adae5bcc94f7a4 (patch)
treeeb3707f7e5b4ae1d0f3094cc8814ef8bc389aa8c /drivers/misc
parenta965a8b904093c9e6790d0460d18a144cefa5e42 (diff)
parentbdcf3a88cc582ce8bb9ea024fa917d9a52e05479 (diff)
downloadu-boot-5f7ff6d63eeb81ad2c071ff5f5adae5bcc94f7a4.zip
u-boot-5f7ff6d63eeb81ad2c071ff5f5adae5bcc94f7a4.tar.gz
u-boot-5f7ff6d63eeb81ad2c071ff5f5adae5bcc94f7a4.tar.bz2
Merge tag 'u-boot-imx-20191105' of https://gitlab.denx.de/u-boot/custodians/u-boot-imx
u-boot-imx-20191105 ------------------- i.MX8MN SoC support ROM API image download support i.MX8MM enet enabling
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/imx8/scu.c46
1 files changed, 7 insertions, 39 deletions
diff --git a/drivers/misc/imx8/scu.c b/drivers/misc/imx8/scu.c
index 9ec0045..a7654a7 100644
--- a/drivers/misc/imx8/scu.c
+++ b/drivers/misc/imx8/scu.c
@@ -26,8 +26,6 @@ struct mu_type {
struct imx8_scu {
struct mu_type *base;
- struct udevice *clk;
- struct udevice *pinclk;
};
#define MU_CR_GIE_MASK 0xF0000000u
@@ -202,9 +200,6 @@ static int imx8_scu_probe(struct udevice *dev)
gd->arch.scu_dev = dev;
- device_probe(plat->clk);
- device_probe(plat->pinclk);
-
return 0;
}
@@ -215,44 +210,17 @@ static int imx8_scu_remove(struct udevice *dev)
static int imx8_scu_bind(struct udevice *dev)
{
- struct imx8_scu *plat = dev_get_platdata(dev);
int ret;
struct udevice *child;
- int node;
- char *clk_compatible, *iomuxc_compatible;
-
- if (IS_ENABLED(CONFIG_IMX8QXP)) {
- clk_compatible = "fsl,imx8qxp-clk";
- iomuxc_compatible = "fsl,imx8qxp-iomuxc";
- } else if (IS_ENABLED(CONFIG_IMX8QM)) {
- clk_compatible = "fsl,imx8qm-clk";
- iomuxc_compatible = "fsl,imx8qm-iomuxc";
- } else {
- return -EINVAL;
- }
+ ofnode node;
debug("%s(dev=%p)\n", __func__, dev);
-
- node = fdt_node_offset_by_compatible(gd->fdt_blob, -1, clk_compatible);
- if (node < 0)
- panic("No clk node found\n");
-
- ret = lists_bind_fdt(dev, offset_to_ofnode(node), &child, true);
- if (ret)
- return ret;
-
- plat->clk = child;
-
- node = fdt_node_offset_by_compatible(gd->fdt_blob, -1,
- iomuxc_compatible);
- if (node < 0)
- panic("No iomuxc node found\n");
-
- ret = lists_bind_fdt(dev, offset_to_ofnode(node), &child, true);
- if (ret)
- return ret;
-
- plat->pinclk = child;
+ ofnode_for_each_subnode(node, dev_ofnode(dev)) {
+ ret = lists_bind_fdt(dev, node, &child, true);
+ if (ret)
+ return ret;
+ debug("bind child dev %s\n", child->name);
+ }
return 0;
}