summaryrefslogtreecommitdiffstats
path: root/drivers/i2c
diff options
context:
space:
mode:
authorAnton Vorontsov <avorontsov@ru.mvista.com>2008-10-22 20:21:33 +0200
committerJean Delvare <khali@linux-fr.org>2008-10-22 20:21:33 +0200
commit11f1f2afd6b07729b12aaba479344d7f12d88ff9 (patch)
treeb0744f435b33869d9b2bb832f1df7cb5c9c6f6bc /drivers/i2c
parent02cf617282c6917484410f86ded3f2d99a05f098 (diff)
downloadblackbird-op-linux-11f1f2afd6b07729b12aaba479344d7f12d88ff9.tar.gz
blackbird-op-linux-11f1f2afd6b07729b12aaba479344d7f12d88ff9.zip
i2c: Add info->archdata field
If present the info->archdata is copied into the dev->archdata. Some (OpenFirmware) platforms need it. Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com> Signed-off-by: Jean Delvare <khali@linux-fr.org>
Diffstat (limited to 'drivers/i2c')
-rw-r--r--drivers/i2c/i2c-core.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c
index 42e852d79ffa..5a485c22660a 100644
--- a/drivers/i2c/i2c-core.c
+++ b/drivers/i2c/i2c-core.c
@@ -266,6 +266,9 @@ i2c_new_device(struct i2c_adapter *adap, struct i2c_board_info const *info)
client->dev.platform_data = info->platform_data;
+ if (info->archdata)
+ client->dev.archdata = *info->archdata;
+
client->flags = info->flags;
client->addr = info->addr;
client->irq = info->irq;
OpenPOWER on IntegriCloud