ns_pinctrl 154 drivers/pinctrl/bcm/pinctrl-ns.c struct ns_pinctrl *ns_pinctrl = pinctrl_dev_get_drvdata(pctrl_dev); ns_pinctrl 156 drivers/pinctrl/bcm/pinctrl-ns.c return ns_pinctrl->num_groups; ns_pinctrl 162 drivers/pinctrl/bcm/pinctrl-ns.c struct ns_pinctrl *ns_pinctrl = pinctrl_dev_get_drvdata(pctrl_dev); ns_pinctrl 164 drivers/pinctrl/bcm/pinctrl-ns.c return ns_pinctrl->groups[selector].name; ns_pinctrl 172 drivers/pinctrl/bcm/pinctrl-ns.c struct ns_pinctrl *ns_pinctrl = pinctrl_dev_get_drvdata(pctrl_dev); ns_pinctrl 174 drivers/pinctrl/bcm/pinctrl-ns.c *pins = ns_pinctrl->groups[selector].pins; ns_pinctrl 175 drivers/pinctrl/bcm/pinctrl-ns.c *num_pins = ns_pinctrl->groups[selector].num_pins; ns_pinctrl 194 drivers/pinctrl/bcm/pinctrl-ns.c struct ns_pinctrl *ns_pinctrl = pinctrl_dev_get_drvdata(pctrl_dev); ns_pinctrl 196 drivers/pinctrl/bcm/pinctrl-ns.c return ns_pinctrl->num_functions; ns_pinctrl 202 drivers/pinctrl/bcm/pinctrl-ns.c struct ns_pinctrl *ns_pinctrl = pinctrl_dev_get_drvdata(pctrl_dev); ns_pinctrl 204 drivers/pinctrl/bcm/pinctrl-ns.c return ns_pinctrl->functions[selector].name; ns_pinctrl 212 drivers/pinctrl/bcm/pinctrl-ns.c struct ns_pinctrl *ns_pinctrl = pinctrl_dev_get_drvdata(pctrl_dev); ns_pinctrl 214 drivers/pinctrl/bcm/pinctrl-ns.c *groups = ns_pinctrl->functions[selector].groups; ns_pinctrl 215 drivers/pinctrl/bcm/pinctrl-ns.c *num_groups = ns_pinctrl->functions[selector].num_groups; ns_pinctrl 224 drivers/pinctrl/bcm/pinctrl-ns.c struct ns_pinctrl *ns_pinctrl = pinctrl_dev_get_drvdata(pctrl_dev); ns_pinctrl 229 drivers/pinctrl/bcm/pinctrl-ns.c for (i = 0; i < ns_pinctrl->groups[grp_select].num_pins; i++) { ns_pinctrl 230 drivers/pinctrl/bcm/pinctrl-ns.c int pin_number = ns_pinctrl->groups[grp_select].pins[i]; ns_pinctrl 235 drivers/pinctrl/bcm/pinctrl-ns.c regmap_read(ns_pinctrl->regmap, ns_pinctrl->offset, &tmp); ns_pinctrl 237 drivers/pinctrl/bcm/pinctrl-ns.c regmap_write(ns_pinctrl->regmap, ns_pinctrl->offset, tmp); ns_pinctrl 271 drivers/pinctrl/bcm/pinctrl-ns.c struct ns_pinctrl *ns_pinctrl; ns_pinctrl 278 drivers/pinctrl/bcm/pinctrl-ns.c ns_pinctrl = devm_kzalloc(dev, sizeof(*ns_pinctrl), GFP_KERNEL); ns_pinctrl 279 drivers/pinctrl/bcm/pinctrl-ns.c if (!ns_pinctrl) ns_pinctrl 281 drivers/pinctrl/bcm/pinctrl-ns.c pctldesc = &ns_pinctrl->pctldesc; ns_pinctrl 282 drivers/pinctrl/bcm/pinctrl-ns.c platform_set_drvdata(pdev, ns_pinctrl); ns_pinctrl 286 drivers/pinctrl/bcm/pinctrl-ns.c ns_pinctrl->dev = dev; ns_pinctrl 291 drivers/pinctrl/bcm/pinctrl-ns.c ns_pinctrl->chipset_flag = (uintptr_t)of_id->data; ns_pinctrl 293 drivers/pinctrl/bcm/pinctrl-ns.c ns_pinctrl->regmap = syscon_node_to_regmap(of_get_parent(np)); ns_pinctrl 294 drivers/pinctrl/bcm/pinctrl-ns.c if (IS_ERR(ns_pinctrl->regmap)) { ns_pinctrl 295 drivers/pinctrl/bcm/pinctrl-ns.c int err = PTR_ERR(ns_pinctrl->regmap); ns_pinctrl 302 drivers/pinctrl/bcm/pinctrl-ns.c if (of_property_read_u32(np, "offset", &ns_pinctrl->offset)) { ns_pinctrl 321 drivers/pinctrl/bcm/pinctrl-ns.c if (chipsets & ns_pinctrl->chipset_flag) { ns_pinctrl 327 drivers/pinctrl/bcm/pinctrl-ns.c ns_pinctrl->groups = devm_kcalloc(dev, ARRAY_SIZE(ns_pinctrl_groups), ns_pinctrl 330 drivers/pinctrl/bcm/pinctrl-ns.c if (!ns_pinctrl->groups) ns_pinctrl 332 drivers/pinctrl/bcm/pinctrl-ns.c for (i = 0, group = &ns_pinctrl->groups[0]; ns_pinctrl 336 drivers/pinctrl/bcm/pinctrl-ns.c if (src->chipsets & ns_pinctrl->chipset_flag) { ns_pinctrl 338 drivers/pinctrl/bcm/pinctrl-ns.c ns_pinctrl->num_groups++; ns_pinctrl 342 drivers/pinctrl/bcm/pinctrl-ns.c ns_pinctrl->functions = devm_kcalloc(dev, ns_pinctrl 346 drivers/pinctrl/bcm/pinctrl-ns.c if (!ns_pinctrl->functions) ns_pinctrl 348 drivers/pinctrl/bcm/pinctrl-ns.c for (i = 0, function = &ns_pinctrl->functions[0]; ns_pinctrl 352 drivers/pinctrl/bcm/pinctrl-ns.c if (src->chipsets & ns_pinctrl->chipset_flag) { ns_pinctrl 354 drivers/pinctrl/bcm/pinctrl-ns.c ns_pinctrl->num_functions++; ns_pinctrl 360 drivers/pinctrl/bcm/pinctrl-ns.c ns_pinctrl->pctldev = devm_pinctrl_register(dev, pctldesc, ns_pinctrl); ns_pinctrl 361 drivers/pinctrl/bcm/pinctrl-ns.c if (IS_ERR(ns_pinctrl->pctldev)) { ns_pinctrl 363 drivers/pinctrl/bcm/pinctrl-ns.c return PTR_ERR(ns_pinctrl->pctldev);