If there are multiple muxes on one bus, then specifying the channel only is not sufficient for a distinguishable name. We need the actual device, too.
Signed-off-by: Wolfram Sang <[email protected]> Cc: Jean Delvare <[email protected]> Cc: Guenter Roeck <[email protected]> Cc: Martin Belanger <[email protected]> Cc: Rodolfo Giometti <[email protected]> Cc: Michael Lawnick <[email protected]> Cc: Jeroen De Wachter <[email protected]> --- This is probably the least "ABI" breaking solution? RFC for now... drivers/i2c/i2c-mux.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/i2c/i2c-mux.c b/drivers/i2c/i2c-mux.c index 5b482ea32faf..26aa84902ada 100644 --- a/drivers/i2c/i2c-mux.c +++ b/drivers/i2c/i2c-mux.c @@ -134,7 +134,8 @@ struct i2c_adapter *i2c_add_mux_adapter(struct i2c_adapter *parent, /* Now fill out new adapter structure */ snprintf(priv->adap.name, sizeof(priv->adap.name), - "i2c-%d-mux (chan_id %d)", i2c_adapter_id(parent), chan_id); + "i2c-%d-mux (chan_id %d) (mux_device %s)", + i2c_adapter_id(parent), chan_id, dev_name(mux_dev)); priv->adap.owner = THIS_MODULE; priv->adap.algo = &priv->algo; priv->adap.algo_data = priv; -- 2.1.1 -- To unsubscribe from this list: send the line "unsubscribe linux-i2c" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
