From df1fa005b3df698831afa265700008a5284c1d09 Mon Sep 17 00:00:00 2001 From: Mathieu Maret Date: Wed, 9 Jan 2019 16:20:06 +0100 Subject: [PATCH] stack: add comments --- core/stack.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/core/stack.c b/core/stack.c index 724c80b..3d6c8f2 100644 --- a/core/stack.c +++ b/core/stack.c @@ -12,6 +12,9 @@ void printStackTrace(unsigned int maxFrames) // first function argument (maxFrames) // return address from caller // EBP (Extended Base Pointer) of calling function + // + // retrace function from address could done by optaining function address with gdb or + // objdump -S kernel unsigned int *ebp = __builtin_frame_address(0); for (unsigned int frame = 0; frame < maxFrames; frame++) { unsigned int eip = ebp[1];