@@ -100,6 +100,14 @@ static unsigned int i2c_mux_parent_classes(struct i2c_adapter *parent)
return class;
}
+void i2c_mux_reparent(struct i2c_adapter *adap, struct i2c_adapter *new_parent)
+{
+ struct i2c_mux_priv *priv = adap->algo_data;
+
+ priv->parent = new_parent;
+}
+EXPORT_SYMBOL_GPL(i2c_mux_reparent);
+
/* Simple consistent prefix for i2c_add_mux_adapter */
#define i2c_mux_msg(fmt, ...) "%s-%u: " fmt, dev_name(mux_dev), chan_id, ##__VA_ARGS__
@@ -44,6 +44,8 @@ struct i2c_adapter *i2c_add_mux_adapter(struct i2c_adapter *parent,
void i2c_del_mux_adapter(struct i2c_adapter *adap);
+void i2c_mux_reparent(struct i2c_adapter *adap, struct i2c_adapter *new_parent);
+
#endif /* __KERNEL__ */
#endif /* _LINUX_I2C_MUX_H */