Messages in this thread | | | Date | Wed, 25 Jun 2003 18:16:33 +0530 | From | "Vamsi Krishna S ." <> | Subject | Re: [patch] kprobes for 2.5.73 with single-stepping out-of-line |
| |
On Wed, Jun 25, 2003 at 01:52:02PM +0200, Andi Kleen wrote: > On Wed, Jun 25, 2003 at 04:11:13PM +0530, Vamsi Krishna S . wrote: > > On Tue, Jun 24, 2003 at 06:01:09PM +0200, Andi Kleen wrote: > > > "Vamsi Krishna S ." <vamsi@in.ibm.com> writes: > > > > > > > > > > +static struct kprobe *current_kprobe; > > > > > > This global variable is quite unclean. It looks like it is for passing > > > function arguments around. Why is it needed? > > > > > This is used for keeping track of the probe that is currently being > > handled. This information is needed to be kept across a > > trap 3 - singlestep - trap 1. So, we set store the current probe in > > this variable while handling trap 3, for use while handling the > > subsequent trap 1. > > But how can this be SMP safe? Do you hold a lock during all this? > Yes.. in the interests of keeping the locking to a minimum, only one probe can be handled at a time, even on SMP.
> -Andi Thanks, Vamsi. -- Vamsi Krishna S. IBM Software Lab, Bangalore. Ph: +91 80 5044959 Internet: vamsi@in.ibm.com - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |