summaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorBartosz Golaszewski <brgl@bgdev.pl>2018-05-07 06:08:37 -0400
committerBartosz Golaszewski <brgl@bgdev.pl>2018-05-09 11:16:06 -0400
commit76aa3de7095f15af7300012cb29ea8ab93eec348 (patch)
tree3edd19f4121c5bb6ca98b22a0aa070fde65e5714 /drivers/misc
parent75bc37fefc4471e718ba8e651aa74673d4e0a9eb (diff)
eeprom: at24: fix retrieving the at24_chip_data structure
Commit feb2f19b1e8f ("eeprom: at24: move platform data processing into a separate routine") introduced a bug where we incorrectly retireve the at24_chip_data structure. Remove the unnecessary ampersand operator. Fixes: feb2f19b1e8f ("eeprom: at24: move platform data processing into a separate routine") Reported-by: Vadim Pasternak <vadimp@mellanox.com> Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/eeprom/at24.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/misc/eeprom/at24.c b/drivers/misc/eeprom/at24.c
index 0c125f207aea..33053b0d1fdf 100644
--- a/drivers/misc/eeprom/at24.c
+++ b/drivers/misc/eeprom/at24.c
@@ -518,7 +518,7 @@ static int at24_get_pdata(struct device *dev, struct at24_platform_data *pdata)
518 if (of_node && of_match_device(at24_of_match, dev)) 518 if (of_node && of_match_device(at24_of_match, dev))
519 cdata = of_device_get_match_data(dev); 519 cdata = of_device_get_match_data(dev);
520 else if (id) 520 else if (id)
521 cdata = (void *)&id->driver_data; 521 cdata = (void *)id->driver_data;
522 else 522 else
523 cdata = acpi_device_get_match_data(dev); 523 cdata = acpi_device_get_match_data(dev);
524 524