summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPreetham Chandru R <pchandru@nvidia.com>2012-12-31 19:47:13 +0530
committerMatthew Pedro <mapedro@nvidia.com>2013-01-07 13:27:48 -0800
commit8acf989d5896b152cc88f8b29afd11d522f903e3 (patch)
treec19e72ee9e92c4171f229fb138f6537052009b03
parentc319d0e904e6bff6e6c89d3c8cf651949c379925 (diff)
usb: otg: tegra: Do not free platform data twice
when platform device is unregistered, the call to platform_device_release() will kfree the platform data. Hence do not free the platform data again. Bug 1209618 Change-Id: Ied67f550223ec199da4bc8e38a12e7ee94c2d98a Signed-off-by: Preetham Chandru R <pchandru@nvidia.com> Reviewed-on: http://git-master/r/187806 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Kiran Adduri <kadduri@nvidia.com> Reviewed-by: Rakesh Bodla <rbodla@nvidia.com> Reviewed-by: Venkat Moganty <vmoganty@nvidia.com> Reviewed-by: Matthew Pedro <mapedro@nvidia.com>
-rw-r--r--drivers/usb/otg/tegra-otg.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/usb/otg/tegra-otg.c b/drivers/usb/otg/tegra-otg.c
index ce19f77433fc..12c359bcbe46 100644
--- a/drivers/usb/otg/tegra-otg.c
+++ b/drivers/usb/otg/tegra-otg.c
@@ -173,8 +173,6 @@ static void tegra_stop_host(struct tegra_otg_data *tegra)
if (pdev) {
/* unregister host from otg */
- kfree(pdev->dev.platform_data);
- pdev->dev.platform_data = NULL;
platform_device_unregister(pdev);
tegra->pdev = NULL;
}