]> asedeno.scripts.mit.edu Git - linux.git/commit
pinctrl: mcp23s08: spi: Fix regmap debugfs entries
authorJan Kundrát <jan.kundrat@cesnet.cz>
Thu, 25 Jan 2018 17:29:15 +0000 (18:29 +0100)
committerLinus Walleij <linus.walleij@linaro.org>
Mon, 12 Feb 2018 09:47:23 +0000 (10:47 +0100)
commit9b3e4207661e67f04c72af15e29f74cd944f5964
treeb050ee4a2f67b58cd5ee1726a5c1765ffce50b6a
parent184f3448f65f9d478a5dfec736c0a7c973637ce6
pinctrl: mcp23s08: spi: Fix regmap debugfs entries

The SPI version of this chip allows several devices to be present on the
same SPI bus via a local address. If this is in action and if the kernel
has debugfs, however, the code attempts to create duplicate entries for
the regmap's debugfs:

  mcp23s08 spi1.1: Failed to create debugfs directory

This patch simply assigns a local name matching the device logical
address to the `struct regmap_config`.

No changes are needed for MCP23S18 because that device does not support
any logical addressing. Similarly, I2C devices do not need any action,
either, because they are already different in their I2C address.

A similar problem is present for the pinctrl debugfs instance, but that
one is not addressed by this patch.

Signed-off-by: Jan Kundrát <jan.kundrat@cesnet.cz>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/pinctrl-mcp23s08.c