diff options
-rw-r--r-- | drivers/gpio/gpio-pca953x.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/gpio/gpio-pca953x.c b/drivers/gpio/gpio-pca953x.c index 892dc043f40b..018f39cc19c8 100644 --- a/drivers/gpio/gpio-pca953x.c +++ b/drivers/gpio/gpio-pca953x.c | |||
@@ -739,7 +739,7 @@ out: | |||
739 | static const struct of_device_id pca953x_dt_ids[]; | 739 | static const struct of_device_id pca953x_dt_ids[]; |
740 | 740 | ||
741 | static int pca953x_probe(struct i2c_client *client, | 741 | static int pca953x_probe(struct i2c_client *client, |
742 | const struct i2c_device_id *id) | 742 | const struct i2c_device_id *i2c_id) |
743 | { | 743 | { |
744 | struct pca953x_platform_data *pdata; | 744 | struct pca953x_platform_data *pdata; |
745 | struct pca953x_chip *chip; | 745 | struct pca953x_chip *chip; |
@@ -765,21 +765,21 @@ static int pca953x_probe(struct i2c_client *client, | |||
765 | 765 | ||
766 | chip->client = client; | 766 | chip->client = client; |
767 | 767 | ||
768 | if (id) { | 768 | if (i2c_id) { |
769 | chip->driver_data = id->driver_data; | 769 | chip->driver_data = i2c_id->driver_data; |
770 | } else { | 770 | } else { |
771 | const struct acpi_device_id *id; | 771 | const struct acpi_device_id *acpi_id; |
772 | const struct of_device_id *match; | 772 | const struct of_device_id *match; |
773 | 773 | ||
774 | match = of_match_device(pca953x_dt_ids, &client->dev); | 774 | match = of_match_device(pca953x_dt_ids, &client->dev); |
775 | if (match) { | 775 | if (match) { |
776 | chip->driver_data = (int)(uintptr_t)match->data; | 776 | chip->driver_data = (int)(uintptr_t)match->data; |
777 | } else { | 777 | } else { |
778 | id = acpi_match_device(pca953x_acpi_ids, &client->dev); | 778 | acpi_id = acpi_match_device(pca953x_acpi_ids, &client->dev); |
779 | if (!id) | 779 | if (!acpi_id) |
780 | return -ENODEV; | 780 | return -ENODEV; |
781 | 781 | ||
782 | chip->driver_data = id->driver_data; | 782 | chip->driver_data = acpi_id->driver_data; |
783 | } | 783 | } |
784 | } | 784 | } |
785 | 785 | ||