aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/joystick/as5011.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/input/joystick/as5011.c')
-rw-r--r--drivers/input/joystick/as5011.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/input/joystick/as5011.c b/drivers/input/joystick/as5011.c
index 121cd63d3334..005d852a06e9 100644
--- a/drivers/input/joystick/as5011.c
+++ b/drivers/input/joystick/as5011.c
@@ -234,7 +234,7 @@ static int as5011_probe(struct i2c_client *client,
234 int irq; 234 int irq;
235 int error; 235 int error;
236 236
237 plat_data = client->dev.platform_data; 237 plat_data = dev_get_platdata(&client->dev);
238 if (!plat_data) 238 if (!plat_data)
239 return -EINVAL; 239 return -EINVAL;
240 240
@@ -288,6 +288,7 @@ static int as5011_probe(struct i2c_client *client,
288 if (irq < 0) { 288 if (irq < 0) {
289 dev_err(&client->dev, 289 dev_err(&client->dev,
290 "Failed to get irq number for button gpio\n"); 290 "Failed to get irq number for button gpio\n");
291 error = irq;
291 goto err_free_button_gpio; 292 goto err_free_button_gpio;
292 } 293 }
293 294