Lines Matching +full:1 +full:g

256 	const struct tegra_pingroup *g;  in tegra_pinctrl_set_mux()  local
260 g = &pmx->soc->groups[group]; in tegra_pinctrl_set_mux()
262 if (WARN_ON(g->mux_reg < 0)) in tegra_pinctrl_set_mux()
265 for (i = 0; i < ARRAY_SIZE(g->funcs); i++) { in tegra_pinctrl_set_mux()
266 if (g->funcs[i] == function) in tegra_pinctrl_set_mux()
269 if (WARN_ON(i == ARRAY_SIZE(g->funcs))) in tegra_pinctrl_set_mux()
272 val = pmx_readl(pmx, g->mux_bank, g->mux_reg); in tegra_pinctrl_set_mux()
273 val &= ~(0x3 << g->mux_bit); in tegra_pinctrl_set_mux()
274 val |= i << g->mux_bit; in tegra_pinctrl_set_mux()
275 pmx_writel(pmx, val, g->mux_bank, g->mux_reg); in tegra_pinctrl_set_mux()
362 const struct tegra_pingroup *g, in tegra_pinconf_reg() argument
369 *bank = g->pupd_bank; in tegra_pinconf_reg()
370 *reg = g->pupd_reg; in tegra_pinconf_reg()
371 *bit = g->pupd_bit; in tegra_pinconf_reg()
375 *bank = g->tri_bank; in tegra_pinconf_reg()
376 *reg = g->tri_reg; in tegra_pinconf_reg()
377 *bit = g->tri_bit; in tegra_pinconf_reg()
378 *width = 1; in tegra_pinconf_reg()
381 *bank = g->mux_bank; in tegra_pinconf_reg()
382 *reg = g->mux_reg; in tegra_pinconf_reg()
383 *bit = g->einput_bit; in tegra_pinconf_reg()
384 *width = 1; in tegra_pinconf_reg()
387 *bank = g->mux_bank; in tegra_pinconf_reg()
388 *reg = g->mux_reg; in tegra_pinconf_reg()
389 *bit = g->odrain_bit; in tegra_pinconf_reg()
390 *width = 1; in tegra_pinconf_reg()
393 *bank = g->mux_bank; in tegra_pinconf_reg()
394 *reg = g->mux_reg; in tegra_pinconf_reg()
395 *bit = g->lock_bit; in tegra_pinconf_reg()
396 *width = 1; in tegra_pinconf_reg()
399 *bank = g->mux_bank; in tegra_pinconf_reg()
400 *reg = g->mux_reg; in tegra_pinconf_reg()
401 *bit = g->ioreset_bit; in tegra_pinconf_reg()
402 *width = 1; in tegra_pinconf_reg()
405 *bank = g->mux_bank; in tegra_pinconf_reg()
406 *reg = g->mux_reg; in tegra_pinconf_reg()
407 *bit = g->rcv_sel_bit; in tegra_pinconf_reg()
408 *width = 1; in tegra_pinconf_reg()
412 *bank = g->mux_bank; in tegra_pinconf_reg()
413 *reg = g->mux_reg; in tegra_pinconf_reg()
415 *bank = g->drv_bank; in tegra_pinconf_reg()
416 *reg = g->drv_reg; in tegra_pinconf_reg()
418 *bit = g->hsm_bit; in tegra_pinconf_reg()
419 *width = 1; in tegra_pinconf_reg()
423 *bank = g->mux_bank; in tegra_pinconf_reg()
424 *reg = g->mux_reg; in tegra_pinconf_reg()
426 *bank = g->drv_bank; in tegra_pinconf_reg()
427 *reg = g->drv_reg; in tegra_pinconf_reg()
429 *bit = g->schmitt_bit; in tegra_pinconf_reg()
430 *width = 1; in tegra_pinconf_reg()
433 *bank = g->drv_bank; in tegra_pinconf_reg()
434 *reg = g->drv_reg; in tegra_pinconf_reg()
435 *bit = g->lpmd_bit; in tegra_pinconf_reg()
439 *bank = g->drv_bank; in tegra_pinconf_reg()
440 *reg = g->drv_reg; in tegra_pinconf_reg()
441 *bit = g->drvdn_bit; in tegra_pinconf_reg()
442 *width = g->drvdn_width; in tegra_pinconf_reg()
445 *bank = g->drv_bank; in tegra_pinconf_reg()
446 *reg = g->drv_reg; in tegra_pinconf_reg()
447 *bit = g->drvup_bit; in tegra_pinconf_reg()
448 *width = g->drvup_width; in tegra_pinconf_reg()
451 *bank = g->drv_bank; in tegra_pinconf_reg()
452 *reg = g->drv_reg; in tegra_pinconf_reg()
453 *bit = g->slwf_bit; in tegra_pinconf_reg()
454 *width = g->slwf_width; in tegra_pinconf_reg()
457 *bank = g->drv_bank; in tegra_pinconf_reg()
458 *reg = g->drv_reg; in tegra_pinconf_reg()
459 *bit = g->slwr_bit; in tegra_pinconf_reg()
460 *width = g->slwr_width; in tegra_pinconf_reg()
464 *bank = g->mux_bank; in tegra_pinconf_reg()
465 *reg = g->mux_reg; in tegra_pinconf_reg()
467 *bank = g->drv_bank; in tegra_pinconf_reg()
468 *reg = g->drv_reg; in tegra_pinconf_reg()
470 *bit = g->drvtype_bit; in tegra_pinconf_reg()
492 param, prop, g->name); in tegra_pinconf_reg()
521 const struct tegra_pingroup *g; in tegra_pinconf_group_get() local
527 g = &pmx->soc->groups[group]; in tegra_pinconf_group_get()
529 ret = tegra_pinconf_reg(pmx, g, param, true, &bank, &reg, &bit, in tegra_pinconf_group_get()
535 mask = (1 << width) - 1; in tegra_pinconf_group_get()
550 const struct tegra_pingroup *g; in tegra_pinconf_group_set() local
556 g = &pmx->soc->groups[group]; in tegra_pinconf_group_set()
562 ret = tegra_pinconf_reg(pmx, g, param, true, &bank, &reg, &bit, in tegra_pinconf_group_set()
578 if (width == 1) in tegra_pinconf_group_set()
582 mask = (1 << width) - 1; in tegra_pinconf_group_set()
611 return comma + 1; in strip_prefix()
618 const struct tegra_pingroup *g; in tegra_pinconf_group_dbg_show() local
624 g = &pmx->soc->groups[group]; in tegra_pinconf_group_dbg_show()
627 ret = tegra_pinconf_reg(pmx, g, cfg_params[i].param, false, in tegra_pinconf_group_dbg_show()
634 val &= (1 << width) - 1; in tegra_pinconf_group_dbg_show()
676 const struct tegra_pingroup *g; in tegra_pinctrl_clear_parked_bits() local
680 g = &pmx->soc->groups[i]; in tegra_pinctrl_clear_parked_bits()
681 if (g->parked_bitmask > 0) { in tegra_pinctrl_clear_parked_bits()
684 if (g->mux_reg != -1) { in tegra_pinctrl_clear_parked_bits()
685 bank = g->mux_bank; in tegra_pinctrl_clear_parked_bits()
686 reg = g->mux_reg; in tegra_pinctrl_clear_parked_bits()
688 bank = g->drv_bank; in tegra_pinctrl_clear_parked_bits()
689 reg = g->drv_reg; in tegra_pinctrl_clear_parked_bits()
693 val &= ~g->parked_bitmask; in tegra_pinctrl_clear_parked_bits()
808 const struct tegra_pingroup *g = &pmx->soc->groups[gn]; in tegra_pinctrl_probe() local
810 if (g->mux_reg == -1) in tegra_pinctrl_probe()
814 if (g->funcs[gfn] == fn) in tegra_pinctrl_probe()
821 *group_pins++ = g->name; in tegra_pinctrl_probe()