<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/kernel/trace/trace_fprobe.c, branch v6.17</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v6.17</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v6.17'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2025-07-28T23:37:52Z</updated>
<entry>
<title>tracing: trace_fprobe: Fix typo of the semicolon</title>
<updated>2025-07-28T23:37:52Z</updated>
<author>
<name>Masami Hiramatsu (Google)</name>
<email>mhiramat@kernel.org</email>
</author>
<published>2025-07-28T02:13:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=133c302a0c60bca1f0a2f5f85ef11e7f5e8f1331'/>
<id>urn:sha1:133c302a0c60bca1f0a2f5f85ef11e7f5e8f1331</id>
<content type='text'>
Fix a typo that uses ',' instead of ';' for line delimiter.

Link: https://lore.kernel.org/linux-trace-kernel/175366879192.487099.5714468217360139639.stgit@mhiramat.tok.corp.google.com/

Signed-off-by: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;
</content>
</entry>
<entry>
<title>tracing: fprobe-event: Allocate string buffers from heap</title>
<updated>2025-07-23T15:21:37Z</updated>
<author>
<name>Masami Hiramatsu (Google)</name>
<email>mhiramat@kernel.org</email>
</author>
<published>2025-07-23T01:31:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d643eaa7082dc3d2438c9ba3ab856eb1c8ad9ffc'/>
<id>urn:sha1:d643eaa7082dc3d2438c9ba3ab856eb1c8ad9ffc</id>
<content type='text'>
Allocate temporary string buffers for fprobe-event from heap
instead of stack. This fixes the stack frame exceed limit error.

Link: https://lore.kernel.org/all/175323426643.57270.6657152008331160704.stgit@devnote2/

Reported-by: kernel test robot &lt;lkp@intel.com&gt;
Closes: https://lore.kernel.org/oe-kbuild-all/202506240416.nZIhDXoO-lkp@intel.com/
Signed-off-by: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;
Reviewed-by: Steven Rostedt (Google) &lt;rostedt@goodmis.org&gt;</content>
</entry>
<entry>
<title>tracing: probe: Allocate traceprobe_parse_context from heap</title>
<updated>2025-07-23T15:21:30Z</updated>
<author>
<name>Masami Hiramatsu (Google)</name>
<email>mhiramat@kernel.org</email>
</author>
<published>2025-07-23T01:30:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=43beb5e89bc8c0b753553964dd0654e2d1aa23f9'/>
<id>urn:sha1:43beb5e89bc8c0b753553964dd0654e2d1aa23f9</id>
<content type='text'>
Instead of allocating traceprobe_parse_context on stack, allocate it
dynamically from heap (slab).

This change is likely intended to prevent potential stack overflow
issues, which can be a concern in the kernel environment where stack
space is limited.

Link: https://lore.kernel.org/all/175323425650.57270.280750740753792504.stgit@devnote2/

Reported-by: kernel test robot &lt;lkp@intel.com&gt;
Closes: https://lore.kernel.org/oe-kbuild-all/202506240416.nZIhDXoO-lkp@intel.com/
Signed-off-by: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;
Reviewed-by: Steven Rostedt (Google) &lt;rostedt@goodmis.org&gt;</content>
</entry>
<entry>
<title>tracing: probes: Sort #include alphabetically</title>
<updated>2025-07-23T15:21:22Z</updated>
<author>
<name>Masami Hiramatsu (Google)</name>
<email>mhiramat@kernel.org</email>
</author>
<published>2025-07-23T01:30:47Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2f02a61d84c629235b8f9684dd0a67e33a2a3d81'/>
<id>urn:sha1:2f02a61d84c629235b8f9684dd0a67e33a2a3d81</id>
<content type='text'>
Sort the #include directives in trace_probe* files alphabetically for
easier maintenance and avoid double includes.
This also groups headers as linux-generic, asm-generic, and local
headers.

Link: https://lore.kernel.org/all/175323424678.57270.11975372127870059007.stgit@devnote2/

Signed-off-by: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;</content>
</entry>
<entry>
<title>tracing: tprobe-events: Register tracepoint when enable tprobe event</title>
<updated>2025-07-02T00:45:35Z</updated>
<author>
<name>Masami Hiramatsu (Google)</name>
<email>mhiramat@kernel.org</email>
</author>
<published>2025-03-31T15:36:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2867495dea86324e984fbafa09474bf92534b652'/>
<id>urn:sha1:2867495dea86324e984fbafa09474bf92534b652</id>
<content type='text'>
As same as fprobe, register tracepoint stub function only when enabling
tprobe events. The major changes are introducing a list of
tracepoint_user and its lock, and tprobe_event_module_nb, which is
another module notifier for module loading/unloading.  By spliting the
lock from event_mutex and a module notifier for trace_fprobe, it
solved AB-BA lock dependency issue between event_mutex and
tracepoint_module_list_mutex.

Link: https://lore.kernel.org/all/174343538901.843280.423773753642677941.stgit@devnote2/

