Lines Matching full:pctrl
201 static void eq5p_update_bits(const struct eq5p_pinctrl *pctrl, in eq5p_update_bits() argument
205 void __iomem *ptr = pctrl->base + eq5p_regs[bank][reg]; in eq5p_update_bits()
210 static bool eq5p_test_bit(const struct eq5p_pinctrl *pctrl, in eq5p_test_bit() argument
213 u32 val = readl(pctrl->base + eq5p_regs[bank][reg]); in eq5p_test_bit()
262 struct eq5p_pinctrl *pctrl = pinctrl_dev_get_drvdata(pctldev); in eq5p_pinconf_get() local
268 pd = eq5p_test_bit(pctrl, bank, EQ5P_PD, offset); in eq5p_pinconf_get()
269 pu = eq5p_test_bit(pctrl, bank, EQ5P_PU, offset); in eq5p_pinconf_get()
284 val_ds = readl(pctrl->base + eq5p_regs[bank][EQ5P_DS_HIGH]); in eq5p_pinconf_get()
287 val_ds = readl(pctrl->base + eq5p_regs[bank][EQ5P_DS_LOW]); in eq5p_pinconf_get()
303 struct eq5p_pinctrl *pctrl = pinctrl_dev_get_drvdata(pctldev); in eq5p_pinctrl_pin_dbg_show() local
304 const char *pin_name = pctrl->desc.pins[pin].name; in eq5p_pinctrl_pin_dbg_show()
317 if (eq5p_test_bit(pctrl, bank, EQ5P_IOCR, offset)) { in eq5p_pinctrl_pin_dbg_show()
348 pd = eq5p_test_bit(pctrl, bank, EQ5P_PD, offset); in eq5p_pinctrl_pin_dbg_show()
349 pu = eq5p_test_bit(pctrl, bank, EQ5P_PU, offset); in eq5p_pinctrl_pin_dbg_show()
401 struct eq5p_pinctrl *pctrl = pinctrl_dev_get_drvdata(pctldev); in eq5p_pinmux_set_mux() local
413 eq5p_update_bits(pctrl, bank, EQ5P_IOCR, mask, val); in eq5p_pinmux_set_mux()
437 struct eq5p_pinctrl *pctrl = pinctrl_dev_get_drvdata(pctldev); in eq5p_pinconf_set_drive_strength() local
459 eq5p_update_bits(pctrl, bank, reg, mask, val); in eq5p_pinconf_set_drive_strength()
466 struct eq5p_pinctrl *pctrl = pinctrl_dev_get_drvdata(pctldev); in eq5p_pinconf_set() local
482 eq5p_update_bits(pctrl, bank, EQ5P_PD, val, 0); in eq5p_pinconf_set()
483 eq5p_update_bits(pctrl, bank, EQ5P_PU, val, 0); in eq5p_pinconf_set()
493 eq5p_update_bits(pctrl, bank, EQ5P_PD, val, val); in eq5p_pinconf_set()
494 eq5p_update_bits(pctrl, bank, EQ5P_PU, val, 0); in eq5p_pinconf_set()
504 eq5p_update_bits(pctrl, bank, EQ5P_PD, val, 0); in eq5p_pinconf_set()
505 eq5p_update_bits(pctrl, bank, EQ5P_PU, val, val); in eq5p_pinconf_set()
538 struct eq5p_pinctrl *pctrl; in eq5p_probe() local
541 pctrl = devm_kzalloc(dev, sizeof(*pctrl), GFP_KERNEL); in eq5p_probe()
542 if (!pctrl) in eq5p_probe()
545 pctrl->base = (void __iomem *)dev_get_platdata(dev); in eq5p_probe()
546 pctrl->desc.name = dev_name(dev); in eq5p_probe()
547 pctrl->desc.pins = eq5p_pins; in eq5p_probe()
548 pctrl->desc.npins = ARRAY_SIZE(eq5p_pins); in eq5p_probe()
549 pctrl->desc.pctlops = &eq5p_pinctrl_ops; in eq5p_probe()
550 pctrl->desc.pmxops = &eq5p_pinmux_ops; in eq5p_probe()
551 pctrl->desc.confops = &eq5p_pinconf_ops; in eq5p_probe()
552 pctrl->desc.owner = THIS_MODULE; in eq5p_probe()
554 ret = devm_pinctrl_register_and_init(dev, &pctrl->desc, pctrl, &pctldev); in eq5p_probe()