regulator: Fix incorrect casting in tps6230-regulator.c
PATCH 1/1 regulator: Fix incorrect casting in tps6230-regulator.c
linux-3.6/drivers/regulator/tps62360-regulator.c: In function ‘tps62360_probe’:linux-3.6/drivers/regulator/tps62360-regulator.c:364:13: warning: cast from poi$
Fix incorrect cast in tps62360_probe() function.
Signed-off-by Luis Gonzalez Fernandez <[email protected]>
--- drivers/regulator/tps62360-regulator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/regulator/tps62360-regulator.c +1 -1
@@ -361,7 +361,7 @@ static int __devinit tps62360_probe(struct i2c_client *client,dev_err (&client->dev,"Error: No device match found\n" );return -ENODEV ; } - chip_id = (int )match->data; + chip_id = *((int *)match->data);if (!pdata) pdata =of_get_tps62360_platform_data (&client->dev); }
Signature · 1 line
1.7.9.5
Quoted 4 lines · Luis Gonzalez Fernandez
linux-3.6/drivers/regulator/tps62360-regulator.c: In function ‘tps62360_probe’:linux-3.6/drivers/regulator/tps62360-regulator.c:364:13: warning: cast from poi$Fix incorrect cast in
tps62360_probe()function.
This fix isn't at all obvious and the warning doesn't show up for me. In general you need to supply some words explaining what you're doing, simply pasting a copy of an error message doesn't explain why your new code is good.