leds: 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: Bryan Wu <cooloney@gmail.com>
This commit is contained in:
Jingoo Han
2013-07-30 01:07:35 -07:00
committed by Bryan Wu
parent 8465b01827
commit 87aae1ea82
30 changed files with 52 additions and 49 deletions

View File

@@ -446,7 +446,8 @@ static int pca9532_probe(struct i2c_client *client,
const struct i2c_device_id *id)
{
struct pca9532_data *data = i2c_get_clientdata(client);
struct pca9532_platform_data *pca9532_pdata = client->dev.platform_data;
struct pca9532_platform_data *pca9532_pdata =
dev_get_platdata(&client->dev);
if (!pca9532_pdata)
return -EIO;