diff options
author | Jean Delvare <khali@linux-fr.org> | 2010-08-26 10:26:54 +1000 |
---|---|---|
committer | Stephen Rothwell <sfr@canb.auug.org.au> | 2010-08-26 10:26:54 +1000 |
commit | cb89df87395f3c4ec125cad340a8f9e56a07a60d (patch) | |
tree | bdd06b8a2aa9967f82e66946473c3e6794cbb3e3 | |
parent | 502adf5778f4151dcba3f64dd6ed322151f3712c (diff) |
i2c: Simplify i2c_parent_is_i2c_adapter
Only i2c devices can have their type set to i2c_adapter_type, so
testing the bus type is redundant.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Michael Lawnick <ml.lawnick@gmx.de>
-rw-r--r-- | include/linux/i2c.h | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/include/linux/i2c.h b/include/linux/i2c.h index 4bae0b72ed3c..9391a491501a 100644 --- a/include/linux/i2c.h +++ b/include/linux/i2c.h @@ -387,7 +387,6 @@ static inline void i2c_set_adapdata(struct i2c_adapter *dev, void *data) static inline int i2c_parent_is_i2c_adapter(const struct i2c_adapter *adapter) { return adapter->dev.parent != NULL - && adapter->dev.parent->bus == &i2c_bus_type && adapter->dev.parent->type == &i2c_adapter_type; } |