diff --git a/drivers/pinctrl/pinctrl-mcp23s08.c b/drivers/pinctrl/pinctrl-mcp23s08.c index d0259577934e..bccebe43dd6a 100644 --- a/drivers/pinctrl/pinctrl-mcp23s08.c +++ b/drivers/pinctrl/pinctrl-mcp23s08.c @@ -9,6 +9,7 @@ #include #include #include +#include #include #include #include @@ -558,6 +559,8 @@ int mcp23s08_probe_one(struct mcp23s08 *mcp, struct device *dev, mcp->chip.parent = dev; mcp->chip.owner = THIS_MODULE; + mcp->reset_gpio = devm_gpiod_get_optional(dev, "reset", GPIOD_OUT_LOW); + /* verify MCP_IOCON.SEQOP = 0, so sequential reads work, * and MCP_IOCON.HAEN = 1, so we work with all chips. */ diff --git a/drivers/pinctrl/pinctrl-mcp23s08.h b/drivers/pinctrl/pinctrl-mcp23s08.h index 90dc27081a3c..b8d15939e0c2 100644 --- a/drivers/pinctrl/pinctrl-mcp23s08.h +++ b/drivers/pinctrl/pinctrl-mcp23s08.h @@ -43,6 +43,7 @@ struct mcp23s08 { struct pinctrl_dev *pctldev; struct pinctrl_desc pinctrl_desc; + struct gpio_desc *reset_gpio; }; extern const struct regmap_config mcp23x08_regmap;