Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

gpio: sama5d2-piobu: remove unneeded call to platform_set_drvdata()

This function call was found to be unnecessary as there is no equivalent
platform_get_drvdata() call to access the private data of the driver. Also,
the private data is defined in this driver, so there is no risk of it being
accessed outside of this driver file.

Reviewed-by: Alexandru Ardelean <alex@shruggie.ro>
Signed-off-by: Andrei Coardos <aboutphysycs@gmail.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

authored by

Andrei Coardos and committed by
Bartosz Golaszewski
c975cc59 8e85d6af

-1
-1
drivers/gpio/gpio-sama5d2-piobu.c
··· 189 189 if (!piobu) 190 190 return -ENOMEM; 191 191 192 - platform_set_drvdata(pdev, piobu); 193 192 piobu->chip.label = pdev->name; 194 193 piobu->chip.parent = &pdev->dev; 195 194 piobu->chip.owner = THIS_MODULE,