aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/i2c
diff options
context:
space:
mode:
authorAndres Salomon <dilinger@queued.net>2011-02-17 22:07:15 -0500
committerSamuel Ortiz <sameo@linux.intel.com>2011-03-23 05:41:52 -0400
commite46dccff341068d8530610a822965794f70b998f (patch)
treea1f567ef8299629456f8a0309761f7d217a95006 /drivers/i2c
parent07ae2a08deb141f22d7974615bd3006e8dce3883 (diff)
mfd: mfd_cell is now implicitly available to timberdale drivers
The cell's platform_data is now accessed with a helper function; change clients to use that, and remove the now-unused data_size. Note that the mfd's platform_data is marked __devinitdata. This is still correct in all cases except for the timbgpio driver, whose remove hook has been changed to no longer reference the pdata. Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/i2c')
-rw-r--r--drivers/i2c/busses/i2c-ocores.c3
-rw-r--r--drivers/i2c/busses/i2c-xiic.c3
2 files changed, 4 insertions, 2 deletions
diff --git a/drivers/i2c/busses/i2c-ocores.c b/drivers/i2c/busses/i2c-ocores.c
index 1b46a9d9f907..fee1a2613861 100644
--- a/drivers/i2c/busses/i2c-ocores.c
+++ b/drivers/i2c/busses/i2c-ocores.c
@@ -49,6 +49,7 @@
49#include <linux/init.h> 49#include <linux/init.h>
50#include <linux/errno.h> 50#include <linux/errno.h>
51#include <linux/platform_device.h> 51#include <linux/platform_device.h>
52#include <linux/mfd/core.h>
52#include <linux/i2c.h> 53#include <linux/i2c.h>
53#include <linux/interrupt.h> 54#include <linux/interrupt.h>
54#include <linux/wait.h> 55#include <linux/wait.h>
@@ -305,7 +306,7 @@ static int __devinit ocores_i2c_probe(struct platform_device *pdev)
305 return -EIO; 306 return -EIO;
306 } 307 }
307 308
308 pdata = pdev->dev.platform_data; 309 pdata = mfd_get_data(pdev);
309 if (pdata) { 310 if (pdata) {
310 i2c->regstep = pdata->regstep; 311 i2c->regstep = pdata->regstep;
311 i2c->clock_khz = pdata->clock_khz; 312 i2c->clock_khz = pdata->clock_khz;
diff --git a/drivers/i2c/busses/i2c-xiic.c b/drivers/i2c/busses/i2c-xiic.c
index a9c419e075a5..9fbd7e6fe32e 100644
--- a/drivers/i2c/busses/i2c-xiic.c
+++ b/drivers/i2c/busses/i2c-xiic.c
@@ -34,6 +34,7 @@
34#include <linux/errno.h> 34#include <linux/errno.h>
35#include <linux/delay.h> 35#include <linux/delay.h>
36#include <linux/platform_device.h> 36#include <linux/platform_device.h>
37#include <linux/mfd/core.h>
37#include <linux/i2c.h> 38#include <linux/i2c.h>
38#include <linux/interrupt.h> 39#include <linux/interrupt.h>
39#include <linux/wait.h> 40#include <linux/wait.h>
@@ -704,7 +705,7 @@ static int __devinit xiic_i2c_probe(struct platform_device *pdev)
704 if (irq < 0) 705 if (irq < 0)
705 goto resource_missing; 706 goto resource_missing;
706 707
707 pdata = (struct xiic_i2c_platform_data *) pdev->dev.platform_data; 708 pdata = mfd_get_data(pdev);
708 if (!pdata) 709 if (!pdata)
709 return -EINVAL; 710 return -EINVAL;
710 711