Skip to content

Commit

Permalink
i2c: Mark i2c_adapter.id as deprecated
Browse files Browse the repository at this point in the history
It's about time to make it clear that i2c_adapter.id is deprecated.
Hopefully this will remind the last user to move over to a different
strategy.

Signed-off-by: Jean Delvare <[email protected]>
Acked-by: Jarod Wilson <[email protected]>
Acked-by: Mauro Carvalho Chehab <[email protected]>
Acked-by: Hans Verkuil <[email protected]>
  • Loading branch information
Jean Delvare authored and Jean Delvare committed Nov 15, 2010
1 parent f3dc65d commit e1e18ee
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
10 changes: 10 additions & 0 deletions Documentation/feature-removal-schedule.txt
Original file line number Diff line number Diff line change
Expand Up @@ -554,3 +554,13 @@ Why: This is a legacy interface which have been replaced by a more
Who: NeilBrown <[email protected]>

----------------------------

What: i2c_adapter.id
When: June 2011
Why: This field is deprecated. I2C device drivers shouldn't change their
behavior based on the underlying I2C adapter. Instead, the I2C
adapter driver should instantiate the I2C devices and provide the
needed platform-specific information.
Who: Jean Delvare <[email protected]>

----------------------------
1 change: 0 additions & 1 deletion drivers/i2c/i2c-mux.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,6 @@ struct i2c_adapter *i2c_add_mux_adapter(struct i2c_adapter *parent,
snprintf(priv->adap.name, sizeof(priv->adap.name),
"i2c-%d-mux (chan_id %d)", i2c_adapter_id(parent), chan_id);
priv->adap.owner = THIS_MODULE;
priv->adap.id = parent->id;
priv->adap.algo = &priv->algo;
priv->adap.algo_data = priv;
priv->adap.dev.parent = &parent->dev;
Expand Down
2 changes: 1 addition & 1 deletion include/linux/i2c.h
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ struct i2c_algorithm {
*/
struct i2c_adapter {
struct module *owner;
unsigned int id;
unsigned int id __deprecated;
unsigned int class; /* classes to allow probing for */
const struct i2c_algorithm *algo; /* the algorithm to access the bus */
void *algo_data;
Expand Down

0 comments on commit e1e18ee

Please sign in to comment.