Signed-off-by: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;</content>
</entry>
<entry>
<title>tracing: fprobe-events: Register fprobe-events only when it is enabled</title>
<updated>2025-07-02T00:45:09Z</updated>
<author>
<name>Masami Hiramatsu (Google)</name>
<email>mhiramat@kernel.org</email>
</author>
<published>2025-03-31T15:36:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2db832ec9090d3b5f726f49ad4d0322d6b68a490'/>
<id>urn:sha1:2db832ec9090d3b5f726f49ad4d0322d6b68a490</id>
<content type='text'>
Currently fprobe events are registered when it is defined. Thus it will
give some overhead even if it is disabled. This changes it to register the
fprobe only when it is enabled.

Link: https://lore.kernel.org/all/174343537128.843280.16131300052837035043.stgit@devnote2/

Suggested-by: Steven Rostedt &lt;rostedt@goodmis.org&gt;
Signed-off-by: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;</content>
</entry>
<entry>
<title>tracing: tprobe-events: Support multiple tprobes on the same tracepoint</title>
<updated>2025-07-02T00:44:55Z</updated>
<author>
<name>Masami Hiramatsu (Google)</name>
<email>mhiramat@kernel.org</email>
</author>
<published>2025-03-31T15:36:02Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e3d6e1b9a34c745b635f122ac471a198867cd0ec'/>
<id>urn:sha1:e3d6e1b9a34c745b635f122ac471a198867cd0ec</id>
<content type='text'>
Allow user to set multiple tracepoint-probe events on the same
tracepoint. After the last tprobe-event is removed, the tracepoint
callback is unregistered.

Link: https://lore.kernel.org/all/174343536245.843280.6548776576601537671.stgit@devnote2/

Signed-off-by: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;</content>
</entry>
<entry>
<title>tracing: tprobe-events: Remove mod field from tprobe-event</title>
<updated>2025-07-02T00:44:36Z</updated>
<author>
<name>Masami Hiramatsu (Google)</name>
<email>mhiramat@kernel.org</email>
</author>
<published>2025-03-31T15:35:53Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c135ab4a96e3f65abf83621a0efe007e64f224cf'/>
<id>urn:sha1:c135ab4a96e3f65abf83621a0efe007e64f224cf</id>
<content type='text'>
Remove unneeded 'mod' struct module pointer field from trace_fprobe
because we don't need to save this info.

Link: https://lore.kernel.org/all/174343535351.843280.5868426549023332120.stgit@devnote2/

Signed-off-by: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;</content>
</entry>
<entry>
<title>Merge tag 'probes-fixes-v6.14' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace</title>
<updated>2025-04-08T19:51:34Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2025-04-08T19:51:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bec7dcbc242c6c087cede1a6fdfaeb5d6eaf25bf'/>
<id>urn:sha1:bec7dcbc242c6c087cede1a6fdfaeb5d6eaf25bf</id>
<content type='text'>
Pull probes fixes from Masami Hiramatsu:

 - fprobe: remove fprobe_hlist_node when module unloading

   When a fprobe target module is removed, the fprobe_hlist_node should
   be removed from the fprobe's hash table to prevent reusing
   accidentally if another module is loaded at the same address.

 - fprobe: lock module while registering fprobe

   The module containing the function to be probeed is locked using a
   reference counter until the fprobe registration is complete, which
   prevents use after free.

 - fprobe-events: fix possible UAF on modules

   Basically as same as above, but in the fprobe-events layer we also
   need to get module reference counter when we find the tracepoint in
   the module.

* tag 'probes-fixes-v6.14' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace:
  tracing: fprobe: Cleanup fprobe hash when module unloading
  tracing: fprobe events: Fix possible UAF on modules
  tracing: fprobe: Fix to lock module while registering fprobe
</content>
</entry>
<entry>
<title>tracing: fprobe events: Fix possible UAF on modules</title>
<updated>2025-04-02T14:18:58Z</updated>
<author>
<name>Masami Hiramatsu (Google)</name>
<email>mhiramat@kernel.org</email>
</author>
<published>2025-03-31T14:05:07Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=dd941507a9486252d6fcf11814387666792020f3'/>
<id>urn:sha1:dd941507a9486252d6fcf11814387666792020f3</id>
<content type='text'>
Commit ac91052f0ae5 ("tracing: tprobe-events: Fix leakage of module
refcount") moved try_module_get() from __find_tracepoint_module_cb()
to find_tracepoint() caller, but that introduced a possible UAF
because the module can be unloaded before try_module_get(). In this
case, the module object should be freed too. Thus, try_module_get()
does not only fail but may access to the freed object.

To avoid that, try_module_get() in __find_tracepoint_module_cb()
again.

Link: https://lore.kernel.org/all/174342990779.781946.9138388479067729366.stgit@devnote2/

Fixes: ac91052f0ae5 ("tracing: tprobe-events: Fix leakage of module refcount")
Cc: stable@vger.kernel.org
Signed-off-by: Masami Hiramatsu (Google) &lt;mhiramat@kernel.org&gt;</content>
</entry>
</feed>
