On Tue, 2010-01-19 at 16:55 +0100, Frederic Weisbecker wrote: > > Also, I see you set an ->unthrottle, but then don't implement it, but > > comment it as todo, which is strange because that implies its broken. If > > there's an ->unthrottle method it will throttle, so if its todo, the > > safest thing is to not set it. > > > Yeah, that's because I have a too vague idea on what is the purpose > of the unthrottle() callback. > > I've read the concerned codes that call this, several times, and I still > can't figure out what happens there, not sure what is meant by throttle > or unthrottle there :-/
OK, so not setting it is relatively safe. As to what it does, it has to undo everything you do when perf_event_overflow() returns true, which happens when ->unthrottle is set and we get more than sysctl_perf_event_sample_rate/HZ events in a jiffy. If you look at the x86 implementation, you'll see that we simply disable the hardware counter when the overflow call returns true, so the unthrottle() callback simply enables it again. ------------------------------------------------------------------------------ Throughout its 18-year history, RSA Conference consistently attracts the world's best and brightest in the field, creating opportunities for Conference attendees to learn about information security's most important issues through interactions with peers, luminaries and emerging and established companies. http://p.sf.net/sfu/rsaconf-dev2dev _______________________________________________ perfmon2-devel mailing list perfmon2-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/perfmon2-devel