aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/i2c/busses/i2c-pxa.c
diff options
context:
space:
mode:
authorJingoo Han <jg1.han@samsung.com>2013-07-30 03:59:33 -0400
committerWolfram Sang <wsa@the-dreams.de>2013-08-19 13:46:30 -0400
commit6d4028c644edc0a2e4a8c948ebf81e8f2f09726e (patch)
tree89368ad03dc603de4af756ba3e5260cee489f023 /drivers/i2c/busses/i2c-pxa.c
parentcda2109a26eb6fa58acfeae878eed87492480eae (diff)
i2c: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of accessing dev->platform_data directly. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/i2c/busses/i2c-pxa.c')
-rw-r--r--drivers/i2c/busses/i2c-pxa.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/i2c/busses/i2c-pxa.c b/drivers/i2c/busses/i2c-pxa.c
index a61d9062bf7b..3dbc1acdc28a 100644
--- a/drivers/i2c/busses/i2c-pxa.c
+++ b/drivers/i2c/busses/i2c-pxa.c
@@ -1118,7 +1118,7 @@ static int i2c_pxa_probe_pdata(struct platform_device *pdev,
1118 struct pxa_i2c *i2c, 1118 struct pxa_i2c *i2c,
1119 enum pxa_i2c_types *i2c_types) 1119 enum pxa_i2c_types *i2c_types)
1120{ 1120{
1121 struct i2c_pxa_platform_data *plat = pdev->dev.platform_data; 1121 struct i2c_pxa_platform_data *plat = dev_get_platdata(&pdev->dev);
1122 const struct platform_device_id *id = platform_get_device_id(pdev); 1122 const struct platform_device_id *id = platform_get_device_id(pdev);
1123 1123
1124 *i2c_types = id->driver_data; 1124 *i2c_types = id->driver_data;
@@ -1136,7 +1136,7 @@ static int i2c_pxa_probe_pdata(struct platform_device *pdev,
1136 1136
1137static int i2c_pxa_probe(struct platform_device *dev) 1137static int i2c_pxa_probe(struct platform_device *dev)
1138{ 1138{
1139 struct i2c_pxa_platform_data *plat = dev->dev.platform_data; 1139 struct i2c_pxa_platform_data *plat = dev_get_platdata(&dev->dev);
1140 enum pxa_i2c_types i2c_type; 1140 enum pxa_i2c_types i2c_type;
1141 struct pxa_i2c *i2c; 1141 struct pxa_i2c *i2c;
1142 struct resource *res = NULL; 1142 struct resource *res = NULL;