mirror of
https://github.com/torvalds/linux.git
synced 2024-11-22 12:11:40 +00:00
pinctrl: renesas: Convert to use grp member
Convert drivers to use grp member embedded in struct group_desc, because other members will be removed to avoid duplication and desynchronisation of the generic pin group description. Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20231211190321.307330-12-andriy.shevchenko@linux.intel.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
parent
a1cf1a5f9b
commit
fc7d3b60a8
@ -1131,7 +1131,7 @@ static int rza1_set_mux(struct pinctrl_dev *pctldev, unsigned int selector,
|
||||
return -EINVAL;
|
||||
|
||||
mux_confs = (struct rza1_mux_conf *)func->data;
|
||||
for (i = 0; i < grp->num_pins; ++i) {
|
||||
for (i = 0; i < grp->grp.npins; ++i) {
|
||||
int ret;
|
||||
|
||||
ret = rza1_pin_mux_single(rza1_pctl, &mux_confs[i]);
|
||||
|
@ -447,15 +447,15 @@ static int rza2_set_mux(struct pinctrl_dev *pctldev, unsigned int selector,
|
||||
|
||||
psel_val = func->data;
|
||||
|
||||
for (i = 0; i < grp->num_pins; ++i) {
|
||||
for (i = 0; i < grp->grp.npins; ++i) {
|
||||
dev_dbg(priv->dev, "Setting P%c_%d to PSEL=%d\n",
|
||||
port_names[RZA2_PIN_ID_TO_PORT(grp->pins[i])],
|
||||
RZA2_PIN_ID_TO_PIN(grp->pins[i]),
|
||||
port_names[RZA2_PIN_ID_TO_PORT(grp->grp.pins[i])],
|
||||
RZA2_PIN_ID_TO_PIN(grp->grp.pins[i]),
|
||||
psel_val[i]);
|
||||
rza2_set_pin_function(
|
||||
priv->base,
|
||||
RZA2_PIN_ID_TO_PORT(grp->pins[i]),
|
||||
RZA2_PIN_ID_TO_PIN(grp->pins[i]),
|
||||
RZA2_PIN_ID_TO_PORT(grp->grp.pins[i]),
|
||||
RZA2_PIN_ID_TO_PIN(grp->grp.pins[i]),
|
||||
psel_val[i]);
|
||||
}
|
||||
|
||||
|
@ -283,9 +283,9 @@ static int rzg2l_pinctrl_set_mux(struct pinctrl_dev *pctldev,
|
||||
return -EINVAL;
|
||||
|
||||
psel_val = func->data;
|
||||
pins = group->pins;
|
||||
pins = group->grp.pins;
|
||||
|
||||
for (i = 0; i < group->num_pins; i++) {
|
||||
for (i = 0; i < group->grp.npins; i++) {
|
||||
unsigned int *pin_data = pctrl->desc.pins[pins[i]].drv_data;
|
||||
u32 off = RZG2L_PIN_CFG_TO_PORT_OFFSET(*pin_data);
|
||||
u32 pin = RZG2L_PIN_ID_TO_PIN(pins[i]);
|
||||
|
@ -175,9 +175,9 @@ static int rzv2m_pinctrl_set_mux(struct pinctrl_dev *pctldev,
|
||||
return -EINVAL;
|
||||
|
||||
psel_val = func->data;
|
||||
pins = group->pins;
|
||||
pins = group->grp.pins;
|
||||
|
||||
for (i = 0; i < group->num_pins; i++) {
|
||||
for (i = 0; i < group->grp.npins; i++) {
|
||||
dev_dbg(pctrl->dev, "port:%u pin: %u PSEL:%u\n",
|
||||
RZV2M_PIN_ID_TO_PORT(pins[i]), RZV2M_PIN_ID_TO_PIN(pins[i]),
|
||||
psel_val[i]);
|
||||
|
Loading…
Reference in New Issue
Block a user