aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/i2c/muxes/i2c-mux-pca9541.c
diff options
context:
space:
mode:
authorPeter Rosin <peda@axentia.se>2016-08-11 16:49:54 +0200
committerPeter Rosin <peda@axentia.se>2016-08-25 22:11:03 +0200
commit40839590f868d77ab8f84ac6e1b1297f553e3dea (patch)
treee5ccc7bb02608c933dd4b4304df0d6fa38f6ec4e /drivers/i2c/muxes/i2c-mux-pca9541.c
parenti2c: mux: add support for 'i2c-mux', 'i2c-arb' and 'i2c-gate' DT subnodes (diff)
downloadlinux-dev-40839590f868d77ab8f84ac6e1b1297f553e3dea.tar.xz
linux-dev-40839590f868d77ab8f84ac6e1b1297f553e3dea.zip
i2c: mux: inform the i2c mux core about how it is used
The i2c mux core can then take appropriate action depending on if it is used for an actual i2c mux, for a gate or for an arbitrator (the last is the case for these drivers). This adds support for the new clearer and more compact devicetree bindings that was added recently. Reviewed-by: Wolfram Sang <wsa@the-dreams.de> Signed-off-by: Peter Rosin <peda@axentia.se>
Diffstat (limited to 'drivers/i2c/muxes/i2c-mux-pca9541.c')
-rw-r--r--drivers/i2c/muxes/i2c-mux-pca9541.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/i2c/muxes/i2c-mux-pca9541.c b/drivers/i2c/muxes/i2c-mux-pca9541.c
index 3cb8af635db5..f052c3067791 100644
--- a/drivers/i2c/muxes/i2c-mux-pca9541.c
+++ b/drivers/i2c/muxes/i2c-mux-pca9541.c
@@ -349,7 +349,8 @@ static int pca9541_probe(struct i2c_client *client,
force = 0;
if (pdata)
force = pdata->modes[0].adap_id;
- muxc = i2c_mux_alloc(adap, &client->dev, 1, sizeof(*data), 0,
+ muxc = i2c_mux_alloc(adap, &client->dev, 1, sizeof(*data),
+ I2C_MUX_ARBITRATOR,
pca9541_select_chan, pca9541_release_chan);
if (!muxc)
return -ENOMEM;