Lines Matching refs:soc

62 		desc = (const struct mtk_pin_desc *)&hw->soc->pins[pin];  in mtk_pinmux_set_mux()
80 desc = (const struct mtk_pin_desc *)&hw->soc->pins[pin]; in mtk_pinmux_gpio_request_enable()
85 hw->soc->gpio_m); in mtk_pinmux_gpio_request_enable()
95 desc = (const struct mtk_pin_desc *)&hw->soc->pins[pin]; in mtk_pinmux_gpio_set_direction()
111 desc = (const struct mtk_pin_desc *)&hw->soc->pins[pin]; in mtk_pinconf_get()
117 if (hw->soc->bias_disable_get) { in mtk_pinconf_get()
118 err = hw->soc->bias_disable_get(hw, desc, &ret); in mtk_pinconf_get()
126 if (hw->soc->bias_get) { in mtk_pinconf_get()
127 err = hw->soc->bias_get(hw, desc, 1, &ret); in mtk_pinconf_get()
135 if (hw->soc->bias_get) { in mtk_pinconf_get()
136 err = hw->soc->bias_get(hw, desc, 0, &ret); in mtk_pinconf_get()
178 if (hw->soc->drive_get) { in mtk_pinconf_get()
179 err = hw->soc->drive_get(hw, desc, &ret); in mtk_pinconf_get()
200 if (hw->soc->adv_pull_get) { in mtk_pinconf_get()
204 err = hw->soc->adv_pull_get(hw, desc, pullup, &ret); in mtk_pinconf_get()
228 desc = (const struct mtk_pin_desc *)&hw->soc->pins[pin]; in mtk_pinconf_set()
238 if (hw->soc->bias_disable_set) { in mtk_pinconf_set()
239 err = hw->soc->bias_disable_set(hw, desc); in mtk_pinconf_set()
247 if (hw->soc->bias_set) { in mtk_pinconf_set()
248 err = hw->soc->bias_set(hw, desc, 1); in mtk_pinconf_set()
256 if (hw->soc->bias_set) { in mtk_pinconf_set()
257 err = hw->soc->bias_set(hw, desc, 0); in mtk_pinconf_set()
277 if (hw->soc->ies_present) { in mtk_pinconf_set()
321 if (hw->soc->drive_set) { in mtk_pinconf_set()
322 err = hw->soc->drive_set(hw, desc, arg); in mtk_pinconf_set()
340 if (hw->soc->adv_pull_set) { in mtk_pinconf_set()
344 err = hw->soc->adv_pull_set(hw, desc, pullup, in mtk_pinconf_set()
447 desc = (const struct mtk_pin_desc *)&hw->soc->pins[gpio]; in mtk_gpio_get()
463 desc = (const struct mtk_pin_desc *)&hw->soc->pins[gpio]; in mtk_gpio_set()
493 desc = (const struct mtk_pin_desc *)&hw->soc->pins[offset]; in mtk_gpio_to_irq()
508 desc = (const struct mtk_pin_desc *)&hw->soc->pins[offset]; in mtk_gpio_set_config()
538 chip->ngpio = hw->soc->npins; in mtk_build_gpiochip()
568 for (i = 0; i < hw->soc->ngrps; i++) { in mtk_build_groups()
569 const struct group_desc *group = hw->soc->grps + i; in mtk_build_groups()
588 for (i = 0; i < hw->soc->nfuncs ; i++) { in mtk_build_functions()
589 const struct function_desc *func = hw->soc->funcs + i; in mtk_build_functions()
606 const struct mtk_pin_soc *soc) in mtk_moore_pinctrl_probe() argument
617 hw->soc = soc; in mtk_moore_pinctrl_probe()
620 if (!hw->soc->nbase_names) in mtk_moore_pinctrl_probe()
624 hw->base = devm_kmalloc_array(&pdev->dev, hw->soc->nbase_names, in mtk_moore_pinctrl_probe()
629 for (i = 0; i < hw->soc->nbase_names; i++) { in mtk_moore_pinctrl_probe()
631 hw->soc->base_names[i]); in mtk_moore_pinctrl_probe()
636 hw->nbase = hw->soc->nbase_names; in mtk_moore_pinctrl_probe()
641 pins = devm_kmalloc_array(&pdev->dev, hw->soc->npins, sizeof(*pins), in mtk_moore_pinctrl_probe()
646 for (i = 0; i < hw->soc->npins; i++) { in mtk_moore_pinctrl_probe()
647 pins[i].number = hw->soc->pins[i].number; in mtk_moore_pinctrl_probe()
648 pins[i].name = hw->soc->pins[i].name; in mtk_moore_pinctrl_probe()
653 mtk_desc.npins = hw->soc->npins; in mtk_moore_pinctrl_probe()