Title: [7362] trunk/arch/blackfin/kernel/ftrace-entry.S: ftrace: fix up new comments
Revision
7362
Author
vapier
Date
2009-09-16 13:20:45 -0400 (Wed, 16 Sep 2009)

Log Message

ftrace: fix up new comments

Modified Paths


Diff

Modified: trunk/arch/blackfin/kernel/ftrace-entry.S (7361 => 7362)


--- trunk/arch/blackfin/kernel/ftrace-entry.S	2009-09-16 10:23:19 UTC (rev 7361)
+++ trunk/arch/blackfin/kernel/ftrace-entry.S	2009-09-16 17:20:45 UTC (rev 7362)
@@ -17,8 +17,8 @@
  * only one we can blow away.  With pointer registers, we have P0-P2.
  *
  * Upon entry, the RETS will point to the top of the current profiled
- * function.  And since GCC setup the frame for us, the previous function
- * will be waiting there.  mmmm pie.
+ * function.  And since GCC pushed the previous RETS for us, the previous
+ * function will be waiting there.  mmmm pie.
  */
 ENTRY(__mcount)
 	/* save third function arg early so we can do testing below */
@@ -71,20 +71,14 @@
 	p0 = r3;
 
 	/* function_trace_call(unsigned long ip, unsigned long parent_ip):
-	 *  ip: ... this location
-	 *  parent_ip: the pc that did the call to ...
+	 *  ip: this point was called by ...
+	 *  parent_ip: ... this function
 	 * the ip itself will need adjusting for the mcount call
 	 */
 	r0 = rets;
+	r1 = [sp + 16];	/* skip the 4 local regs on stack */
 	r0 += -MCOUNT_INSN_SIZE;
 
-	/*
-	 * parent_ip:
-	 * __mcount is called this way:
-	 * [--sp] = rets; call __mcount; rets = [sp++]
-	 * currently on stack: rets, r2, r0, r1, rets
-	 */
-	r1 = [sp + 16];
 	/* call the tracer */
 	call (p0);
 
@@ -115,8 +109,7 @@
 	/* prepare_ftrace_return(unsigned long *parent, unsigned long self_addr) */
 	r0 = sp;
 	r1 = rets;
-	/* currently on the stack: rets, r2, r0, r1, rets */
-	r0 += 16;
+	r0 += 16;	/* skip the 4 local regs on stack */
 	r1 += -MCOUNT_INSN_SIZE;
 	call _prepare_ftrace_return;
 
_______________________________________________
Linux-kernel-commits mailing list
[email protected]
https://blackfin.uclinux.org/mailman/listinfo/linux-kernel-commits

Reply via email to