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

Commit 777f1f25 authored by Sai Krishna Juturi's avatar Sai Krishna Juturi Committed by Sriharsha Allenki
Browse files

usb : dwc3: Initialize kernel stack variables properly



If kernel stack variables are not initialized properly,
there  is a chance of kernel information disclosure.
So, initialize kernel stack variables with null characters.

CRs-fixed: 2042592
Change-Id: I213c0e5c7f67824c2cecace276ff2f8f81599d51
Signed-off-by: default avatarSai Krishna Juturi <jsaikrishna@codeaurora.org>
Signed-off-by: default avatarMayank Rana <mrana@codeaurora.org>
Signed-off-by: default avatarSriharsha Allenki <sallenki@codeaurora.org>
parent 0b21d22f
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -412,7 +412,7 @@ static ssize_t dwc3_testmode_write(struct file *file,
	struct dwc3		*dwc = s->private;
	unsigned long		flags;
	u32			testmode = 0;
	char			buf[32];
	char			buf[32] = {};

	if (atomic_read(&dwc->in_lpm)) {
		seq_puts(s, "USB device is powered off\n");
@@ -484,7 +484,7 @@ static ssize_t dwc3_link_state_write(struct file *file,
	struct dwc3		*dwc = s->private;
	unsigned long		flags;
	enum dwc3_link_state	state = 0;
	char			buf[32];
	char			buf[32] = {};

	if (atomic_read(&dwc->in_lpm)) {
		seq_puts(s, "USB device is powered off\n");