Skip to content

Commit eb367d8

Browse files
parakalinusw
authored andcommitted
pinctrl: ralink: rt2880: avoid to error in calls is pin is already enabled
In 'rt2880_pmx_group_enable' driver is printing an error and returning -EBUSY if a pin has been already enabled. This begets anoying messages in the caller when this happens like the following: rt2880-pinmux pinctrl: pcie is already enabled mt7621-pci 1e140000.pcie: Error applying setting, reverse things back To avoid this just print the already enabled message in the pinctrl driver and return 0 instead to not confuse the user with a real bad problem. Signed-off-by: Sergio Paracuellos <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Linus Walleij <[email protected]>
1 parent 0e4bf26 commit eb367d8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/pinctrl/ralink/pinctrl-rt2880.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ static int rt2880_pmx_group_enable(struct pinctrl_dev *pctrldev,
127127
if (p->groups[group].enabled) {
128128
dev_err(p->dev, "%s is already enabled\n",
129129
p->groups[group].name);
130-
return -EBUSY;
130+
return 0;
131131
}
132132

133133
p->groups[group].enabled = 1;

0 commit comments

Comments
 (0)