Re: Who changed /proc// in 2.6.0-test5-bk9?

Linus Torvalds
2003-10-01T15:11:47Z

On Wed, 1 Oct 2003, Mikael Pettersson wrote:
>
> Linus' 2.6.0-test6 announcement doesn't seem to mention the
> fact that 2.6.0-test5-bk9 fundamentally changed the semantics
> of /proc/self and the /proc/<pid> name space.

Well, that's because the semantics weren't _supposed_ to change. The new
semantics were meant to be a superset of the old behaviour, with just the
added "task" subdirectory that lists the actual threads.

However, you're right that "/proc/self" should likely point into the
_thread_, and not into the task. But it's debatable. You are very likely
the only one who could ever care ;)

> I don't actually disagree with the change, but it took me by
> surprise since neither the 2.6.0-test6 annoucement nor the
> diff between the t5-bk8 and t5-bk9 logs seem to mention it.

Well, the changelog mentions "fix for hidden task problem", since the diff
really is mainly to _add_ threads to the /proc layout. The fact that it
changed /proc/self is actually a bit surprising. Albert?

> (It broke the perfctr driver, but I'm handling that by making
> an already planned API switch now instead of later.)

I think /proc/self most likely _should_ point into the thread, not the
task.

Linus