projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3235844
)
i2c: Simplify i2c_parent_is_i2c_adapter
author
Jean Delvare
<khali@linux-fr.org>
Sun, 24 Oct 2010 16:16:57 +0000
(18:16 +0200)
committer
Jean Delvare
<khali@endymion.delvare>
Sun, 24 Oct 2010 16:16:57 +0000
(18:16 +0200)
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>
include/linux/i2c.h
patch
|
blob
|
blame
|
history
diff --git
a/include/linux/i2c.h
b/include/linux/i2c.h
index 4bae0b72ed3cdba567f306bddb2a2e26326f7fc4..9391a491501a6792b7e6373ef52c1901833dbb8b 100644
(file)
--- 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;
}