Skip to content

Commit

Permalink
tracing/fastboot: fix len of func buffer
Browse files Browse the repository at this point in the history
Impact: fix possible stack overrun

This is a port of a patch included in the mainline (KSYM_SYMBOL_LEN fixes).
The current func len is not large enough to contain the max symbol len, the
right size must be KSYM_SYMBOL_LEN.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Stephen Rothwell authored and Ingo Molnar committed Dec 12, 2008
1 parent f3134de commit 8001530
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/trace/boot.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@
*/
struct boot_trace_call {
pid_t caller;
char func[KSYM_NAME_LEN];
char func[KSYM_SYMBOL_LEN];
};

/*
* Structure which defines the trace of an initcall
* while it returns.
*/
struct boot_trace_ret {
char func[KSYM_NAME_LEN];
char func[KSYM_SYMBOL_LEN];
int result;
unsigned long long duration; /* nsecs */
};
Expand Down

0 comments on commit 8001530

Please sign in to comment.