hwmon: (ina2xx) Remove casting the return value which is a void pointer
authorJingoo Han <[email protected]>
Mon, 9 Sep 2013 05:29:32 +0000 (14:29 +0900)
committerGuenter Roeck <[email protected]>
Tue, 10 Sep 2013 13:28:31 +0000 (06:28 -0700)
Casting the return value which is a void pointer is redundant.
The conversion from void pointer to any other pointer type is
guaranteed by the C programming language.

Signed-off-by: Jingoo Han <[email protected]>
Acked-by: Jean Delvare <[email protected]>
Signed-off-by: Guenter Roeck <[email protected]>
drivers/hwmon/ina2xx.c

index 18c062360ca7950e77ef4573ddf3dbc9fc16be82..70a39a8ac0160e520f6017225c71d1efedebca2c 100644 (file)
@@ -233,8 +233,7 @@ static int ina2xx_probe(struct i2c_client *client,
                return -ENOMEM;
 
        if (dev_get_platdata(&client->dev)) {
-               pdata =
-                 (struct ina2xx_platform_data *)dev_get_platdata(&client->dev);
+               pdata = dev_get_platdata(&client->dev);
                shunt = pdata->shunt_uohms;
        } else if (!of_property_read_u32(client->dev.of_node,
                                "shunt-resistor", &val)) {