Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7b9f5aa1 authored by Rohith Kollalsi's avatar Rohith Kollalsi
Browse files

usb: dwc3: Initialize val,val1 with 0 as they can be used uninitialized



If in the function dwc3_msm_power_collapse_por, dwc3 is not on
DWC_usb31 core and dwc3_msm doesn't have dual port then val1
can be used uninitialized. To prevent such scenario initialize
val1 and val with zero.

Change-Id: I359c596d3dace6c00475eb22fb64a37631f240b1
Signed-off-by: default avatarRohith Kollalsi <rkollals@codeaurora.org>
parent 8ba92afc
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2256,7 +2256,7 @@ static void dwc3_msm_block_reset(struct dwc3_msm *mdwc, bool core_reset)
static void dwc3_msm_power_collapse_por(struct dwc3_msm *mdwc)
{
	struct dwc3 *dwc = platform_get_drvdata(mdwc->dwc3);
	u32 val, val1;
	u32 val = 0, val1 = 0;
	int ret;

	/* Configure AHB2PHY for one wait state read/write */