Re: [PATCH 2/2] pinctrl: at91-pio4: Add persist state case in config

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 07/10/2022 at 17:16, Ryan.Wanner@xxxxxxxxxxxxx wrote:
From: Ryan Wanner <Ryan.Wanner@xxxxxxxxxxxxx>

Adding persist state case to atmel_conf_pin_config_group_set() function.
After adding configuration support for userspace gpiod api, there was an
extra flag PIN_CONFIG_PERSIST_STATE that was not passed in before.

Based on other drivers like TI drivers, added a switch case and return
ENOTSUPP in that case.

Signed-off-by: Ryan Wanner <Ryan.Wanner@xxxxxxxxxxxxx>

Acked-by: Nicolas Ferre <nicolas.ferre@xxxxxxxxxxxxx>

Thanks, best regards,
  Nicolas

---
  drivers/pinctrl/pinctrl-at91-pio4.c | 4 ++++
  1 file changed, 4 insertions(+)

diff --git a/drivers/pinctrl/pinctrl-at91-pio4.c b/drivers/pinctrl/pinctrl-at91-pio4.c
index 13b77f1eb6e2..40f1b9397767 100644
--- a/drivers/pinctrl/pinctrl-at91-pio4.c
+++ b/drivers/pinctrl/pinctrl-at91-pio4.c
@@ -780,6 +780,8 @@ static int atmel_conf_pin_config_group_get(struct pinctrl_dev *pctldev,
  			return -EINVAL;
  		arg = (res & ATMEL_PIO_DRVSTR_MASK) >> ATMEL_PIO_DRVSTR_OFFSET;
  		break;
+	case PIN_CONFIG_PERSIST_STATE:
+		return -ENOTSUPP;
  	default:
  		return -ENOTSUPP;
  	}
@@ -888,6 +890,8 @@ static int atmel_conf_pin_config_group_set(struct pinctrl_dev *pctldev,
  				dev_warn(pctldev->dev, "drive strength not updated (incorrect value)\n");
  			}
  			break;
+		case PIN_CONFIG_PERSIST_STATE:
+			return -ENOTSUPP;
  		default:
  			dev_warn(pctldev->dev,
  				 "unsupported configuration parameter: %u\n",


--
Nicolas Ferre



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux