From b21fde722e625766ec90024a8c019adc2c60bc1b Mon Sep 17 00:00:00 2001 From: Rakesh Bodla Date: Thu, 31 Mar 2011 17:16:30 +0530 Subject: ARM: tegra: usb_phy: Fixing unintialized pointer Memory for phy structure is allocated using kzalloc for phy memory allocation so that reg_vbus doesn't contain garbage value. Bug 807534 Original-Change-Id: Ib25a5baebda2b39baf49d12a16044688d4ae559f Reviewed-on: http://git-master/r/24930 Reviewed-by: Rakesh Bodla Tested-by: Rakesh Bodla Reviewed-by: Scott Williams Original-Change-Id: I2da9e8c2102c564a68493d22cdf951866c165635 Rebase-Id: R7b15702463ba89e7b9bc447432314fe6ada00974 --- arch/arm/mach-tegra/usb_phy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mach-tegra/usb_phy.c b/arch/arm/mach-tegra/usb_phy.c index e69f8ad4322b..4190cb8d8c91 100644 --- a/arch/arm/mach-tegra/usb_phy.c +++ b/arch/arm/mach-tegra/usb_phy.c @@ -1346,7 +1346,7 @@ struct tegra_usb_phy *tegra_usb_phy_open(int instance, void __iomem *regs, int err; bool hsic = false; - phy = kmalloc(sizeof(struct tegra_usb_phy), GFP_KERNEL); + phy = kzalloc(sizeof(struct tegra_usb_phy), GFP_KERNEL); if (!phy) return ERR_PTR(-ENOMEM); -- cgit v1.2.3