[lkml]   [2004]   [Feb]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Subject/proc visibility patch breaks GDB, etc.

In fs/proc/base.c:proc_pid_lookup(), the patch

if (!task)
goto out;
+ if (!thread_group_leader(task))
+ goto out_drop_task;

inode = proc_pid_make_inode(dir->i_sb, task, PROC_TGID_INO);

means that threads other than the thread group leader don't appear in
the /proc top-level directory. Programs that are informed via pid of
events can no longer find the appropriate process -- for example,
using gdb on a multi-threaded process, or profiling using perfmon.

The immediate symptom is GDB saying:
Could not open /proc/757/status
when 757 is a TID not a PID.

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 14:01    [W:0.048 / U:6.836 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site