Commit a260527f authored by Nizam Haider's avatar Nizam Haider Committed by Jonathan Cameron

Staging: iio: light: tsl2x7x_core: use dev_get_platdata()

Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly.
Signed-off-by: default avatarNizam Haider <nijamh@cdac.in>
Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
parent 22b19ab3
...@@ -1898,7 +1898,7 @@ static int tsl2x7x_probe(struct i2c_client *clientp, ...@@ -1898,7 +1898,7 @@ static int tsl2x7x_probe(struct i2c_client *clientp,
mutex_init(&chip->prox_mutex); mutex_init(&chip->prox_mutex);
chip->tsl2x7x_chip_status = TSL2X7X_CHIP_UNKNOWN; chip->tsl2x7x_chip_status = TSL2X7X_CHIP_UNKNOWN;
chip->pdata = clientp->dev.platform_data; chip->pdata = dev_get_platdata(&clientp->dev);
chip->id = id->driver_data; chip->id = id->driver_data;
chip->chip_info = chip->chip_info =
&tsl2x7x_chip_info_tbl[device_channel_config[id->driver_data]]; &tsl2x7x_chip_info_tbl[device_channel_config[id->driver_data]];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment