static int sandbox_pmic_bind(struct udevice *dev) { if (!pmic_bind_children(dev, dev_ofnode(dev), pmic_children_info)) pr_err("%s:%d PMIC: %s - no child found!", __func__, __LINE__, dev->name); /* Always return success for this device - allows for PMIC I/O */ return 0; }
static int pmic_tps65910_bind(struct udevice *dev) { ofnode regulators_node; int children; regulators_node = dev_read_subnode(dev, "regulators"); if (!ofnode_valid(regulators_node)) { debug("%s regulators subnode not found\n", dev->name); return -EINVAL; } children = pmic_bind_children(dev, regulators_node, pmic_children_info); if (!children) debug("%s has no children (regulators)\n", dev->name); return 0; }
static int lp873x_bind(struct udevice *dev) { ofnode regulators_node; int children; regulators_node = dev_read_subnode(dev, "regulators"); if (!ofnode_valid(regulators_node)) { debug("%s: %s regulators subnode not found!", __func__, dev->name); return -ENXIO; } children = pmic_bind_children(dev, regulators_node, pmic_children_info); if (!children) printf("%s: %s - no child found\n", __func__, dev->name); /* Always return success for this device */ return 0; }
static int s2mps11_probe(struct udevice *dev) { ofnode regulators_node; int children; regulators_node = dev_read_subnode(dev, "voltage-regulators"); if (!ofnode_valid(regulators_node)) { debug("%s: %s regulators subnode not found!", __func__, dev->name); return -ENXIO; } debug("%s: '%s' - found regulators subnode\n", __func__, dev->name); children = pmic_bind_children(dev, regulators_node, pmic_children_info); if (!children) debug("%s: %s - no child found\n", __func__, dev->name); return 0; }
static int lp873x_bind(struct udevice *dev) { int regulators_node; const void *blob = gd->fdt_blob; int children; int node = dev->of_offset; regulators_node = fdt_subnode_offset(blob, node, "regulators"); if (regulators_node <= 0) { printf("%s: %s reg subnode not found!", __func__, dev->name); return -ENXIO; } children = pmic_bind_children(dev, regulators_node, pmic_children_info); if (!children) printf("%s: %s - no child found\n", __func__, dev->name); /* Always return success for this device */ return 0; }
static int stpmu1_bind(struct udevice *dev) { #ifndef CONFIG_SPL_BUILD ofnode regulators_node; int children; regulators_node = dev_read_subnode(dev, "regulators"); if (!ofnode_valid(regulators_node)) { dev_dbg(dev, "regulators subnode not found!"); return -ENXIO; } dev_dbg(dev, "found regulators subnode\n"); children = pmic_bind_children(dev, regulators_node, stpmu1_children_info); if (!children) dev_dbg(dev, "no child found\n"); #endif /* CONFIG_SPL_BUILD */ return 0; }
static int s5m8767_bind(struct udevice *dev) { int children; ofnode node; node = dev_read_subnode(dev, "regulators"); if (!ofnode_valid(node)) { debug("%s: %s regulators subnode not found!", __func__, dev->name); return -ENXIO; } debug("%s: '%s' - found regulators subnode\n", __func__, dev->name); children = pmic_bind_children(dev, node, pmic_children_info); if (!children) debug("%s: %s - no child found\n", __func__, dev->name); /* Always return success for this device */ return 0; }
static int max77686_bind(struct udevice *dev) { ofnode regulators_node; int children; regulators_node = dev_read_subnode(dev, "voltage-regulators"); if (!ofnode_valid(regulators_node)) { debug("%s: %s regulators subnode not found!\n", __func__, dev->name); return -ENXIO; } debug("%s: '%s' - found regulators subnode\n", __func__, dev->name); children = pmic_bind_children(dev, regulators_node, pmic_children_info); if (!children) debug("%s: %s - no child found\n", __func__, dev->name); /* Always return success for this device */ return 0; }
static int s5m8767_bind(struct udevice *dev) { int node; const void *blob = gd->fdt_blob; int children; node = fdt_subnode_offset(blob, dev->of_offset, "regulators"); if (node <= 0) { debug("%s: %s regulators subnode not found!", __func__, dev->name); return -ENXIO; } debug("%s: '%s' - found regulators subnode\n", __func__, dev->name); children = pmic_bind_children(dev, node, pmic_children_info); if (!children) debug("%s: %s - no child found\n", __func__, dev->name); /* Always return success for this device */ return 0; }