Commit d9f50048 authored by Phil Reid's avatar Phil Reid Committed by Linus Walleij

pinctrl: mcp23s08: fix probing of mcp23s18

one_regmap_config is always null if mcp type is MCP_TYPE_S18.
Remove the null check so that the mcp23s18 will probe.

Fixes: 1781af56 ("pinctrl: mcp23s08: spi: Fix duplicate pinctrl debugfs entries")
Signed-off-by: default avatarPhil Reid <preid@electromag.com.au>
Reviewed-by: default avatarJan Kundrát <jan.kundrat@cesnet.cz>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
parent 12b10f47
...@@ -823,8 +823,6 @@ static int mcp23s08_probe_one(struct mcp23s08 *mcp, struct device *dev, ...@@ -823,8 +823,6 @@ static int mcp23s08_probe_one(struct mcp23s08 *mcp, struct device *dev,
break; break;
case MCP_TYPE_S18: case MCP_TYPE_S18:
if (!one_regmap_config)
return -ENOMEM;
mcp->regmap = devm_regmap_init(dev, &mcp23sxx_spi_regmap, mcp, mcp->regmap = devm_regmap_init(dev, &mcp23sxx_spi_regmap, mcp,
&mcp23x17_regmap); &mcp23x17_regmap);
mcp->reg_shift = 1; mcp->reg_shift = 1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment