lkml.org 
[lkml]   [2017]   [Oct]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH -tip 0/5] kprobes: Abolish jprobe APIs
On Mon, 9 Oct 2017 09:33:50 -0600
Jonathan Corbet <corbet@lwn.net> wrote:

> > Using ftrace to hook to functions
> > =================================
> >
> > Copyright 2017 VMware Inc.
> > Author: Steven Rostedt <srostedt@goodmis.org>
> > License: The GNU Free Documentation License, Version 1.2
> > (dual licensed under the GPL v2)
> >
> > Written for: 4.14
>
> Experience says that strings like this go obsolete in a hurry, so they
> don't really reflect the state of the document. The git history tends to
> be rather more reliable.

And this document is about to become stale by 4.15 ;-)


> > The ftrace FLAGS
> > ================
> >
> > The ftrace_ops flags are all defined and documented in include/linux/ftrace.h.
> > Some of the flags are used for internal infrastructure of ftrace, but the
> > ones that users should be aware of are the following:
> >
> > (All of these are prefixed with FTRACE_OPS_FL_)
>
> I hate to say it, but you'll reduce the cognitive load on the reader if you
> just spell the flags out.
>
> > PER_CPU - When set, the callback can be enabled or disabled per cpu with the
> > following functions:
> >
> > void ftrace_function_local_enable(struct ftrace_ops *ops);
> > void ftrace_function_local_disable(struct ftrace_ops *ops);
> >
> > These two functions must be called with preemption disabled.
>
> s/per cpu/per-CPU/
>
> More importantly, though, what does this actually mean? Presumably that
> the callback is only called if the function is hit on an enabled CPU? It
> seems you can only enable/disable the local CPU? Is the default state
> enabled or disabled? Inquiring minds want to know.

This may be removed by 4.15.

Link: http://lkml.kernel.org/r/20171010130448.4goubbka7e4bguar@hirez.programming.kicks-ass.net

-- Steve

\
 
 \ /
  Last update: 2017-10-10 16:04    [W:0.119 / U:0.092 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site