Messages in this thread | | | Date | Sun, 1 Mar 1998 11:52:50 +0100 | From | Jeanette Pauline Middelink <> | Subject | Re: /proc/PID/stat breakage [PATCH] |
| |
On Sat, Feb 28, 1998 at 05:29:07PM -0500, Neil Moore wrote: > Is there any particular reasoning behind the bitmappish TASK_* > constants: > > #define TASK_RUNNING 0 > #define TASK_INTERRUPTIBLE 1 > #define TASK_UNINTERRUPTIBLE 2 > #define TASK_ZOMBIE 4 > #define TASK_STOPPED 8 > #define TASK_SWAPPING 16 > ? > > This breaks proc/PID/stat{,us} -- fs/proc/array.c relied on the old > numbering. Now, zombies report as stopped, and stopped or swapping > processes report as `.'. [snip]
Your patch implies that the state field can only contain a single bit, but the TASK_ bit ordering suggests the possibility for multiple bit settings. (Uninterruptable running zombie?) The switch you patched does not handle such cases. However, after checking some uses of the task state it seems most checking is done by == or !=...
Met vriendelijke groet, Pauline Middelink -- PGP Key fingerprint = DE 6B D0 D9 19 AD A7 A0 58 A3 06 9D B6 34 39 E2 For more details look at my website http://www.polyware.nl/~middelin
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu
| |