)]}'
{
  "log": [
    {
      "commit": "da7978b0348d497688541e2d2f5739aa2a2c334f",
      "tree": "f4f55bf4293ff203f598e7a57959da1c5a7ad295",
      "parents": [
        "dfc7064500061677720fa26352963c772d3ebe6b"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri May 23 13:04:41 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Sat May 24 09:56:10 2008 -0700"
      },
      "message": "signals: fix sigqueue_free() vs __exit_signal() race\n\n__exit_signal() does flush_sigqueue(tsk-\u003epending) outside of -\u003esiglock.\nThis can race with another thread doing sigqueue_free(), we can free the\nsame SIGQUEUE_PREALLOC sigqueue twice or corrupt the pending-\u003elist.\n\nNote that even sys_exit_group() can trigger this race, not only\nsys_timer_delete().\n\nMove the callsite of flush_sigqueue(tsk-\u003epending) under -\u003esiglock.\n\nThis patch doesn\u0027t touch flush_sigqueue(-\u003eshared_pending) below, it is\ncalled when there are no other threads which can play with signals, and\nsigqueue_free() can\u0027t be used outside of our thread group.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "9f3acc3140444a900ab280de942291959f0f615d",
      "tree": "0d7f3f9698071ff90fb9a127a4c6e86e1c37c945",
      "parents": [
        "a2dcb44c3c5a8151d2d9f6ac8ad0789efcdbe184"
      ],
      "author": {
        "name": "Al Viro",
        "email": "viro@zeniv.linux.org.uk",
        "time": "Thu Apr 24 07:44:08 2008 -0400"
      },
      "committer": {
        "name": "Al Viro",
        "email": "viro@zeniv.linux.org.uk",
        "time": "Thu May 01 13:08:16 2008 -0400"
      },
      "message": "[PATCH] split linux/file.h\n\nInitial splitoff of the low-level stuff; taken to fdtable.h\n\nSigned-off-by: Al Viro \u003cviro@zeniv.linux.org.uk\u003e\n"
    },
    {
      "commit": "7d8da0962eaee30b4a380ded177349bfbdd6ac46",
      "tree": "cfbdb6d94922264e7e06892275f1e4d5a29017a6",
      "parents": [
        "83beaf3c6c75b36b7c9be7f555c8cf7797842cc5"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Wed Apr 30 00:54:27 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Wed Apr 30 08:29:49 2008 -0700"
      },
      "message": "pids: __set_special_pids: use change_pid() helper\n\nUse change_pid() instead of detach_pid() + attach_pid() in\n__set_special_pids().\n\nThis way task_session() is not NULL in between.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc:  \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nCc: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "53b6f9fbd3b63af14b4f6268e8b5b80d178d05bc",
      "tree": "93a5bd26974e07a3d7fa20dc17c8b70daacc1d85",
      "parents": [
        "2800d8d19e51414403df8144eaa214bb03400b87"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Wed Apr 30 00:53:13 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Wed Apr 30 08:29:38 2008 -0700"
      },
      "message": "ptrace: introduce ptrace_reparented() helper\n\nAdd another trivial helper for the sake of grep.  It also auto-documents the\nfact that -\u003eparent !\u003d real_parent implies -\u003eptrace.\n\nNo functional changes.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "2800d8d19e51414403df8144eaa214bb03400b87",
      "tree": "d5b01302c7109d7ffdc140ce8d6e31cebcdb233a",
      "parents": [
        "376e1d2531860358c8a79fecf5f4f42994d03c4d"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Wed Apr 30 00:53:12 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Wed Apr 30 08:29:38 2008 -0700"
      },
      "message": "document de_thread() with exit_notify() connection\n\nAdd a couple of small comments, it is not easy to see what this code does.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "376e1d2531860358c8a79fecf5f4f42994d03c4d",
      "tree": "7d90aa39ee7250e1ba0593fa927118b4a9c911e9",
      "parents": [
        "d839fd4d2e95a5fbc4d50aa9d17eed6a5f2094e6"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Wed Apr 30 00:53:12 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Wed Apr 30 08:29:38 2008 -0700"
      },
      "message": "reparent_thread: use same_thread_group()\n\nTrivial, use same_thread_group() in reparent_thread().\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "d839fd4d2e95a5fbc4d50aa9d17eed6a5f2094e6",
      "tree": "bfeccf3201208a9ce0e994cff9eacdc4647002a6",
      "parents": [
        "5a8da0ea82db6fa9737041381079fd16f25dcce2"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Wed Apr 30 00:53:11 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Wed Apr 30 08:29:38 2008 -0700"
      },
      "message": "ptrace: introduce task_detached() helper\n\nexit.c has numerous \"-\u003eexit_signal \u003d\u003d -1\" comparisons, this check is subtle\nand deserves a helper.  Imho makes the code more parseable for humans.  At\nleast it\u0027s surely more greppable.\n\nAlso, a couple of whitespace cleanups. No functional changes.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "bfc4b0890af566940de6e7aeb4b5faf46d3c3513",
      "tree": "d3c0d7ad6e3d619345acf7130f053514177bf5c7",
      "parents": [
        "573cf9ad72c13750e86c91de43477e9dfb440523"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Wed Apr 30 00:52:36 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Wed Apr 30 08:29:33 2008 -0700"
      },
      "message": "signals: do_group_exit(): use signal_group_exit() more consistently\n\ndo_group_exit() checks SIGNAL_GROUP_EXIT to avoid taking sighand-\u003esiglock.\nSince ed5d2cac114202fe2978a9cbcab8f5032796d538 exec() doesn\u0027t set this\nflag, we should use signal_group_exit().\n\nThis is not needed for correctness, but can speedup the multithreaded exec\nand makes the code more consistent.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "cf475ad28ac35cc9ba612d67158f29b73b38b05d",
      "tree": "2c7cd568d00357bd42643ea602884e731cc24f26",
      "parents": [
        "29486df325e1fe6e1764afcb19e3370804c2b002"
      ],
      "author": {
        "name": "Balbir Singh",
        "email": "balbir@linux.vnet.ibm.com",
        "time": "Tue Apr 29 01:00:16 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Tue Apr 29 08:06:10 2008 -0700"
      },
      "message": "cgroups: add an owner to the mm_struct\n\nRemove the mem_cgroup member from mm_struct and instead adds an owner.\n\nThis approach was suggested by Paul Menage.  The advantage of this approach\nis that, once the mm-\u003eowner is known, using the subsystem id, the cgroup\ncan be determined.  It also allows several control groups that are\nvirtually grouped by mm_struct, to exist independent of the memory\ncontroller i.e., without adding mem_cgroup\u0027s for each controller, to\nmm_struct.\n\nA new config option CONFIG_MM_OWNER is added and the memory resource\ncontroller selects this config option.\n\nThis patch also adds cgroup callbacks to notify subsystems when mm-\u003eowner\nchanges.  The mm_cgroup_changed callback is called with the task_lock() of\nthe new task held and is called just prior to changing the mm-\u003eowner.\n\nI am indebted to Paul Menage for the several reviews of this patchset and\nhelping me make it lighter and simpler.\n\nThis patch was tested on a powerpc box, it was compiled with both the\nMM_OWNER config turned on and off.\n\nAfter the thread group leader exits, it\u0027s moved to init_css_state by\ncgroup_exit(), thus all future charges from runnings threads would be\nredirected to the init_css_set\u0027s subsystem.\n\nSigned-off-by: Balbir Singh \u003cbalbir@linux.vnet.ibm.com\u003e\nCc: Pavel Emelianov \u003cxemul@openvz.org\u003e\nCc: Hugh Dickins \u003chugh@veritas.com\u003e\nCc: Sudhir Kumar \u003cskumar@linux.vnet.ibm.com\u003e\nCc: YAMAMOTO Takashi \u003cyamamoto@valinux.co.jp\u003e\nCc: Hirokazu Takahashi \u003ctaka@valinux.co.jp\u003e\nCc: David Rientjes \u003crientjes@google.com\u003e,\nCc: Balbir Singh \u003cbalbir@linux.vnet.ibm.com\u003e\nAcked-by: KAMEZAWA Hiroyuki \u003ckamezawa.hiroyu@jp.fujitsu.com\u003e\nAcked-by: Pekka Enberg \u003cpenberg@cs.helsinki.fi\u003e\nReviewed-by: Paul Menage \u003cmenage@google.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "f0be3d32b05d3fea2fcdbbb81a39dac2a7163169",
      "tree": "5794ce6a8befbce82cd3e44ff15fbf3bb5f2f3bf",
      "parents": [
        "3b1163006332302117b1b2acf226d4014ff46525"
      ],
      "author": {
        "name": "Lee Schermerhorn",
        "email": "lee.schermerhorn@hp.com",
        "time": "Mon Apr 28 02:13:08 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Mon Apr 28 08:58:23 2008 -0700"
      },
      "message": "mempolicy: rename mpol_free to mpol_put\n\nThis is a change that was requested some time ago by Mel Gorman.  Makes sense\nto me, so here it is.\n\nNote: I retain the name \"mpol_free_shared_policy()\" because it actually does\nfree the shared_policy, which is NOT a reference counted object.  However, ...\n\nThe mempolicy object[s] referenced by the shared_policy are reference counted,\nso mpol_put() is used to release the reference held by the shared_policy.  The\nmempolicy might not be freed at this time, because some task attached to the\nshared object associated with the shared policy may be in the process of\nallocating a page based on the mempolicy.  In that case, the task performing\nthe allocation will hold a reference on the mempolicy, obtained via\nmpol_shared_policy_lookup().  The mempolicy will be freed when all tasks\nholding such a reference have called mpol_put() for the mempolicy.\n\nSigned-off-by: Lee Schermerhorn \u003clee.schermerhorn@hp.com\u003e\nCc: Christoph Lameter \u003cclameter@sgi.com\u003e\nCc: David Rientjes \u003crientjes@google.com\u003e\nCc: Mel Gorman \u003cmel@csn.ul.ie\u003e\nCc: Andi Kleen \u003cak@suse.de\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "3b1253880b7a9e6db54b943b2d40bcf2202f58ab",
      "tree": "5301be7b4d4310faa8db5a0d027b81421e36570e",
      "parents": [
        "fd8328be874f4190a811c58cd4778ec2c74d2c05"
      ],
      "author": {
        "name": "Al Viro",
        "email": "viro@zeniv.linux.org.uk",
        "time": "Tue Apr 22 05:31:30 2008 -0400"
      },
      "committer": {
        "name": "Al Viro",
        "email": "viro@zeniv.linux.org.uk",
        "time": "Fri Apr 25 09:23:59 2008 -0400"
      },
      "message": "[PATCH] sanitize unshare_files/reset_files_struct\n\n* let unshare_files() give caller the displaced files_struct\n* don\u0027t bother with grabbing reference only to drop it in the\n  caller if it hadn\u0027t been shared in the first place\n* in that form unshare_files() is trivially implemented via\n  unshare_fd(), so we eliminate the duplicate logics in fork.c\n* reset_files_struct() is not just only called for current;\n  it will break the system if somebody ever calls it for anything\n  else (we can\u0027t modify -\u003efiles of somebody else).  Lose the\n  task_struct * argument.\n\nSigned-off-by: Al Viro \u003cviro@zeniv.linux.org.uk\u003e\n"
    },
    {
      "commit": "fd8328be874f4190a811c58cd4778ec2c74d2c05",
      "tree": "b44ae8e99ce96a1a4739b04d4d1a23c40ab8b163",
      "parents": [
        "6b335d9c80d7f3c2a3f6545f664ae9007a0f3821"
      ],
      "author": {
        "name": "Al Viro",
        "email": "viro@zeniv.linux.org.uk",
        "time": "Tue Apr 22 05:11:59 2008 -0400"
      },
      "committer": {
        "name": "Al Viro",
        "email": "viro@zeniv.linux.org.uk",
        "time": "Fri Apr 25 09:23:53 2008 -0400"
      },
      "message": "[PATCH] sanitize handling of shared descriptor tables in failing execve()\n\n* unshare_files() can fail; doing it after irreversible actions is wrong\n  and de_thread() is certainly irreversible.\n* since we do it unconditionally anyway, we might as well do it in do_execve()\n  and save ourselves the PITA in binfmt handlers, etc.\n* while we are at it, binfmt_som actually leaked files_struct on failure.\n\nAs a side benefit, unshare_files(), put_files_struct() and reset_files_struct()\nbecome unexported.\n\nSigned-off-by: Al Viro \u003cviro@zeniv.linux.org.uk\u003e\n"
    },
    {
      "commit": "1ec7f1ddbe5ba49f7b10c3b129d6d5c90c43526c",
      "tree": "c5bd86c748fe42b14698aa29a5b4dadf981cfcfd",
      "parents": [
        "9b4f526cdc0f95f635607dfba6ac788b3deca188"
      ],
      "author": {
        "name": "Al Viro",
        "email": "viro@zeniv.linux.org.uk",
        "time": "Tue Apr 22 05:35:42 2008 -0400"
      },
      "committer": {
        "name": "Al Viro",
        "email": "viro@zeniv.linux.org.uk",
        "time": "Tue Apr 22 19:55:09 2008 -0400"
      },
      "message": "[PATCH] get rid of __exit_files(), __exit_fs() and __put_fs_struct()\n\nThe only reason to have separated __...() for those was to keep them inlined\nfor local users in exit.c.  Since Alexey removed the inline on those, there\u0027s\nno reason whatsoever to keep them around; just collapse with normal variants.\n\nSigned-off-by: Al Viro \u003cviro@zeniv.linux.org.uk\u003e\n"
    },
    {
      "commit": "54a015104136974262afa4b8ddd943ea70dec8a2",
      "tree": "713f0c1f4d0afe62e5c568a424e309f70388cf7f",
      "parents": [
        "783e391b7b5b273cd20856d8f6f4878da8ec31b3"
      ],
      "author": {
        "name": "Roland McGrath",
        "email": "roland@redhat.com",
        "time": "Thu Apr 10 15:37:38 2008 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Thu Apr 10 17:28:26 2008 -0700"
      },
      "message": "asmlinkage_protect replaces prevent_tail_call\n\nThe prevent_tail_call() macro works around the problem of the compiler\nclobbering argument words on the stack, which for asmlinkage functions\nis the caller\u0027s (user\u0027s) struct pt_regs.  The tail/sibling-call\noptimization is not the only way that the compiler can decide to use\nstack argument words as scratch space, which we have to prevent.\nOther optimizations can do it too.\n\nUntil we have new compiler support to make \"asmlinkage\" binding on the\ncompiler\u0027s own use of the stack argument frame, we have work around all\nthe manifestations of this issue that crop up.\n\nMore cases seem to be prevented by also keeping the incoming argument\nvariables live at the end of the function.  This makes their original\nstack slots attractive places to leave those variables, so the compiler\ntends not clobber them for something else.  It\u0027s still no guarantee, but\nit handles some observed cases that prevent_tail_call() did not.\n\nSigned-off-by: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "6efcae460186c0c1c94afff58a92784e1fc0d10b",
      "tree": "da67b86b65e8dde1f52245e25b1889f87cc96b4e",
      "parents": [
        "84c6f6046c5a2189160a8f0dca8b90427bf690ea"
      ],
      "author": {
        "name": "Roland McGrath",
        "email": "roland@redhat.com",
        "time": "Sat Mar 08 11:41:22 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Sat Mar 08 11:54:00 2008 -0800"
      },
      "message": "Fix waitid si_code regression\n\nIn commit ee7c82da830ea860b1f9274f1f0cdf99f206e7c2 (\"wait_task_stopped:\nsimplify and fix races with SIGCONT/SIGKILL/untrace\"), the magic (short)\ncast when storing si_code was lost in wait_task_stopped.  This leaks the\nin-kernel CLD_* values that do not match what userland expects.\n\nSigned-off-by: Roland McGrath \u003croland@redhat.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "821c7de7194e77afee1a69d50830a329a6d9af9f",
      "tree": "6755cb5f57822c142b228ad8ca817c18b8f31884",
      "parents": [
        "05e83df624fe682bb8571cdb2c6d5284a99c3066"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Sun Mar 02 21:44:44 2008 +0300"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon Mar 03 14:53:16 2008 -0800"
      },
      "message": "exit_notify: fix kill_orphaned_pgrp() usage with mt exit\n\n1. exit_notify() always calls kill_orphaned_pgrp(). This is wrong, we\n   should do this only when the whole process exits.\n\n2. exit_notify() uses \"current\" as \"ignored_task\", obviously wrong.\n   Use -\u003egroup_leader instead.\n\nTest case:\n\n\tvoid hup(int sig)\n\t{\n\t\tprintf(\"HUP received\\n\");\n\t}\n\n\tvoid *tfunc(void *arg)\n\t{\n\t\tsleep(2);\n\t\tprintf(\"sub-thread exited\\n\");\n\t\treturn NULL;\n\t}\n\n\tint main(int argc, char *argv[])\n\t{\n\t\tif (!fork()) {\n\t\t\tsignal(SIGHUP, hup);\n\t\t\tkill(getpid(), SIGSTOP);\n\t\t\texit(0);\n\t\t}\n\n\t\tpthread_t thr;\n\t\tpthread_create(\u0026thr, NULL, tfunc, NULL);\n\n\t\tsleep(1);\n\t\tprintf(\"main thread exited\\n\");\n\t\tsyscall(__NR_exit, 0);\n\n\t\treturn 0;\n\t}\n\noutput:\n\n\tmain thread exited\n\tHUP received\n\tHangup\n\nWith this patch the output is:\n\n\tmain thread exited\n\tsub-thread exited\n\tHUP received\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "05e83df624fe682bb8571cdb2c6d5284a99c3066",
      "tree": "c55df1d1258f2fae4069aa7954a2c74ba1831192",
      "parents": [
        "f49ee505b1ecb5960984880740f09aba87f870dc"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Sun Mar 02 21:44:42 2008 +0300"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon Mar 03 14:53:16 2008 -0800"
      },
      "message": "will_become_orphaned_pgrp: partially fix insufficient -\u003eexit_state check\n\np-\u003eexit_state !\u003d 0 doesn\u0027t mean this process is dead, it may have\nsub-threads.  Change the code to use \"p-\u003eexit_state \u0026\u0026 thread_group_empty(p)\"\ninstead.\n\nWithout this patch, ^Z doesn\u0027t deliver SIGTSTP to the foreground process\nif the main thread has exited.\n\nHowever, the new check is not perfect either.  There is a window when\nexit_notify() drops tasklist and before release_task().  Suppose that\nthe last (non-leader) thread exits.  This means that entire group exits,\nbut thread_group_empty() is not true yet.\n\nAs Eric pointed out, is_global_init() is wrong as well, but I did not\ndare to do other changes.\n\nJust for the record, has_stopped_jobs() is absolutely wrong too.  But we\ncan\u0027t fix it now, we should first fix SIGNAL_STOP_STOPPED issues.\n\nEven with this patch ^Z doesn\u0027t play well with the dead main thread.\nThe task is stopped correctly but do_wait(WSTOPPED) won\u0027t see it.  This\nis another unrelated issue, will be (hopefully) fixed separately.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "f49ee505b1ecb5960984880740f09aba87f870dc",
      "tree": "2ff1289ecd2741d3f9d3a298662bc9b5a6266a3d",
      "parents": [
        "5ce2087ed0eb424e0889bdc9102727f65d2ecdde"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Sun Mar 02 21:44:40 2008 +0300"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon Mar 03 14:53:16 2008 -0800"
      },
      "message": "introduce kill_orphaned_pgrp() helper\n\nFactor out the common code in reparent_thread() and exit_notify().\n\nNo functional changes.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "6ac08c39a16f72c2d3e845cb6849a1392fa03e80",
      "tree": "d7603571e9ab3ea4b57b7901211320e48d0c5ed8",
      "parents": [
        "5dd784d04924be5d8bc066aded0ec3274b20e612"
      ],
      "author": {
        "name": "Jan Blunck",
        "email": "jblunck@suse.de",
        "time": "Thu Feb 14 19:34:38 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Thu Feb 14 21:13:33 2008 -0800"
      },
      "message": "Use struct path in fs_struct\n\n* Use struct path in fs_struct.\n\nSigned-off-by: Andreas Gruenbacher \u003cagruen@suse.de\u003e\nSigned-off-by: Jan Blunck \u003cjblunck@suse.de\u003e\nAcked-by: Christoph Hellwig \u003chch@lst.de\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "7ad5b3a505e68cfdc342933d6e0fc0eaa5e0a4f7",
      "tree": "6715ffd8df509d3d53dea581bb97418a21bc7cbc",
      "parents": [
        "fc9b52cd8f5f459b88adcf67c47668425ae31a78"
      ],
      "author": {
        "name": "Harvey Harrison",
        "email": "harvey.harrison@gmail.com",
        "time": "Fri Feb 08 04:19:53 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:31 2008 -0800"
      },
      "message": "kernel: remove fastcall in kernel/*\n\n[akpm@linux-foundation.org: coding-style fixes]\nSigned-off-by: Harvey Harrison \u003charvey.harrison@gmail.com\u003e\nAcked-by: Ingo Molnar \u003cmingo@elte.hu\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "6c5f3e7b43300508fe3947ff3cfff0f86043bb57",
      "tree": "9843b8897ec3357b09f62bb6423cd4753e1d4516",
      "parents": [
        "fea9d175545b38cb3e84569400419eb81bc90fa3"
      ],
      "author": {
        "name": "Pavel Emelyanov",
        "email": "xemul@openvz.org",
        "time": "Fri Feb 08 04:19:20 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:29 2008 -0800"
      },
      "message": "Pidns: make full use of xxx_vnr() calls\n\nSome time ago the xxx_vnr() calls (e.g.  pid_vnr or find_task_by_vpid) were\n_all_ converted to operate on the current pid namespace.  After this each call\nlike xxx_nr_ns(foo, current-\u003ensproxy-\u003epid_ns) is nothing but a xxx_vnr(foo)\none.\n\nSwitch all the xxx_nr_ns() callers to use the xxx_vnr() calls where\nappropriate.\n\nSigned-off-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nReviewed-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nCc: Balbir Singh \u003cbalbir@in.ibm.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "161550d74c07303ffa6187ba776f62df5a906a21",
      "tree": "c47ece377d76141ba48b3e7ffd2d7dbd31c906e1",
      "parents": [
        "5dee1707dfbfc55eb7569b9ae5abaf932bd4c377"
      ],
      "author": {
        "name": "Eric W. Biederman",
        "email": "ebiederm@xmission.com",
        "time": "Fri Feb 08 04:19:14 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:27 2008 -0800"
      },
      "message": "pid: sys_wait... fixes\n\nThis modifies do_wait and eligible child to take a pair of enum pid_type\nand struct pid *pid to precisely specify what set of processes are eligible\nto be waited for, instead of the raw pid_t value from sys_wait4.\n\nThis fixes a bug in sys_waitid where you could not wait for children in\njust process group 1.\n\nThis fixes a pid namespace crossing case in eligible_child.  Allowing us to\nwait for a processes in our current process group even if our current\nprocess group \u003d\u003d 0.\n\nThis allows the no child with this pid case to be optimized.  This allows\nus to optimize the pid membership test in eligible child to be optimized.\n\nThis even closes a theoretical pid wraparound race where in a threaded\nparent if two threads are waiting for the same child and one thread picks\nup the child and the pid numbers wrap around and generate another child\nwith that same pid before the other thread is scheduled (teribly insanely\nunlikely) we could end up waiting on the second child with the same pid#\nand not discover that the specific child we were waiting for has exited.\n\n[akpm@linux-foundation.org: coding-style fixes]\nSigned-off-by: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "5dee1707dfbfc55eb7569b9ae5abaf932bd4c377",
      "tree": "6e162f61f9645f790aa14cb4146882b918bb0286",
      "parents": [
        "6806aac6d282d58b97763f5e17e2787e62c3b440"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:13 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:27 2008 -0800"
      },
      "message": "move the related code from exit_notify() to exit_signals()\n\nThe previous bugfix was not optimal, we shouldn\u0027t care about group stop\nwhen we are the only thread or the group stop is in progress.  In that case\nnothing special is needed, just set PF_EXITING and return.\n\nAlso, take the related \"TIF_SIGPENDING re-targeting\" code from exit_notify().\n\nSo, from the performance POV the only difference is that we don\u0027t trust\n!signal_pending() until we take -\u003esiglock.  But this in fact fixes another\n___pure___ theoretical minor race.  __group_complete_signal() finds the\ntask without PF_EXITING and chooses it as the target for signal_wake_up().\nBut nothing prevents this task from exiting in between without noticing the\npending signal and thus unpredictably delaying the actual delivery.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Davide Libenzi \u003cdavidel@xmailserver.org\u003e\nCc: Ingo Molnar \u003cmingo@elte.hu\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "d12619b5ff5664623524aef796514d1946ea3b4a",
      "tree": "23140ca0148f9154440d3056e2040d8df468a24b",
      "parents": [
        "430c623121ea88ca80595c99fdc63b7f8a803ae5"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:12 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:27 2008 -0800"
      },
      "message": "fix group stop with exit race\n\ndo_signal_stop() counts all sub-thread and sets -\u003egroup_stop_count\naccordingly.  Every thread should decrement -\u003egroup_stop_count and stop,\nthe last one should notify the parent.\n\nHowever a sub-thread can exit before it notices the signal_pending(), or it\nmay be somewhere in do_exit() already.  In that case the group stop never\nfinishes properly.\n\nNote: this is a minimal fix, we can add some optimizations later.  Say we\ncan return quickly if thread_group_empty().  Also, we can move some signal\nrelated code from exit_notify() to exit_signals().\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: Davide Libenzi \u003cdavidel@xmailserver.org\u003e\nCc: Ingo Molnar \u003cmingo@elte.hu\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "297bd42b15daed02453ff59ce6d31216a58b0398",
      "tree": "4b1fecc6e285c50d55961ed85e013419f5810164",
      "parents": [
        "8520d7c7f8611216e3b270becec95bb35b6899d4"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:10 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:27 2008 -0800"
      },
      "message": "move daemonized kernel threads into the swapper\u0027s session\n\nDaemonized kernel threads run in the init\u0027s session. This doesn\u0027t match the\nbehaviour of kthread_create()\u0027ed threads, and this is one of the 2 reasons\nwhy we need a special hack in sys_setsid().\n\nNow that set_special_pids() was changed to use struct pid, not pid_t, we can\nuse init_struct_pid and set 0,0 special pids.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nCc: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "8520d7c7f8611216e3b270becec95bb35b6899d4",
      "tree": "77001e6830bb415590067e9d4be24cd8bdd36219",
      "parents": [
        "e4cc0a9c876d4d4eadaef97a2bff4a199946d202"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:09 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:27 2008 -0800"
      },
      "message": "teach set_special_pids() to use struct pid\n\nChange set_special_pids() to work with struct pid, not pid_t from global name\nspace. This again speedups and imho cleanups the code, also a preparation for\nthe next patch.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nAcked-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "c543f1ee08ea6c2176dbdc47df0d0f6357c88713",
      "tree": "ae2d4de96aabbafd3792316d14f40330ec64572d",
      "parents": [
        "3a515e4a62dbf7e4c213740268a5267faa69e5b2"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:07 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:27 2008 -0800"
      },
      "message": "wait_task_zombie: remove -\u003eexit_state/exit_signal checks for WNOWAIT\n\nThe first \"p-\u003eexit_state !\u003d EXIT_ZOMBIE\" check doesn\u0027t make too much sense.\nThe exit_state was EXIT_ZOMBIE when the function was called, and another\nthread can change it to EXIT_DEAD right after the check.\n\nThe second condition is not possible, detached non-traced threads were already\nfiltered out by eligible_child(), we didn\u0027t drop tasklist since then.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "3a515e4a62dbf7e4c213740268a5267faa69e5b2",
      "tree": "51f98e662c80ca5de628f09c5eb24d18f1794f6c",
      "parents": [
        "f2cc3eb133baa2e9dc8efd40f417106b2ee520f3"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:07 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:26 2008 -0800"
      },
      "message": "wait_task_continued/zombie: don\u0027t use task_pid_nr_ns() lockless\n\nSurprise, the other two wait_task_*() functions also abuse the\ntask_pid_nr_ns() function, and may cause read-after-free or report nr \u003d\u003d 0\nin wait_task_continued().  wait_task_zombie() doesn\u0027t have this problem,\nbut it is still better to cache pid_t rather than call task_pid_nr_ns()\nthree times on the saved pid_namespace.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "f2cc3eb133baa2e9dc8efd40f417106b2ee520f3",
      "tree": "37b08158ee5296e79a61aad086be36c742825e3b",
      "parents": [
        "96fabbf55ae79826f2e8a86f4066d7e8834315ae"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:06 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:26 2008 -0800"
      },
      "message": "do_wait: fix security checks\n\nImho, the current usage of security_task_wait() is not logical.\n\nSuppose we have the single child p, and security_task_wait(p) return\n-EANY.  In that case waitpid(-1) returns this error.  Why? Isn\u0027t it\nbetter to return ECHLD? We don\u0027t really have reapable children.\n\nNow suppose that child was stolen by gdb.  In that case we find this\nchild on -\u003eptrace_children and set flag \u003d 1, but we don\u0027t check that the\nchild was denied.  So, do_wait(..., WNOHANG) returns 0, this doesn\u0027t\nmatch the behaviour above.  Without WNOHANG do_wait() blocks only to\nreturn the error later, when the child will be untraced.  Inho, really\nstrange.\n\nI think eligible_child() should return the error only if the child\u0027s pid\nwas requested explicitly, otherwise we should silently ignore the tasks\nwhich were nacked by security_task_wait().\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nCc: Chris Wright \u003cchrisw@sous-sol.org\u003e\nCc: Eric Paris \u003ceparis@redhat.com\u003e\nCc: James Morris \u003cjmorris@namei.org\u003e\nCc: Stephen Smalley \u003csds@tycho.nsa.gov\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "96fabbf55ae79826f2e8a86f4066d7e8834315ae",
      "tree": "e4b3259a744a1e0c8fa477e3dfba02e4ea1993c8",
      "parents": [
        "1bad95c3bee183719e15eebffef66afc3fb3f8b0"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:04 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:26 2008 -0800"
      },
      "message": "do_wait: cleanup delay_group_leader() usage\n\neligible_child() \u003d\u003d 2 means delay_group_leader().  With the previous patch\nthis only matters for EXIT_ZOMBIE task, we can move that special check to\nthe only place it is really needed.\n\nAlso, with this patch we don\u0027t skip security_task_wait() for the group\nleaders in a non-empty thread group.  I don\u0027t really understand the exact\nsemantics of security_task_wait(), but imho this change is a bugfix.\n\nAlso rearrange the code a bit to kill an ugly \"check_continued\" backdoor.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Eric Paris \u003ceparis@redhat.com\u003e\nCc: James Morris \u003cjmorris@namei.org\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nCc: Stephen Smalley \u003csds@tycho.nsa.gov\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "1bad95c3bee183719e15eebffef66afc3fb3f8b0",
      "tree": "b875db7096572a69f3906db631708d7e75e22f3f",
      "parents": [
        "20686a309aa98c518adbbd9b57cdbb1804143deb"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:03 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:26 2008 -0800"
      },
      "message": "wait_task_stopped(): remove unneeded delay_group_leader check\n\nwait_task_stopped() doesn\u0027t need the \"delay_group_leader\" parameter.  If\nthe child is not traced it must be a group leader.  With or without\nsubthreads -\u003egroup_stop_count \u003d\u003d 0 when the whole task is stopped.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Mika Penttila \u003cmika.penttila@kolumbus.fi\u003e\nAcked-by: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "9cbab8100538efdd93aeae6fc37787d986f2f558",
      "tree": "a34cf1b3d6bdb3b2bbede801a9acdb23d35903ff",
      "parents": [
        "ee7c82da830ea860b1f9274f1f0cdf99f206e7c2"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:02 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:26 2008 -0800"
      },
      "message": "do_wait: factor out \"retval !\u003d 0\" checks\n\nEvery branch if the main \"if\" statement does the same code at the end.  Move\nit down.  Also, fix the indentation.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "ee7c82da830ea860b1f9274f1f0cdf99f206e7c2",
      "tree": "449477479b25ec73a1c2242723b3fb1c09cd936d",
      "parents": [
        "6405f7f4675884b671bee66678e1c2859bdb0e56"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:19:01 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:26 2008 -0800"
      },
      "message": "wait_task_stopped: simplify and fix races with SIGCONT/SIGKILL/untrace\n\nwait_task_stopped() has multiple races with SIGCONT/SIGKILL.  tasklist_lock\ndoes not pin the child in TASK_TRACED/TASK_STOPPED stated, almost all info\nreported (including exit_code) may be wrong.\n\nIn fact, the code under write_lock_irq(tasklist_lock) is not safe.  The child\nmay be PTRACE_DETACH\u0027ed at this time by another subthread, in that case it is\npossible we are no longer its -\u003eparent.\n\nChange wait_task_stopped() to take -\u003esiglock before inspecting the task.  This\nguarantees that the child can\u0027t resume and (for example) clear its\n-\u003eexit_code, so we don\u0027t need to use xchg(\u0026p-\u003eexit_code) and re-check.  The\nonly exception is ptrace_stop() which changes -\u003estate and -\u003eexit_code without\n-\u003esiglock held during abort.  But this can only happen if both the tracer and\nthe tracee are dying (coredump is in progress), we don\u0027t care.\n\nWith this patch wait_task_stopped() doesn\u0027t move the child to the end of\nthe -\u003eparent list on success.  This optimization could be restored, but\nin that case we have to take write_lock(tasklist) and do some nasty\nchecks.\n\nAlso change the do_wait() since we don\u0027t return EAGAIN any longer.\n\n[akpm@linux-foundation.org: fix up after Willy renamed everything]\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "34a1738f7da0b3d28d4b066d03a78f46b8cab68f",
      "tree": "4e7312642adb1aab0ba9fa4f29b4912c9ee035d2",
      "parents": [
        "6b39c7bfbd1436836c0fb34c5b437fda1a7a3dd4"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:18:59 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:26 2008 -0800"
      },
      "message": "kill my_ptrace_child()\n\nNow that my_ptrace_child() is trivial we can use the \"p-\u003eptrace \u0026 PT_PTRACED\"\ninline and simplify the corresponding logic in do_wait: we can\u0027t find the\nchild in TASK_TRACED state without PT_PTRACED flag set, ptrace_untrace()\neither sets TASK_STOPPED or wakes up the tracee.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: Roland McGrath \u003croland@redhat.com\u003e\nCc: Christoph Hellwig \u003chch@lst.de\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "6b39c7bfbd1436836c0fb34c5b437fda1a7a3dd4",
      "tree": "60d3d9719eef3076527fcbf9c3cb362fe0f52d61",
      "parents": [
        "01b8b07a5d77d22e609267dcae74d15e3e9c5f13"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Fri Feb 08 04:18:58 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Feb 08 09:22:26 2008 -0800"
      },
      "message": "kill PT_ATTACHED\n\nSince the patch\n\n\t\"Fix ptrace_attach()/ptrace_traceme()/de_thread() race\"\n\tcommit f5b40e363ad6041a96e3da32281d8faa191597b9\n\nwe set PT_ATTACHED and change child-\u003eparent \"atomically\" wrt task_list lock.\n\nThis means we can remove the checks like \"PT_ATTACHED \u0026\u0026 -\u003eparent !\u003d ptracer\"\nwhich were needed to catch the \"ptrace attach is in progress\" case.  We can\nalso remove the flag itself since nobody else uses it.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: Roland McGrath \u003croland@redhat.com\u003e\nCc: Christoph Hellwig \u003chch@lst.de\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "0a76fe8e50ee93a9d4a1badb1ec995852a6bcaf1",
      "tree": "57a6a1b8bdb101a1ac5fd54971bfe172de949da0",
      "parents": [
        "f10db6277dfd6dffb80b2182a256d35adb3134bc"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Wed Feb 06 01:37:06 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Feb 06 10:41:04 2008 -0800"
      },
      "message": "do_wait: remove one \"else if\" branch\n\nMinor cleanup. We can remove one \"else if\" branch.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "ed5d2cac114202fe2978a9cbcab8f5032796d538",
      "tree": "aa9aaea1aa0945bd9159685d1b04897d105a90c9",
      "parents": [
        "f558b7e408026eb3c6afcd0e8fc1f7fe31195a6a"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Mon Feb 04 22:27:24 2008 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Tue Feb 05 09:44:07 2008 -0800"
      },
      "message": "exec: rework the group exit and fix the race with kill\n\nAs Roland pointed out, we have the very old problem with exec.  de_thread()\nsets SIGNAL_GROUP_EXIT, kills other threads, changes -\u003egroup_leader and then\nclears signal-\u003eflags.  All signals (even fatal ones) sent in this window\n(which is not too small) will be lost.\n\nWith this patch exec doesn\u0027t abuse SIGNAL_GROUP_EXIT.  signal_group_exit(),\nthe new helper, should be used to detect exit_group() or exec() in progress.\nIt can have more users, but this patch does only strictly necessary changes.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Davide Libenzi \u003cdavidel@xmailserver.org\u003e\nCc: Ingo Molnar \u003cmingo@elte.hu\u003e\nCc: Robin Holt \u003cholt@sgi.com\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "06c93e875747f3020d997220b3e7c98083acc7c3",
      "tree": "daed1cf5919f4f8acdbcc0c668a3bfee45b14c92",
      "parents": [
        "ef08cce81d9be38063ec7796e36f2b32bdf82ff2"
      ],
      "author": {
        "name": "Pierre Peiffer",
        "email": "pierre.peiffer@bull.net",
        "time": "Sun Feb 03 16:22:12 2008 +0200"
      },
      "committer": {
        "name": "Adrian Bunk",
        "email": "bunk@kernel.org",
        "time": "Sun Feb 03 16:22:12 2008 +0200"
      },
      "message": "Remove one useless extern declaration\n\nThe file exit.c contains one useless extern declaration of sem_exit().\nMoreover, it refers to nothing.\n\nThis trivial patch removes it.\n\nSigned-off-by: Pierre Peiffer \u003cpierre.peiffer@bull.net\u003e\nSigned-off-by: Adrian Bunk \u003cbunk@kernel.org\u003e\n"
    },
    {
      "commit": "338077e54e17e656da470a84724b773816207316",
      "tree": "79194e34d4ca5a454bf996640fa78c1964b727cc",
      "parents": [
        "e1abb39c60971590b6580c0d3a12119dcbad9c50"
      ],
      "author": {
        "name": "Matthew Wilcox",
        "email": "matthew@wil.cx",
        "time": "Thu Dec 06 11:09:35 2007 -0500"
      },
      "committer": {
        "name": "Matthew Wilcox",
        "email": "willy@linux.intel.com",
        "time": "Thu Dec 06 17:35:17 2007 -0500"
      },
      "message": "exit: Use task_is_*\n\nAlso restructure the loop in do_wait()\n\nSigned-off-by: Matthew Wilcox \u003cwilly@linux.intel.com\u003e\n"
    },
    {
      "commit": "e6ceb32aa25fc33f21af84cc7a32fe289b3e860c",
      "tree": "6a7684a5ac0f841a0bb85ce3a679e5836bd0e2df",
      "parents": [
        "14816b1e2b0eb24ef41dbe37dcb558338e54a603"
      ],
      "author": {
        "name": "Scott James Remnant",
        "email": "scott@ubuntu.com",
        "time": "Wed Nov 28 16:22:07 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Thu Nov 29 09:24:55 2007 -0800"
      },
      "message": "wait_task_stopped(): pass correct exit_code to wait_noreap_copyout()\n\nIn wait_task_stopped() exit_code already contains the right value for the\nsi_status member of siginfo, and this is simply set in the non WNOWAIT\ncase.\n\nIf you call waitid() with a stopped or traced process, you\u0027ll get the signal\nin siginfo.si_status as expected -- however if you call waitid(WNOWAIT) at the\nsame time, you\u0027ll get the signal \u003c\u003c 8 | 0x7f\n\nPass it unchanged to wait_noreap_copyout(); we would only need to shift it\nand add 0x7f if we were returning it in the user status field and that\nisn\u0027t used for any function that permits WNOWAIT.\n\nSigned-off-by: Scott James Remnant \u003cscott@ubuntu.com\u003e\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nCc: \u003cstable@kernel.org\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "c895078355b6b6e05c60aa205892526dd3390f0a",
      "tree": "922a0b9204b0cfcd5c59762f4d02e167d587ccd2",
      "parents": [
        "c2319540cd7330fa9066e5b9b84d357a2c8631a2"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Wed Nov 28 16:21:24 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Thu Nov 29 09:24:52 2007 -0800"
      },
      "message": "wait_task_stopped(): don\u0027t use task_pid_nr_ns() lockless\n\nwait_task_stopped(WNOWAIT) does task_pid_nr_ns() without tasklist/rcu lock,\nwe can read an already freed memory.  Use the cached pid_t value.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nLooks-good-to: Roland McGrath \u003croland@redhat.com\u003e\nAcked-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "a3474224e6a01924be40a8255636ea5522c1023a",
      "tree": "e190dfea1792d364b93b0fbfe45019a0e8cdad09",
      "parents": [
        "99fee6d7e5748d96884667a4628118f7fc130ea0"
      ],
      "author": {
        "name": "Roland McGrath",
        "email": "roland@redhat.com",
        "time": "Tue Nov 13 22:11:50 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Thu Nov 15 08:36:27 2007 -0800"
      },
      "message": "wait_task_stopped: Check p-\u003eexit_state instead of TASK_TRACED\n\nThe original meaning of the old test (p-\u003estate \u003e TASK_STOPPED) was\n\"not dead\", since it was before TASK_TRACED existed and before the\nstate/exit_state split.  It was a wrong correction in commit\n14bf01bb0599c89fc7f426d20353b76e12555308 to make this test for\nTASK_TRACED instead.  It should have been changed when TASK_TRACED\nwas introducted and again when exit_state was introduced.\n\nSigned-off-by: Roland McGrath \u003croland@redhat.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Alexey Dobriyan \u003cadobriyan@sw.ru\u003e\nCc: Kees Cook \u003ckees@ubuntu.com\u003e\nAcked-by: Scott James Remnant \u003cscott@ubuntu.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "a39bc51691a0c8880b7d10fa7c2f034f3ba9a037",
      "tree": "6f74815a32b5344cbfc2b3eca6def411308c06fb",
      "parents": [
        "a24efe62dd165be7d03431cf936ae17d345fed69"
      ],
      "author": {
        "name": "Alexey Dobriyan",
        "email": "adobriyan@sw.ru",
        "time": "Thu Oct 18 23:41:10 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:56 2007 -0700"
      },
      "message": "Uninline fork.c/exit.c\n\nSave ~650 bytes here.\n\nadd/remove: 4/0 grow/shrink: 0/7 up/down: 430/-1088 (-658)\nfunction                                     old     new   delta\n__copy_fs_struct                               -     202    +202\n__put_fs_struct                                -     112    +112\n__exit_fs                                      -      58     +58\n__exit_files                                   -      58     +58\nexit_files                                    58       2     -56\nput_fs_struct                                112       5    -107\nexit_fs                                      161       2    -159\nsys_unshare                                  774     590    -184\ncopy_process                                4031    3840    -191\ndo_exit                                     1791    1597    -194\ncopy_fs_struct                               202       5    -197\n\nNo difference in lmbench lat_proc tests on 2-way Opteron 246.\nSmaaaal degradation on UP P4 (within errors).\n\n[akpm@linux-foundation.org: coding-style fixes]\nSigned-off-by: Alexey Dobriyan \u003cadobriyan@sw.ru\u003e\nCc: Arjan van de Ven \u003carjan@infradead.org\u003e\nCc: Ingo Molnar \u003cmingo@elte.hu\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "ba25f9dcc4ea6e30839fcab5a5516f2176d5bfed",
      "tree": "3123c03b25dd5c0cd24b6ab4fc16731217838157",
      "parents": [
        "9a2e70572e94e21e7ec4186702d045415422bda0"
      ],
      "author": {
        "name": "Pavel Emelyanov",
        "email": "xemul@openvz.org",
        "time": "Thu Oct 18 23:40:40 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:43 2007 -0700"
      },
      "message": "Use helpers to obtain task pid in printks\n\nThe task_struct-\u003epid member is going to be deprecated, so start\nusing the helpers (task_pid_nr/task_pid_vnr/task_pid_nr_ns) in\nthe kernel.\n\nThe first thing to start with is the pid, printed to dmesg - in\nthis case we may safely use task_pid_nr(). Besides, printks produce\nmore (much more) than a half of all the explicit pid usage.\n\n[akpm@linux-foundation.org: git-drm went and changed lots of stuff]\nSigned-off-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nCc: Dave Airlie \u003cairlied@linux.ie\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "9a2e70572e94e21e7ec4186702d045415422bda0",
      "tree": "a6cd54dc559cbf6840dac4077f507a961486e21b",
      "parents": [
        "270f722d4d5f94b02fd48eed47e57917ab00a858"
      ],
      "author": {
        "name": "Pavel Emelyanov",
        "email": "xemul@openvz.org",
        "time": "Thu Oct 18 23:40:39 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:43 2007 -0700"
      },
      "message": "Isolate the explicit usage of signal-\u003epgrp\n\nThe pgrp field is not used widely around the kernel so it is now marked as\ndeprecated with appropriate comment.\n\nThe initialization of INIT_SIGNALS is trimmed because\na) they are set to 0 automatically;\nb) gcc cannot properly initialize two anonymous (the second one\n   is the one with the session) unions. In this particular case\n   to make it compile we\u0027d have to add some field initialized\n   right before the .pgrp.\n\nThis is the same patch as the 1ec320afdc9552c92191d5f89fcd1ebe588334ca one\n(from Cedric), but for the pgrp field.\n\nSome progress report:\n\nWe have to deprecate the pid, tgid, session and pgrp fields on struct\ntask_struct and struct signal_struct.  The session and pgrp are already\ndeprecated.  The tgid value is close to being such - the worst known usage\nin in fs/locks.c and audit code.  The pid field deprecation is mainly\nblocked by numerous printk-s around the kernel that print the tsk-\u003epid to\nlog.\n\nSigned-off-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nCc: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nCc: Serge Hallyn \u003cserue@us.ibm.com\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nCc: Herbert Poetzl \u003cherbert@13thfloor.at\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "b488893a390edfe027bae7a46e9af8083e740668",
      "tree": "c469a7f99ad01005a73011c029eb5e5d15454559",
      "parents": [
        "3eb07c8c8adb6f0572baba844ba2d9e501654316"
      ],
      "author": {
        "name": "Pavel Emelyanov",
        "email": "xemul@openvz.org",
        "time": "Thu Oct 18 23:40:14 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:40 2007 -0700"
      },
      "message": "pid namespaces: changes to show virtual ids to user\n\nThis is the largest patch in the set. Make all (I hope) the places where\nthe pid is shown to or get from user operate on the virtual pids.\n\nThe idea is:\n - all in-kernel data structures must store either struct pid itself\n   or the pid\u0027s global nr, obtained with pid_nr() call;\n - when seeking the task from kernel code with the stored id one\n   should use find_task_by_pid() call that works with global pids;\n - when showing pid\u0027s numerical value to the user the virtual one\n   should be used, but however when one shows task\u0027s pid outside this\n   task\u0027s namespace the global one is to be used;\n - when getting the pid from userspace one need to consider this as\n   the virtual one and use appropriate task/pid-searching functions.\n\n[akpm@linux-foundation.org: build fix]\n[akpm@linux-foundation.org: nuther build fix]\n[akpm@linux-foundation.org: yet nuther build fix]\n[akpm@linux-foundation.org: remove unneeded casts]\nSigned-off-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nSigned-off-by: Alexey Dobriyan \u003cadobriyan@openvz.org\u003e\nCc: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Paul Menage \u003cmenage@google.com\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "3eb07c8c8adb6f0572baba844ba2d9e501654316",
      "tree": "5c3d527f6b003b316d41119320ebd5c589c8afd0",
      "parents": [
        "0fbc26a6cfab9f377e82e28225f2c0c6b4661e5c"
      ],
      "author": {
        "name": "Sukadev Bhattiprolu",
        "email": "sukadev@us.ibm.com",
        "time": "Thu Oct 18 23:40:13 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:40 2007 -0700"
      },
      "message": "pid namespaces: destroy pid namespace on init\u0027s death\n\nTerminate all processes in a namespace when the reaper of the namespace is\nexiting.  We do this by walking the pidmap of the namespace and sending\nSIGKILL to all processes.\n\nSigned-off-by: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nAcked-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nCc: Paul Menage \u003cmenage@google.com\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "60347f6716aa49831ac311e04d77ccdc50dc024a",
      "tree": "82e666fef22f43550da42ad368a61a5e9a59ef96",
      "parents": [
        "8bf9725c29f2589237dd696d06a204230add0ba3"
      ],
      "author": {
        "name": "Pavel Emelyanov",
        "email": "xemul@openvz.org",
        "time": "Thu Oct 18 23:40:03 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:38 2007 -0700"
      },
      "message": "pid namespaces: prepare proc_flust_task() to flush entries from multiple proc trees\n\nThe first part is trivial - we just make the proc_flush_task() to operate on\narbitrary vfsmount with arbitrary ids and pass the pid and global proc_mnt to\nit.\n\nThe other change is more tricky: I moved the proc_flush_task() call in\nrelease_task() higher to address the following problem.\n\nWhen flushing task from many proc trees we need to know the set of ids (not\njust one pid) to find the dentries\u0027 names to flush.  Thus we need to pass the\ntask\u0027s pid to proc_flush_task() as struct pid is the only object that can\nprovide all the pid numbers.  But after __exit_signal() task has detached all\nhis pids and this information is lost.\n\nThis creates a tiny gap for proc_pid_lookup() to bring some dentries back to\ntree and keep them in hash (since pids are still alive before __exit_signal())\ntill the next shrink, but since proc_flush_task() does not provide a 100%\nguarantee that the dentries will be flushed, this is OK to do so.\n\nSigned-off-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nCc: Paul Menage \u003cmenage@google.com\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "2e4a707269a409950c3f315010c20f9719c594e2",
      "tree": "d25109a6b36bdcb78382d379bdba4c4e83150389",
      "parents": [
        "762a24beed3f3ab93224bd447710e6c36fcf1968"
      ],
      "author": {
        "name": "Pavel Emelyanov",
        "email": "xemul@openvz.org",
        "time": "Thu Oct 18 23:40:01 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:38 2007 -0700"
      },
      "message": "pid namespaces: move exit_task_namespaces()\n\nMake task release its namespaces after it has reparented all his children to\nchild_reaper, but before it notifies its parent about its death.\n\nThe reason to release namespaces after reparenting is that when task exits it\nmay send a signal to its parent (SIGCHLD), but if the parent has already\nexited its namespaces there will be no way to decide what pid to dever to him\n- parent can be from different namespace.\n\nThe reason to release namespace before notifying the parent it that when task\nsends a SIGCHLD to parent it can call wait() on this taks and release it.  But\nreleasing the mnt namespace implies dropping of all the mounts in the mnt\nnamespace and NFS expects the task to have valid sighand pointer.\n\nThanks to Oleg for pointing out some races that can apear and helping with\npatches and fixes.\n\nSigned-off-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nCc: Paul Menage \u003cmenage@google.com\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "762a24beed3f3ab93224bd447710e6c36fcf1968",
      "tree": "5753a796e11e53173194199292fdfcaae04efb47",
      "parents": [
        "d4c5e41f3f1b0c19448fcf2d259bdab1ede75e2e"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Thu Oct 18 23:40:00 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:38 2007 -0700"
      },
      "message": "pid namespaces: rework forget_original_parent()\n\nA pid namespace is a \"view\" of a particular set of tasks on the system.  They\nwork in a similar way to filesystem namespaces.  A file (or a process) can be\naccessed in multiple namespaces, but it may have a different name in each.  In\na filesystem, this name might be /etc/passwd in one namespace, but\n/chroot/etc/passwd in another.\n\nFor processes, a process may have pid 1234 in one namespace, but be pid 1 in\nanother.  This allows new pid namespaces to have basically arbitrary pids, and\nnot have to worry about what pids exist in other namespaces.  This is\nessential for checkpoint/restart where a restarted process\u0027s pid might collide\nwith an existing process on the system\u0027s pid.\n\nIn this particular implementation, pid namespaces have a parent-child\nrelationship, just like processes.  A process in a pid namespace may see all\nof the processes in the same namespace, as well as all of the processes in all\nof the namespaces which are children of its namespace.  Processes may not,\nhowever, see others which are in their parent\u0027s namespace, but not in their\nown.  The same goes for sibling namespaces.\n\nThe know issue to be solved in the nearest future is signal handling in the\nnamespace boundary.  That is, currently the namespace\u0027s init is treated like\nan ordinary task that can be killed from within an namespace.  Ideally, the\nsignal handling by the namespace\u0027s init should have two sides: when signaling\nthe init from its namespace, the init should look like a real init task, i.e.\nreceive only those signals, that is explicitly wants to; when signaling the\ninit from one of the parent namespaces, init should look like an ordinary\ntask, i.e.  receive any signal, only taking the general permissions into\naccount.\n\nThe pid namespace was developed by Pavel Emlyanov and Sukadev Bhattiprolu and\nwe eventually came to almost the same implementation, which differed in some\ndetails.  This set is based on Pavel\u0027s patches, but it includes comments and\npatches that from Sukadev.\n\nMany thanks to Oleg, who reviewed the patches, pointed out many BUGs and made\nvaluable advises on how to make this set cleaner.\n\nThis patch:\n\nWe have to call exit_task_namespaces() only after the exiting task has\nreparented all his children and is sure that no other threads will reparent\ntheirs for it.  Why this is needed is explained in appropriate patch.  This\none only reworks the forget_original_parent() so that after calling this a\ntask cannot be/become parent of any other task.\n\nWe check PF_EXITING instead of -\u003eexit_state while choosing the new parent.\nNote that tasklits_lock acts as a barrier, everyone who takes tasklist after\nus (when forget_original_parent() drops it) must see PF_EXITING.\n\nThe other changes are just cleanups.  They just move some code from\nexit_notify to forget_original_parent().  It is a bit silly to declare\nptrace_dead in exit_notify(), take tasklist, pass ptrace_dead to\nforget_original_parent(), unlock-lock-unlock tasklist, and then use\nptrace_dead.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nCc: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nCc: Paul Menage \u003cmenage@google.com\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "d4c5e41f3f1b0c19448fcf2d259bdab1ede75e2e",
      "tree": "5a5ae3a1967c39f728b42e2fa0fc7cbcddcd2108",
      "parents": [
        "7b1915a989ea4d426d0fd98974ab80f30ef1d779"
      ],
      "author": {
        "name": "Daniel Walker",
        "email": "dwalker@mvista.com",
        "time": "Thu Oct 18 23:39:59 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:38 2007 -0700"
      },
      "message": "whitespace fixes: task exit handling\n\nSigned-off-by: Daniel Walker \u003cdwalker@mvista.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "03ff17979c58a0b63b0fe30a373f41b719731bd2",
      "tree": "c6369ebab7a3035b309de5f288d6e8fc149b3d69",
      "parents": [
        "d473012710b815741043942bc41945d444abab40"
      ],
      "author": {
        "name": "Matthias Kaehlcke",
        "email": "matthias.kaehlcke@gmail.com",
        "time": "Thu Oct 18 23:39:57 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:38 2007 -0700"
      },
      "message": "kernel/exit.c: Use list_for_each_entry(_safe) instead of list_for_each(_safe)\n\nkernel/exit.c: Convert list_for_each(_safe) to\nlist_for_each_entry(_safe) in forget_original_parent(), exit_notify()\nand do_wait()\n\nSigned-off-by: Matthias Kaehlcke \u003cmatthias.kaehlcke@gmail.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "cf7b708c8d1d7a27736771bcf4c457b332b0f818",
      "tree": "10f80257b052313b283f18ddfe35145882e0b47f",
      "parents": [
        "a6f5e06378970a2687332c2d54046245fcff1e7e"
      ],
      "author": {
        "name": "Pavel Emelyanov",
        "email": "xemul@openvz.org",
        "time": "Thu Oct 18 23:39:54 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:37 2007 -0700"
      },
      "message": "Make access to task\u0027s nsproxy lighter\n\nWhen someone wants to deal with some other taks\u0027s namespaces it has to lock\nthe task and then to get the desired namespace if the one exists.  This is\nslow on read-only paths and may be impossible in some cases.\n\nE.g.  Oleg recently noticed a race between unshare() and the (sent for\nreview in cgroups) pid namespaces - when the task notifies the parent it\nhas to know the parent\u0027s namespace, but taking the task_lock() is\nimpossible there - the code is under write locked tasklist lock.\n\nOn the other hand switching the namespace on task (daemonize) and releasing\nthe namespace (after the last task exit) is rather rare operation and we\ncan sacrifice its speed to solve the issues above.\n\nThe access to other task namespaces is proposed to be performed\nlike this:\n\n     rcu_read_lock();\n     nsproxy \u003d task_nsproxy(tsk);\n     if (nsproxy !\u003d NULL) {\n             / *\n               * work with the namespaces here\n               * e.g. get the reference on one of them\n               * /\n     } / *\n         * NULL task_nsproxy() means that this task is\n         * almost dead (zombie)\n         * /\n     rcu_read_unlock();\n\nThis patch has passed the review by Eric and Oleg :) and,\nof course, tested.\n\n[clg@fr.ibm.com: fix unshare()]\n[ebiederm@xmission.com: Update get_net_ns_by_pid]\nSigned-off-by: Pavel Emelyanov \u003cxemul@openvz.org\u003e\nSigned-off-by: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Paul E. McKenney \u003cpaulmck@linux.vnet.ibm.com\u003e\nCc: Serge Hallyn \u003cserue@us.ibm.com\u003e\nSigned-off-by: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "b460cbc581a53cc088ceba80608021dd49c63c43",
      "tree": "83c28d0adbc15f4157c77b40fa60c40a71cb8673",
      "parents": [
        "3743ca05ff464b8a9e345c08a6c9ce30485f9805"
      ],
      "author": {
        "name": "Serge E. Hallyn",
        "email": "serue@us.ibm.com",
        "time": "Thu Oct 18 23:39:52 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:37 2007 -0700"
      },
      "message": "pid namespaces: define is_global_init() and is_container_init()\n\nis_init() is an ambiguous name for the pid\u003d\u003d1 check.  Split it into\nis_global_init() and is_container_init().\n\nA cgroup init has it\u0027s tsk-\u003epid \u003d\u003d 1.\n\nA global init also has it\u0027s tsk-\u003epid \u003d\u003d 1 and it\u0027s active pid namespace\nis the init_pid_ns.  But rather than check the active pid namespace,\ncompare the task structure with \u0027init_pid_ns.child_reaper\u0027, which is\ninitialized during boot to the /sbin/init process and never changes.\n\nChangelog:\n\n\t2.6.22-rc4-mm2-pidns1:\n\t- Use \u0027init_pid_ns.child_reaper\u0027 to determine if a given task is the\n\t  global init (/sbin/init) process. This would improve performance\n\t  and remove dependence on the task_pid().\n\n\t2.6.21-mm2-pidns2:\n\n\t- [Sukadev Bhattiprolu] Changed is_container_init() calls in {powerpc,\n\t  ppc,avr32}/traps.c for the _exception() call to is_global_init().\n\t  This way, we kill only the cgroup if the cgroup\u0027s init has a\n\t  bug rather than force a kernel panic.\n\n[akpm@linux-foundation.org: fix comment]\n[sukadev@us.ibm.com: Use is_global_init() in arch/m32r/mm/fault.c]\n[bunk@stusta.de: kernel/pid.c: remove unused exports]\n[sukadev@us.ibm.com: Fix capability.c to work with threaded init]\nSigned-off-by: Serge E. Hallyn \u003cserue@us.ibm.com\u003e\nSigned-off-by: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nAcked-by: Pavel Emelianov \u003cxemul@openvz.org\u003e\nCc: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nCc: Dave Hansen \u003chaveblue@us.ibm.com\u003e\nCc: Herbert Poetzel \u003cherbert@13thfloor.at\u003e\nCc: Kirill Korotaev \u003cdev@sw.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "88f21d818255bc61c002478d21caf52f8a9b8def",
      "tree": "de16e38862622b3d295f7850cdb006922307fb8d",
      "parents": [
        "2894d650cd9715d00ca196c711265819ef6ebd2d"
      ],
      "author": {
        "name": "Sukadev Bhattiprolu",
        "email": "sukadev@us.ibm.com",
        "time": "Thu Oct 18 23:39:50 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:37 2007 -0700"
      },
      "message": "pid namespaces: rename child_reaper() function\n\nRename the child_reaper() function to task_child_reaper() to be similar to\nother task_* functions and to distinguish the function from \u0027struct\npid_namspace.child_reaper\u0027.\n\nSigned-off-by: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nCc: Pavel Emelianov \u003cxemul@openvz.org\u003e\nCc: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nCc: Dave Hansen \u003chaveblue@us.ibm.com\u003e\nCc: Serge Hallyn \u003cserue@us.ibm.com\u003e\nCc: Herbert Poetzel \u003cherbert@13thfloor.at\u003e\nCc: Kirill Korotaev \u003cdev@sw.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "a47afb0f9d794d525a372c8d69902147cc88222a",
      "tree": "7bd67280e2edc1c3b1803d4a93bee794088e9342",
      "parents": [
        "858d72ead4864da0fb0b89b919524125ce998e27"
      ],
      "author": {
        "name": "Pavel Emelianov",
        "email": "xemul@openvz.org",
        "time": "Thu Oct 18 23:39:46 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:37 2007 -0700"
      },
      "message": "pid namespaces: round up the API\n\nThe set of functions process_session, task_session, process_group and\ntask_pgrp is confusing, as the names can be mixed with each other when looking\nat the code for a long time.\n\nThe proposals are to\n* equip the functions that return the integer with _nr suffix to\n  represent that fact,\n* and to make all functions work with task (not process) by making\n  the common prefix of the same name.\n\nFor monotony the routines signal_session() and set_signal_session() are\nreplaced with task_session_nr() and set_task_session(), especially since they\nare only used with the explicit task-\u003esignal dereference.\n\nSigned-off-by: Pavel Emelianov \u003cxemul@openvz.org\u003e\nAcked-by: Serge E. Hallyn \u003cserue@us.ibm.com\u003e\nCc: Kirill Korotaev \u003cdev@openvz.org\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nCc: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nCc: Herbert Poetzl \u003cherbert@13thfloor.at\u003e\nCc: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "8793d854edbc2774943a4b0de3304dc73991159a",
      "tree": "380b3403a0fedfcce61d9af5af1ffbcc71017abf",
      "parents": [
        "81a6a5cdd2c5cd70874b88afe524ab09e9e869af"
      ],
      "author": {
        "name": "Paul Menage",
        "email": "menage@google.com",
        "time": "Thu Oct 18 23:39:39 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:36 2007 -0700"
      },
      "message": "Task Control Groups: make cpusets a client of cgroups\n\nRemove the filesystem support logic from the cpusets system and makes cpusets\na cgroup subsystem\n\nThe \"cpuset\" filesystem becomes a dummy filesystem; attempts to mount it get\npassed through to the cgroup filesystem with the appropriate options to\nemulate the old cpuset filesystem behaviour.\n\nSigned-off-by: Paul Menage \u003cmenage@google.com\u003e\nCc: Serge E. Hallyn \u003cserue@us.ibm.com\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nCc: Dave Hansen \u003chaveblue@us.ibm.com\u003e\nCc: Balbir Singh \u003cbalbir@in.ibm.com\u003e\nCc: Paul Jackson \u003cpj@sgi.com\u003e\nCc: Kirill Korotaev \u003cdev@openvz.org\u003e\nCc: Herbert Poetzl \u003cherbert@13thfloor.at\u003e\nCc: Srivatsa Vaddagiri \u003cvatsa@in.ibm.com\u003e\nCc: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "b4f48b6363c81ca743ef46943ef23fd72e60f679",
      "tree": "40437b78e2d7a7d9d71e7bd63bc96e1ad02daa94",
      "parents": [
        "355e0c48b757b7fcc79ccb98fda8105ed37a1598"
      ],
      "author": {
        "name": "Paul Menage",
        "email": "menage@google.com",
        "time": "Thu Oct 18 23:39:33 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Oct 19 11:53:36 2007 -0700"
      },
      "message": "Task Control Groups: add fork()/exit() hooks\n\nThis adds the necessary hooks to the fork() and exit() paths to ensure\nthat new children inherit their parent\u0027s cgroup assignments, and that\nexiting processes release reference counts on their cgroups.\n\nSigned-off-by: Paul Menage \u003cmenage@google.com\u003e\nCc: Serge E. Hallyn \u003cserue@us.ibm.com\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nCc: Dave Hansen \u003chaveblue@us.ibm.com\u003e\nCc: Balbir Singh \u003cbalbir@in.ibm.com\u003e\nCc: Paul Jackson \u003cpj@sgi.com\u003e\nCc: Kirill Korotaev \u003cdev@openvz.org\u003e\nCc: Herbert Poetzl \u003cherbert@13thfloor.at\u003e\nCc: Srivatsa Vaddagiri \u003cvatsa@in.ibm.com\u003e\nCc: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "42b2dd0a02c512cf59c96f5c227bf54bfe5bbf08",
      "tree": "f9e4a572804897772d97e2db1ab0d2adcd28840c",
      "parents": [
        "bcbba6c10ef6b14b0542d7ed7380e95168175818"
      ],
      "author": {
        "name": "Alexey Dobriyan",
        "email": "adobriyan@sw.ru",
        "time": "Tue Oct 16 23:27:30 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:55 2007 -0700"
      },
      "message": "Shrink task_struct if CONFIG_FUTEX\u003dn\n\nrobust_list, compat_robust_list, pi_state_list, pi_state_cache are\nreally used if futexes are on.\n\nSigned-off-by: Alexey Dobriyan \u003cadobriyan@sw.ru\u003e\nAcked-by: Ingo Molnar \u003cmingo@elte.hu\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "6db840fa7887980ef68a649640d506fe069eef0c",
      "tree": "6248c1e65b572f1c2b14c46848e5a18df003f60e",
      "parents": [
        "356d6d5058c8082b9e811838ab2fa27825c947e4"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Tue Oct 16 23:27:23 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:54 2007 -0700"
      },
      "message": "exec: RT sub-thread can livelock and monopolize CPU on exec\n\nde_thread() yields waiting for -\u003egroup_leader to be a zombie. This deadlocks\nif an rt-prio execer shares the same cpu with -\u003egroup_leader. Change the code\nto use -\u003egroup_exit_task/notify_count mechanics.\n\nThis patch certainly uglifies the code, perhaps someone can suggest something\nbetter.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "715015e8da37c4d13e234def054bcbea116297e9",
      "tree": "3c3f2cd1d516d13d50ad33519dfe98a75243eb0d",
      "parents": [
        "18442cf28af81378cf8996d264b368bba47cf846"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Tue Oct 16 23:27:00 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:52 2007 -0700"
      },
      "message": "wait_task_stopped/continued: remove unneeded p-\u003esignal !\u003d NULL check\n\nThe child was found on -\u003echildren list under tasklist_lock, it must have a\nvalid -\u003esignal. __exit_signal() both removes the task from parent-\u003echildren\nand clears -\u003esignal \"atomically\" under write_lock(tasklist).\n\nRemove unneeded checks.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "442a10cf9e1c350b4de4dd6f22c72618a0b13d7f",
      "tree": "13ab9fc1bd97be616511425d422e0c9188fbf5f3",
      "parents": [
        "ebca4cda1133775111e8b09f7124a7e5e391926d"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Tue Oct 16 23:26:59 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:51 2007 -0700"
      },
      "message": "wait_task_zombie: don\u0027t fight with non-existing race with a dying ptracee\n\nThe \"p-\u003eexit_signal \u003d\u003d -1 \u0026\u0026 p-\u003eptrace \u003d\u003d 0\" check and the comment are\nbogus.  We already did exactly the same check in eligible_child(), we did\nnot drop tasklist_lock since then, and both variables need\nwrite_lock(tasklist) to be changed.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "3ae4cbadf4bf97ee137b921a1b928d2a5dcd26ca",
      "tree": "1d8bea4faeae056da20b2401645900daa3c86c55",
      "parents": [
        "2f4e6e2a814eb1305a873a045401708d73f870bc"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Tue Oct 16 23:26:58 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:51 2007 -0700"
      },
      "message": "exit_notify: don\u0027t take tasklist for TIF_SIGPENDING re-targeting\n\n-\u003esiglock provides enough protection to iterate over the thread group.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "2f4e6e2a814eb1305a873a045401708d73f870bc",
      "tree": "8860a0e557c6849143c363eb7c1c9e82333e7fe3",
      "parents": [
        "407af46a967ffd2f208f0a5fb3f1ff954801494a"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Tue Oct 16 23:26:58 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:51 2007 -0700"
      },
      "message": "wait_task_zombie: fix 2/3 races vs forget_original_parent()\n\nTwo threads, T1 and T2.  T2 ptraces P, and P is not a child of ptracer\u0027s\nthread group.  P exits and goes to TASK_ZOMBIE.\n\nT1 does wait_task_zombie(P):\n\n\tP-\u003eexit_state \u003d TASK_DEAD;\n\t...\n\tread_unlock(\u0026tasklist_lock);\n\n\t\t\t\t\tT2 does exit(), takes tasklist,\n\t\t\t\t\tforget_original_parent() does\n\t\t\t\t\t__ptrace_unlink(P) but doesn\u0027t\n\t\t\t\t\tcall do_notify_parent(P) because\n\t\t\t\t\tp-\u003eexit_state \u003d\u003d EXIT_DEAD.\n\nNow, P is not visible to our process: __ptrace_unlink() removed it from\n-\u003echildren. We should send notification to P-\u003eparent and release P if and\nonly if SIGCHLD is ignored.\n\nAnd we have 3 bugs:\n\n1. P-\u003eparent does do_wait() and gets -ECHILD (P is on -\u003eparent-\u003echildren,\n   but its state is TASK_DEAD).\n\n2. // wait_task_zombie() continues\n\n\tif (put_user(...)) {\n\t\t// TODO: is this safe?\n\t\tp-\u003eexit_state \u003d EXIT_ZOMBIE;\n\t\treturn;\n\t}\n\n   we return without notification/release, task_struct leaked.\n\n   Solution: ignore -EFAULT and proceed. It is an application\u0027s bug if\n   we can\u0027t fill infop/stat_addr (in case of VM_FAULT_OOM we have much\n   more problems).\n\n3. // wait_task_zombie() continues\n\n\tif (p-\u003ereal_parent !\u003d p-\u003eparent) {\n\t\t// Not taken, it was untraced\u0027ed\n\t\t...\n\t}\n\n\trelease_task(p);\n\n   we released the task which we shouldn\u0027t.\n\n   Solution: check -\u003ereal_parent !\u003d -\u003eparent before, under tasklist_lock,\n   but use ptrace_unlink() instead of __ptrace_unlink() to check -\u003eptrace.\n\nThis patch hopefully solves 2 and 3, the 1st bug will be fixed later, we need\nsome cleanups in forget_original_parent/reparent_thread.\n\nHowever, the first race is very unlikely and not critical, so I hope it makes\nsense to fix 1 and 2 for now.\n\n4. Small cleanup: don\u0027t \"restore\" EXIT_ZOMBIE unless we know we are not going\n   to realease the child.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Ingo Molnar \u003cmingo@elte.hu\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "407af46a967ffd2f208f0a5fb3f1ff954801494a",
      "tree": "cf9b98874efb3f6a9e244c4f2be6eaf69db3306e",
      "parents": [
        "a8b0ac0873cd911b3bf3d6e2db98f80d0b158d56"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Tue Oct 16 23:26:57 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:51 2007 -0700"
      },
      "message": "wait_task_zombie: remove unneeded child-\u003esignal check\n\nA zombie must have a valid -\u003esignal, we are going to release it and\n__exit_signal() starts with BUG_ON(!sig).\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "84eb646b6eabcd82ec563f30d2d9d40c2054a9c9",
      "tree": "96219c5844c80c40cbc9814a13a9a72de7430fc7",
      "parents": [
        "8e9073ed027771bcdee4033eb900a3c09ac90a19"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Tue Oct 16 23:26:49 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:51 2007 -0700"
      },
      "message": "handle the multi-threaded init\u0027s exit() properly\n\nWith or without this patch, multi-threaded init\u0027s are not fully supported,\nbut do_exit() is completely wrong.  This becomes a real problem when we\nsupport pid namespaces.\n\n1. do_exit() panics when the main thread of /sbin/init exits. It should not\n   until the whole thread group exits. Move the code below, under the\n   \"if (group_dead)\" check.\n\n   Note: this means that forget_original_parent() can use an already dead\n   child_reaper()\u0027s task_struct. This is OK for /sbin/init because\n\n   \t- do_wait() from alive sub-thread still can reap a zombie, we iterate\n   \t  over all sub-thread\u0027s -\u003echildren lists\n\n   \t- do_notify_parent() will wakeup some alive sub-thread because it sends\n   \t  the group-wide signal\n\n   However, we should remove choose_new_parent()-\u003eBUG_ON(reaper-\u003eexit_state)\n   for this.\n\n2. We are playing games with -\u003ensproxy-\u003epid_ns. This code is bogus today, and\n   it has to be changed anyway when we really support pid namespaces, just\n   remove it.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nRoland McGrath \u003croland@redhat.com\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nCc: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nCc: Serge Hallyn \u003cserue@us.ibm.com\u003e\nCc: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nCc: Ingo Molnar \u003cmingo@elte.hu\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "d2ee7198cc2414aade234a3cebc69e6cbff35d9b",
      "tree": "e89d52b8b64f6eb675add025ba8507863e4bc0f8",
      "parents": [
        "7917ff9a4cefd0500aa4a1b1942da96dbce6999f"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Tue Oct 16 23:26:47 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:51 2007 -0700"
      },
      "message": "pi-futex: set PF_EXITING without taking -\u003epi_lock\n\nIt is a bit annoying that do_exit() takes -\u003epi_lock to set PF_EXITING.  All\nwe need is to synchronize with lookup_pi_state() which saw this task\nwithout PF_EXITING under -\u003epi_lock.\n\nChange do_exit() to use spin_unlock_wait().\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: Ingo Molnar \u003cmingo@elte.hu\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "a9022e9cb9e919e31d5bc15fcef5c7186740645e",
      "tree": "48aea98aec8d9822155b2054bc60f9142f478769",
      "parents": [
        "ea0b7d5da0024df1c6f2c2139dbeb4fd260baac6"
      ],
      "author": {
        "name": "Jesper Juhl",
        "email": "jesper.juhl@gmail.com",
        "time": "Tue Oct 16 23:26:23 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed Oct 17 08:42:48 2007 -0700"
      },
      "message": "Clean up duplicate includes in kernel/\n\nThis patch cleans up duplicate includes in\n\tkernel/\n\nSigned-off-by: Jesper Juhl \u003cjesper.juhl@gmail.com\u003e\nAcked-by: Paul E. McKenney \u003cpaulmck@linux.vnet.ibm.com\u003e\nReviewed-by: Satyam Sharma \u003cssatyam@cse.iitk.ac.in\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "9ac52315d4cf5f561f36dabaf0720c00d3553162",
      "tree": "afe7284f34a65d2540fcb2a9b764834f9d790fa7",
      "parents": [
        "5e84cfde51cf303d368fcb48f22059f37b3872de"
      ],
      "author": {
        "name": "Laurent Vivier",
        "email": "Laurent.Vivier@bull.net",
        "time": "Mon Oct 15 17:00:19 2007 +0200"
      },
      "committer": {
        "name": "Ingo Molnar",
        "email": "mingo@elte.hu",
        "time": "Mon Oct 15 17:00:19 2007 +0200"
      },
      "message": "sched: guest CPU accounting: add guest-CPU /proc/\u003cpid\u003e/stat fields\n\nlike for cpustat, introduce the \"gtime\" (guest time of the task) and\n\"cgtime\" (guest time of the task children) fields for the\ntasks. Modify signal_struct and task_struct.\n\nModify /proc/\u003cpid\u003e/stat to display these new fields.\n\nSigned-off-by: Laurent Vivier \u003cLaurent.Vivier@bull.net\u003e\nAcked-by: Avi Kivity \u003cavi@qumranet.com\u003e\nSigned-off-by: Ingo Molnar \u003cmingo@elte.hu\u003e\n"
    },
    {
      "commit": "b8fceee17a310f189188599a8fa5e9beaff57eb0",
      "tree": "21308319be2579059a4d4d7db680a73334659f82",
      "parents": [
        "9db619e66503494e41159de3c76fafabe80d016b"
      ],
      "author": {
        "name": "Davide Libenzi",
        "email": "davidel@xmailserver.org",
        "time": "Thu Sep 20 12:40:16 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Thu Sep 20 13:19:59 2007 -0700"
      },
      "message": "signalfd simplification\n\nThis simplifies signalfd code, by avoiding it to remain attached to the\nsighand during its lifetime.\n\nIn this way, the signalfd remain attached to the sighand only during\npoll(2) (and select and epoll) and read(2).  This also allows to remove\nall the custom \"tsk \u003d\u003d current\" checks in kernel/signal.c, since\ndequeue_signal() will only be called by \"current\".\n\nI think this is also what Ben was suggesting time ago.\n\nThe external effect of this, is that a thread can extract only its own\nprivate signals and the group ones.  I think this is an acceptable\nbehaviour, in that those are the signals the thread would be able to\nfetch w/out signalfd.\n\nSigned-off-by: Davide Libenzi \u003cdavidel@xmailserver.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "f2ab6d8889422c1f5354f014e8bef337b1d1bade",
      "tree": "ab7de371c86ce9e72015363fc06563709d823354",
      "parents": [
        "c24c55c75a0d799be07ad6c1a7ff4ccfe25da75b"
      ],
      "author": {
        "name": "Jonathan Lim",
        "email": "jlim@sgi.com",
        "time": "Thu Aug 30 23:56:23 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Aug 31 01:42:22 2007 -0700"
      },
      "message": "Assign task_struct.exit_code before taskstats_exit()\n\ntaskstats.ac_exitcode is assigned to task_struct.exit_code in bacct_add_tsk()\nthrough the following kernel function calls:\n\n  do_exit()\n    taskstats_exit()\n      fill_pid()\n        bacct_add_tsk()\n\nThe problem is that in do_exit(), task_struct.exit_code is set to \u0027code\u0027 only\nafter taskstats_exit() has been called.  So we need to move the assignment\nbefore taskstats_exit().\n\nSigned-off-by: Jonathan Lim \u003cjlim@sgi.com\u003e\nCc: Balbir Singh \u003cbalbir@in.ibm.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "247284481ca40288bd120cf0707681c3bdbee78f",
      "tree": "d0de3020d9961561b66b44af8ddc9e4d1442a7fe",
      "parents": [
        "b6b1d87785712474d0ed80689c17107d616a1171"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Sat Aug 04 01:04:41 2007 +0400"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Aug 03 15:06:33 2007 -0700"
      },
      "message": "Kill some obsolete sub-thread-ptrace stuff\n\nThere is a couple of subtle checks which were needed to handle ptracing from\nthe same thread group. This was deprecated a long ago, imho this code just\ncomplicates the understanding.\n\nAnd, the \"-\u003eparent-\u003esignal-\u003eflags \u0026 SIGNAL_GROUP_EXIT\" check in exit_notify()\nis not right. SIGNAL_GROUP_EXIT can mean exec(), not exit_group(). This means\nptracer can lose a ptraced zombie on exec(). Minor problem, but still the bug.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "0c1eecfb345401629aa57c9d3b077273e56c45a7",
      "tree": "522d7090966c6e70f3147c30e3308781e0309938",
      "parents": [
        "b1457bcc3a00a0446c7f6e2f22fd24b6d8d0a309"
      ],
      "author": {
        "name": "Rafael J. Wysocki",
        "email": "rjw@sisk.pl",
        "time": "Thu Jul 19 01:47:33 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Thu Jul 19 10:04:42 2007 -0700"
      },
      "message": "Freezer: avoid freezing kernel threads prematurely\n\nKernel threads should not have TIF_FREEZE set when user space processes are\nbeing frozen, since otherwise some of them might be frozen prematurely.\nTo prevent this from happening we can (1) make exit_mm() unset TIF_FREEZE\nunconditionally just after clearing tsk-\u003emm and (2) make try_to_freeze_tasks()\ncheck if p-\u003emm is different from zero and PF_BORROWED_MM is unset in p-\u003eflags\nwhen user space processes are to be frozen.\n\nNamely, when user space processes are being frozen, we only should set\nTIF_FREEZE for tasks that have p-\u003emm different from NULL and don\u0027t have\nPF_BORROWED_MM set in p-\u003eflags.  For this reason task_lock() must be used to\nprevent try_to_freeze_tasks() from racing with use_mm()/unuse_mm(), in which\np-\u003emm and p-\u003eflags.PF_BORROWED_MM are changed under task_lock(p).  Also, we\nneed to prevent the following scenario from happening:\n\n* daemonize() is called by a task spawned from a user space code path\n* freezer checks if the task has p-\u003emm set and the result is positive\n* task enters exit_mm() and clears its TIF_FREEZE\n* freezer sets TIF_FREEZE for the task\n* task calls try_to_freeze() and goes to the refrigerator, which is wrong at\n  that point\n\nThis requires us to acquire task_lock(p) before p-\u003eflags.PF_BORROWED_MM and\np-\u003emm are examined and release it after TIF_FREEZE is set for p (or it turns\nout that TIF_FREEZE should not be set).\n\nSigned-off-by: Rafael J. Wysocki \u003crjw@sisk.pl\u003e\nCc: Gautham R Shenoy \u003cego@in.ibm.com\u003e\nCc: Pavel Machek \u003cpavel@ucw.cz\u003e\nCc: Nigel Cunningham \u003cnigel@nigel.suspend2.net\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "831441862956fffa17b9801db37e6ea1650b0f69",
      "tree": "b0334921341f8f1734bdd3243de76d676329d21c",
      "parents": [
        "787d2214c19bcc9b6ac48af0ce098277a801eded"
      ],
      "author": {
        "name": "Rafael J. Wysocki",
        "email": "rjw@sisk.pl",
        "time": "Tue Jul 17 04:03:35 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Tue Jul 17 10:23:02 2007 -0700"
      },
      "message": "Freezer: make kernel threads nonfreezable by default\n\nCurrently, the freezer treats all tasks as freezable, except for the kernel\nthreads that explicitly set the PF_NOFREEZE flag for themselves.  This\napproach is problematic, since it requires every kernel thread to either\nset PF_NOFREEZE explicitly, or call try_to_freeze(), even if it doesn\u0027t\ncare for the freezing of tasks at all.\n\nIt seems better to only require the kernel threads that want to or need to\nbe frozen to use some freezer-related code and to remove any\nfreezer-related code from the other (nonfreezable) kernel threads, which is\ndone in this patch.\n\nThe patch causes all kernel threads to be nonfreezable by default (ie.  to\nhave PF_NOFREEZE set by default) and introduces the set_freezable()\nfunction that should be called by the freezable kernel threads in order to\nunset PF_NOFREEZE.  It also makes all of the currently freezable kernel\nthreads call set_freezable(), so it shouldn\u0027t cause any (intentional)\nchange of behaviour to appear.  Additionally, it updates documentation to\ndescribe the freezing of tasks more accurately.\n\n[akpm@linux-foundation.org: build fixes]\nSigned-off-by: Rafael J. Wysocki \u003crjw@sisk.pl\u003e\nAcked-by: Nigel Cunningham \u003cnigel@nigel.suspend2.net\u003e\nCc: Pavel Machek \u003cpavel@ucw.cz\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Gautham R Shenoy \u003cego@in.ibm.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "522ed7767e800cff6c650ec64b0ee0677303119c",
      "tree": "f65ecb29f2cf885018d3557f840de3ef4be6ec64",
      "parents": [
        "4f27c00bf80f122513d3a5be16ed851573164534"
      ],
      "author": {
        "name": "Miloslav Trmac",
        "email": "mitr@redhat.com",
        "time": "Sun Jul 15 23:40:56 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon Jul 16 09:05:47 2007 -0700"
      },
      "message": "Audit: add TTY input auditing\n\nAdd TTY input auditing, used to audit system administrator\u0027s actions.  This is\nrequired by various security standards such as DCID 6/3 and PCI to provide\nnon-repudiation of administrator\u0027s actions and to allow a review of past\nactions if the administrator seems to overstep their duties or if the system\nbecomes misconfigured for unknown reasons.  These requirements do not make it\nnecessary to audit TTY output as well.\n\nCompared to an user-space keylogger, this approach records TTY input using the\naudit subsystem, correlated with other audit events, and it is completely\ntransparent to the user-space application (e.g.  the console ioctls still\nwork).\n\nTTY input auditing works on a higher level than auditing all system calls\nwithin the session, which would produce an overwhelming amount of mostly\nuseless audit events.\n\nAdd an \"audit_tty\" attribute, inherited across fork ().  Data read from TTYs\nby process with the attribute is sent to the audit subsystem by the kernel.\nThe audit netlink interface is extended to allow modifying the audit_tty\nattribute, and to allow sending explanatory audit events from user-space (for\nexample, a shell might send an event containing the final command, after the\ninteractive command-line editing and history expansion is performed, which\nmight be difficult to decipher from the TTY input alone).\n\nBecause the \"audit_tty\" attribute is inherited across fork (), it would be set\ne.g.  for sshd restarted within an audited session.  To prevent this, the\naudit_tty attribute is cleared when a process with no open TTY file\ndescriptors (e.g.  after daemon startup) opens a TTY.\n\nSee https://www.redhat.com/archives/linux-audit/2007-June/msg00000.html for a\nmore detailed rationale document for an older version of this patch.\n\n[akpm@linux-foundation.org: build fix]\nSigned-off-by: Miloslav Trmac \u003cmitr@redhat.com\u003e\nCc: Al Viro \u003cviro@zeniv.linux.org.uk\u003e\nCc: Alan Cox \u003calan@lxorguk.ukuu.org.uk\u003e\nCc: Paul Fulghum \u003cpaulkf@microgate.com\u003e\nCc: Casey Schaufler \u003ccasey@schaufler-ca.com\u003e\nCc: Steve Grubb \u003csgrubb@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "e18eecb8b35703a5eea73ee2b45324262029e62c",
      "tree": "8c276ae6633b8116ca366274091b00491fd50bbe",
      "parents": [
        "84812217e395f5272eac36856c0a2415d61fe139"
      ],
      "author": {
        "name": "Jeff Dike",
        "email": "jdike@addtoit.com",
        "time": "Sun Jul 15 23:38:48 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon Jul 16 09:05:38 2007 -0700"
      },
      "message": "Add generic exit-time stack-depth checking to CONFIG_DEBUG_STACK_USAGE\n\nAdd generic exit-time stack-depth checking to CONFIG_DEBUG_STACK_USAGE.\n\nThis also adds UML support.\n\nTested on UML and i386.\n\n[akpm@linux-foundation.org: cleanups, speedups, tweaks]\nSigned-off-by: Jeff Dike \u003cjdike@linux.intel.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: Ingo Molnar \u003cmingo@elte.hu\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "172ba844a8851c3edd13c0a979cdf46bd5e3cc1a",
      "tree": "5e1bfd820c8e68fc28450688f166f4136351e1e1",
      "parents": [
        "b27f03d4bdc145a09fb7b0c0e004b29f1ee555fa"
      ],
      "author": {
        "name": "Balbir Singh",
        "email": "balbir@linux.vnet.ibm.com",
        "time": "Mon Jul 09 18:52:00 2007 +0200"
      },
      "committer": {
        "name": "Ingo Molnar",
        "email": "mingo@elte.hu",
        "time": "Mon Jul 09 18:52:00 2007 +0200"
      },
      "message": "sched: update delay-accounting to use CFS\u0027s precise stats\n\nupdate delay-accounting to use CFS\u0027s precise stats.\n\nSigned-off-by: Ingo Molnar \u003cmingo@elte.hu\u003e\n"
    },
    {
      "commit": "e05606d3301525aa67b081ad9fccade2b31ab35a",
      "tree": "2a3e5a477dfca70ce32f3ea8dbc5e16034c98c23",
      "parents": [
        "138a8aeb5b9e5c5abd5e5ec22b6d1848e7e9c50b"
      ],
      "author": {
        "name": "Ingo Molnar",
        "email": "mingo@elte.hu",
        "time": "Mon Jul 09 18:51:59 2007 +0200"
      },
      "committer": {
        "name": "Ingo Molnar",
        "email": "mingo@elte.hu",
        "time": "Mon Jul 09 18:51:59 2007 +0200"
      },
      "message": "sched: clean up the rt priority macros\n\nclean up the rt priority macros, pointed out by Andrew Morton.\n\nSigned-off-by: Ingo Molnar \u003cmingo@elte.hu\u003e\n"
    },
    {
      "commit": "f64f61145a38f7039e4f1c0b50dcc3fbe70ec28e",
      "tree": "5864c65e858dc320ab16d6025132bd26d4f54e7e",
      "parents": [
        "c65cc8705256ad7524c97564b4fe3ca9782bf6d1"
      ],
      "author": {
        "name": "Ingo Molnar",
        "email": "mingo@elte.hu",
        "time": "Mon Jul 09 18:51:58 2007 +0200"
      },
      "committer": {
        "name": "Ingo Molnar",
        "email": "mingo@elte.hu",
        "time": "Mon Jul 09 18:51:58 2007 +0200"
      },
      "message": "sched: remove sched_exit()\n\nremove sched_exit(): the elaborate dance of us trying to recover\ntimeslices given to child tasks never really worked.\n\nCFS does not need it either.\n\nSigned-off-by: Ingo Molnar \u003cmingo@elte.hu\u003e\n"
    },
    {
      "commit": "778e9a9c3e7193ea9f434f382947155ffb59c755",
      "tree": "2ceb8c7ce1d55124982b77966dcd65cee5cc623b",
      "parents": [
        "1a539a87280b3032fd12bc93a4a82f1d8aa97ca8"
      ],
      "author": {
        "name": "Alexey Kuznetsov",
        "email": "kuznet@ms2.inr.ac.ru",
        "time": "Fri Jun 08 13:47:00 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri Jun 08 17:23:34 2007 -0700"
      },
      "message": "pi-futex: fix exit races and locking problems\n\n1. New entries can be added to tsk-\u003epi_state_list after task completed\n   exit_pi_state_list(). The result is memory leakage and deadlocks.\n\n2. handle_mm_fault() is called under spinlock. The result is obvious.\n\n3. results in self-inflicted deadlock inside glibc.\n   Sometimes futex_lock_pi returns -ESRCH, when it is not expected\n   and glibc enters to for(;;) sleep() to simulate deadlock. This problem\n   is quite obvious and I think the patch is right. Though it looks like\n   each \"if\" in futex_lock_pi() got some stupid special case \"else if\". :-)\n\n4. sometimes futex_lock_pi() returns -EDEADLK,\n   when nobody has the lock. The reason is also obvious (see comment\n   in the patch), but correct fix is far beyond my comprehension.\n   I guess someone already saw this, the chunk:\n\n                        if (rt_mutex_trylock(\u0026q.pi_state-\u003epi_mutex))\n                                ret \u003d 0;\n\n   is obviously from the same opera. But it does not work, because the\n   rtmutex is really taken at this point: wake_futex_pi() of previous\n   owner reassigned it to us. My fix works. But it looks very stupid.\n   I would think about removal of shift of ownership in wake_futex_pi()\n   and making all the work in context of process taking lock.\n\nFrom: Thomas Gleixner \u003ctglx@linutronix.de\u003e\n\nFix 1) Avoid the tasklist lock variant of the exit race fix by adding\n    an additional state transition to the exit code.\n\n    This fixes also the issue, when a task with recursive segfaults\n    is not able to release the futexes.\n\nFix 2) Cleanup the lookup_pi_state() failure path and solve the -ESRCH\n    problem finally.\n\nFix 3) Solve the fixup_pi_state_owner() problem which needs to do the fixup\n    in the lock protected section by using the in_atomic userspace access\n    functions.\n\n    This removes also the ugly lock drop / unqueue inside of fixup_pi_state()\n\nFix 4) Fix a stale lock in the error path of futex_wake_pi()\n\nAdded some error checks for verification.\n\nThe -EDEADLK problem is solved by the rtmutex fixups.\n\nSigned-off-by: Thomas Gleixner \u003ctglx@linutronix.de\u003e\nAcked-by: Ingo Molnar \u003cmingo@elte.hu\u003e\nCc: Steven Rostedt \u003crostedt@goodmis.org\u003e\nCc: Ulrich Drepper \u003cdrepper@redhat.com\u003e\nCc: Eric Dumazet \u003cdada1@cosmosbay.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "7bb44adef39ad3bda2be40bb34686bc56bd563a5",
      "tree": "1e9eecbd03877c7ac8b00a8cb1d4ae54ebec3bb1",
      "parents": [
        "3c6df2a9177c010bf811c361149069e4bfd9bb11"
      ],
      "author": {
        "name": "Roland McGrath",
        "email": "roland@redhat.com",
        "time": "Wed May 23 13:57:44 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed May 23 20:14:12 2007 -0700"
      },
      "message": "recalc_sigpending_tsk fixes\n\nSteve Hawkes discovered a problem where recalc_sigpending_tsk was called in\ndo_sigaction but no signal_wake_up call was made, preventing later signals\nfrom waking up blocked threads with TIF_SIGPENDING already set.\n\nIn fact, the few other calls to recalc_sigpending_tsk outside the signals\ncode are also subject to this problem in other race conditions.\n\nThis change makes recalc_sigpending_tsk private to the signals code.  It\nchanges the outside calls, as well as do_sigaction, to use the new\nrecalc_sigpending_and_wake instead.\n\nSigned-off-by: Roland McGrath \u003croland@redhat.com\u003e\nCc: \u003cSteve.Hawkes@motorola.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "fba2afaaec790dc5ab4ae8827972f342211bbb86",
      "tree": "2694d4cd8c6b7d69a5569b92151d61a3d4af39b7",
      "parents": [
        "5dc8bf8132d59c03fe2562bce165c2f03f021687"
      ],
      "author": {
        "name": "Davide Libenzi",
        "email": "davidel@xmailserver.org",
        "time": "Thu May 10 22:23:13 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri May 11 08:29:36 2007 -0700"
      },
      "message": "signal/timer/event: signalfd core\n\nThis patch series implements the new signalfd() system call.\n\nI took part of the original Linus code (and you know how badly it can be\nbroken :), and I added even more breakage ;) Signals are fetched from the same\nsignal queue used by the process, so signalfd will compete with standard\nkernel delivery in dequeue_signal().  If you want to reliably fetch signals on\nthe signalfd file, you need to block them with sigprocmask(SIG_BLOCK).  This\nseems to be working fine on my Dual Opteron machine.  I made a quick test\nprogram for it:\n\nhttp://www.xmailserver.org/signafd-test.c\n\nThe signalfd() system call implements signal delivery into a file descriptor\nreceiver.  The signalfd file descriptor if created with the following API:\n\nint signalfd(int ufd, const sigset_t *mask, size_t masksize);\n\nThe \"ufd\" parameter allows to change an existing signalfd sigmask, w/out going\nto close/create cycle (Linus idea).  Use \"ufd\" \u003d\u003d -1 if you want a brand new\nsignalfd file.\n\nThe \"mask\" allows to specify the signal mask of signals that we are interested\nin.  The \"masksize\" parameter is the size of \"mask\".\n\nThe signalfd fd supports the poll(2) and read(2) system calls.  The poll(2)\nwill return POLLIN when signals are available to be dequeued.  As a direct\nconsequence of supporting the Linux poll subsystem, the signalfd fd can use\nused together with epoll(2) too.\n\nThe read(2) system call will return a \"struct signalfd_siginfo\" structure in\nthe userspace supplied buffer.  The return value is the number of bytes copied\nin the supplied buffer, or -1 in case of error.  The read(2) call can also\nreturn 0, in case the sighand structure to which the signalfd was attached,\nhas been orphaned.  The O_NONBLOCK flag is also supported, and read(2) will\nreturn -EAGAIN in case no signal is available.\n\nIf the size of the buffer passed to read(2) is lower than sizeof(struct\nsignalfd_siginfo), -EINVAL is returned.  A read from the signalfd can also\nreturn -ERESTARTSYS in case a signal hits the process.  The format of the\nstruct signalfd_siginfo is, and the valid fields depends of the (-\u003ecode \u0026\n__SI_MASK) value, in the same way a struct siginfo would:\n\nstruct signalfd_siginfo {\n\t__u32 signo;\t/* si_signo */\n\t__s32 err;\t/* si_errno */\n\t__s32 code;\t/* si_code */\n\t__u32 pid;\t/* si_pid */\n\t__u32 uid;\t/* si_uid */\n\t__s32 fd;\t/* si_fd */\n\t__u32 tid;\t/* si_fd */\n\t__u32 band;\t/* si_band */\n\t__u32 overrun;\t/* si_overrun */\n\t__u32 trapno;\t/* si_trapno */\n\t__s32 status;\t/* si_status */\n\t__s32 svint;\t/* si_int */\n\t__u64 svptr;\t/* si_ptr */\n\t__u64 utime;\t/* si_utime */\n\t__u64 stime;\t/* si_stime */\n\t__u64 addr;\t/* si_addr */\n};\n\n[akpm@linux-foundation.org: fix signalfd_copyinfo() on i386]\nSigned-off-by: Davide Libenzi \u003cdavidel@xmailserver.org\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "e713d0dab21a68500720e222fa02567fc7dfb14b",
      "tree": "a56f90ce94d9287b73da6db72ed0e73542a70a07",
      "parents": [
        "4ac24b3ba9016881b11646114bb5cd12cf23edd9"
      ],
      "author": {
        "name": "Sukadev Bhattiprolu",
        "email": "sukadev@us.ibm.com",
        "time": "Thu May 10 22:22:58 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri May 11 08:29:35 2007 -0700"
      },
      "message": "attach_pid() with struct pid parameter\n\nattach_pid() currently takes a pid_t and then uses find_pid() to find the\ncorresponding struct pid.  Sometimes we already have the struct pid.  We can\nthen skip find_pid() if attach_pid() were to take a struct pid parameter.\n\nSigned-off-by: Sukadev Bhattiprolu \u003csukadev@us.ibm.com\u003e\nCc: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nCc: Dave Hansen \u003chaveblue@us.ibm.com\u003e\nCc: Serge Hallyn \u003cserue@us.ibm.com\u003e\nCc: \u003ccontainers@lists.osdl.org\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "6eaeeaba39e5fa3d52a0bb8de15e995516ae251a",
      "tree": "5b4052fabfe107ad5332cb758ad8d86ea5a87848",
      "parents": [
        "02239c29967418284c05d58971894d658575e78c"
      ],
      "author": {
        "name": "Eric Dumazet",
        "email": "dada1@cosmosbay.com",
        "time": "Thu May 10 22:22:37 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Fri May 11 08:29:34 2007 -0700"
      },
      "message": "getrusage(): fill ru_inblock and ru_oublock fields if possible\n\nIf CONFIG_TASK_IO_ACCOUNTING is defined, we update io accounting counters for\neach task.\n\nThis patch permits reporting of values using the well known getrusage()\nsyscall, filling ru_inblock and ru_oublock instead of null values.\n\nAs TASK_IO_ACCOUNTING currently counts bytes counts, we approximate blocks\ncount doing : nr_blocks \u003d nr_bytes / 512\n\nExample of use :\n----------------------\nAfter patch is applied, /usr/bin/time command can now give a good\napproximation of IO that the process had to do.\n\n$ /usr/bin/time grep tototo /usr/include/*\nCommand exited with non-zero status 1\n0.00user 0.02system 0:02.11elapsed 1%CPU (0avgtext+0avgdata 0maxresident)k\n24288inputs+0outputs (0major+259minor)pagefaults 0swaps\n\n$ /usr/bin/time dd if\u003d/dev/zero of\u003d/tmp/testfile count\u003d1000\n1000+0 enregistrements lus\n1000+0 enregistrements écrits\n512000 octets (512 kB) copiés, 0,00326601 seconde, 157 MB/s\n0.00user 0.00system 0:00.00elapsed 80%CPU (0avgtext+0avgdata 0maxresident)k\n0inputs+3000outputs (0major+299minor)pagefaults 0swaps\n\nSigned-off-by: Eric Dumazet \u003cdada1@cosmosbay.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "10ab825bdef8df510f99c703a5a2d9b13a4e31a5",
      "tree": "e4db81f26c03ba5a5bff43ed44646a4ed4509d67",
      "parents": [
        "5de18d169739293e27e0cf9acfc75a2d2f4aa572"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Wed May 09 02:34:37 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed May 09 12:30:53 2007 -0700"
      },
      "message": "change kernel threads to ignore signals instead of blocking them\n\nCurrently kernel threads use sigprocmask(SIG_BLOCK) to protect against\nsignals.  This doesn\u0027t prevent the signal delivery, this only blocks\nsignal_wake_up().  Every \"killall -33 kthreadd\" means a \"struct siginfo\"\nleak.\n\nChange kthreadd_setup() to set all handlers to SIG_IGN instead of blocking\nthem (make a new helper ignore_signals() for that).  If the kernel thread\nneeds some signal, it should use allow_signal() anyway, and in that case it\nshould not use CLONE_SIGHAND.\n\nNote that we can\u0027t change daemonize() (should die!) in the same way,\nbecause it can be used along with CLONE_SIGHAND.  This means that\nallow_signal() still should unblock the signal to work correctly with\ndaemonize()ed threads.\n\nHowever, disallow_signal() doesn\u0027t block the signal any longer but ignores\nit.\n\nNOTE: with or without this patch the kernel threads are not protected from\nhandle_stop_signal(), this seems harmless, but not good.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nAcked-by: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "49d769d52e16efabd3ad47b7995522fff771371d",
      "tree": "cf6ec2c39ae671c3f4cae34daf9d0558ca4fcf49",
      "parents": [
        "73c279927f89561ecb45b2dfdf9314bafcfd9f67"
      ],
      "author": {
        "name": "Eric W. Biederman",
        "email": "ebiederm@xmission.com",
        "time": "Wed May 09 02:34:33 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Wed May 09 12:30:53 2007 -0700"
      },
      "message": "Change reparent_to_init to reparent_to_kthreadd\n\nWhen a kernel thread calls daemonize, instead of reparenting the thread to\ninit reparent the thread to kthreadd next to the threads created by\nkthread_create.\n\nThis is really just a stop gap until daemonize goes away, but it does\nensure no kernel threads are under init and they are all in one place that\nis easy to find.\n\nSigned-off-by: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "e63340ae6b6205fef26b40a75673d1c9c0c8bb90",
      "tree": "8d3212705515edec73c3936bb9e23c71d34a7b41",
      "parents": [
        "04c9167f91e309c9c4ea982992aa08e83b2eb42e"
      ],
      "author": {
        "name": "Randy Dunlap",
        "email": "randy.dunlap@oracle.com",
        "time": "Tue May 08 00:28:08 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Tue May 08 11:15:07 2007 -0700"
      },
      "message": "header cleaning: don\u0027t include smp_lock.h when not used\n\nRemove includes of \u003clinux/smp_lock.h\u003e where it is not used/needed.\nSuggested by Al Viro.\n\nBuilds cleanly on x86_64, i386, alpha, ia64, powerpc, sparc,\nsparc64, and arm (all 59 defconfigs).\n\nSigned-off-by: Randy Dunlap \u003crandy.dunlap@oracle.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "73243284463a761e04d69d22c7516b2be7de096c",
      "tree": "1a823a613568b48d3a4db694aa02ce380643a3dc",
      "parents": [
        "906e0be197232c219197d058ef5095baa7764cd4"
      ],
      "author": {
        "name": "Roland McGrath",
        "email": "roland@redhat.com",
        "time": "Sun May 06 14:50:20 2007 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon May 07 12:12:57 2007 -0700"
      },
      "message": "Return EPERM not ECHILD on security_task_wait failure\n\nwait* syscalls return -ECHILD even when an individual PID of a live child\nwas requested explicitly, when security_task_wait denies the operation.\nThis means that something like a broken SELinux policy can produce an\nunexpected failure that looks just like a bug with wait or ptrace or\nsomething.\n\nThis patch makes do_wait return -EACCES (or other appropriate error returned\nfrom security_task_wait() instead of -ECHILD if some children were ruled out\nsolely because security_task_wait failed.\n\n[jmorris@namei.org: switch error code to EACCES]\nSigned-off-by: Roland McGrath \u003croland@redhat.com\u003e\nAcked-by: Stephen Smalley \u003csds@tycho.nsa.gov\u003e\nCc: Chris Wright \u003cchrisw@sous-sol.org\u003e\nCc: James Morris \u003cjmorris@namei.org\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "14e9d5730adfca26452b3a2838a80af6950556f5",
      "tree": "2288e59261478c013935cfe99e6565057e525452",
      "parents": [
        "c97beb4710bc673867207d7d729f2ace4ca1f197"
      ],
      "author": {
        "name": "Eric W. Biederman",
        "email": "ebiederm@xmission.com",
        "time": "Wed Mar 28 23:38:16 2007 -0600"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Thu Mar 29 08:16:23 2007 -0700"
      },
      "message": "[PATCH] pid: Properly detect orphaned process groups in exit_notify\n\nIn commit 0475ac0845f9295bc5f69af45f58dff2c104c8d1 when converting the\norphaned process group handling to use struct pid I made a small\nmistake.  I accidentally replaced an \u003d\u003d with a !\u003d.\n\nBesides just being a dumb thing to do apparently this has a bad side\neffect.  The improper orphaned process group detection causes kwin to\ndie after a suspend/resume cycle.\n\nI\u0027m amazed this patch has been around as long as it has without anyone\nelse noticing something funny going on.\n\nAnd the following people deserve credit for spotting and helping\nto reproduce this.\n\nThanks to: Sid Boyce \u003cg3vbv@blueyonder.co.uk\u003e\nThanks to: \"Michael Wu\"\n\nSigned-off-by: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "3e7cd6c413c9e6fbb5e1ee2acdadb4ababd2d474",
      "tree": "de97d00794ee0c787b6c551a91e33fb1faa48caa",
      "parents": [
        "0475ac0845f9295bc5f69af45f58dff2c104c8d1"
      ],
      "author": {
        "name": "Eric W. Biederman",
        "email": "ebiederm@xmission.com",
        "time": "Mon Feb 12 00:52:58 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon Feb 12 09:48:32 2007 -0800"
      },
      "message": "[PATCH] pid: replace is_orphaned_pgrp with is_current_pgrp_orphaned\n\nEvery call to is_orphaned_pgrp passed in process_group(current) which is racy\nwith respect to another thread changing our process group.  It didn\u0027t bite us\nbecause we were dealing with integers and the worse we would get would be a\nstale answer.\n\nIn switching the checks to use struct pid to be a little more efficient and\nprepare the way for pid namespaces this race became apparent.\n\nSo I simplified the calls to the more specialized is_current_pgrp_orphaned so\nI didn\u0027t have to worry about making logic changes to avoid the race.\n\nSigned-off-by: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Alan Cox \u003calan@lxorguk.ukuu.org.uk\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "0475ac0845f9295bc5f69af45f58dff2c104c8d1",
      "tree": "2052ddeb6cc271238a1470a2fb3a7082bb1eefd1",
      "parents": [
        "04a2e6a5cbf84e85fe86de0a18f6509b147e1d89"
      ],
      "author": {
        "name": "Eric W. Biederman",
        "email": "ebiederm@xmission.com",
        "time": "Mon Feb 12 00:52:57 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon Feb 12 09:48:32 2007 -0800"
      },
      "message": "[PATCH] pid: use struct pid for talking about process groups in exitc\n\nModify has_stopped_jobs and will_become_orphan_pgrp to use struct pid based\nprocess groups.  This reduces the number of hash tables looks ups and paves\nthe way for multiple pid spaces.\n\nSigned-off-by: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Alan Cox \u003calan@lxorguk.ukuu.org.uk\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "04a2e6a5cbf84e85fe86de0a18f6509b147e1d89",
      "tree": "67dd67d2c4c18e5c36654dfe569e3085bd262ba5",
      "parents": [
        "8d42db189ca99703f0f4f91c477cb54808c8eaaa"
      ],
      "author": {
        "name": "Eric W. Biederman",
        "email": "ebiederm@xmission.com",
        "time": "Mon Feb 12 00:52:56 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon Feb 12 09:48:31 2007 -0800"
      },
      "message": "[PATCH] pid: make session_of_pgrp use struct pid instead of pid_t\n\nTo properly implement a pid namespace I need to deal exclusively in terms of\nstruct pid, because pid_t values become ambiguous.\n\nTo this end session_of_pgrp is transformed to take and return a struct pid\npointer.  To avoid the need to worry about reference counting I now require my\ncaller to hold the appropriate locks.  Leaving callers repsonsible for\nincreasing the reference count if they need access to the result outside of\nthe locks.\n\nSince session_of_pgrp currently only has one caller and that caller simply\nuses only test the result for equality with another process group, the locking\nchange means I don\u0027t actually have to acquire the tasklist_lock at all.\n\ntiocspgrp is also modified to take and release the lock.  The logic there is a\nlittle more complicated but nothing I won\u0027t need when I convert pgrp of a tty\nto a struct pid pointer.\n\nSigned-off-by: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Alan Cox \u003calan@lxorguk.ukuu.org.uk\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "944be0b224724fcbf63c3a3fe3a5478c325a6547",
      "tree": "83877201ca028cf0ad3d7ee74d06c26d2dfde95e",
      "parents": [
        "92ba0ee2770ed4954e3f8ba412ef2f37e5519477"
      ],
      "author": {
        "name": "Ingo Molnar",
        "email": "mingo@elte.hu",
        "time": "Mon Feb 12 00:52:26 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Mon Feb 12 09:48:30 2007 -0800"
      },
      "message": "[PATCH] close_files(): add scheduling point\n\nclose_files() can sometimes take long enough to trigger the soft lockup\ndetector.\n\nCc: Eric Dumazet \u003cdada1@cosmosbay.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "72fd4a35a824331d7a0f4168d7576502d95d34b3",
      "tree": "be27880bc36b7f62e8044a88b8744a35c5317714",
      "parents": [
        "262086cf5b5343c2b81c97b1c606058e921859df"
      ],
      "author": {
        "name": "Robert P. J. Day",
        "email": "rpjday@mindspring.com",
        "time": "Sat Feb 10 01:45:59 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Sun Feb 11 10:51:32 2007 -0800"
      },
      "message": "[PATCH] Numerous fixes to kernel-doc info in source files.\n\nA variety of (mostly) innocuous fixes to the embedded kernel-doc content in\nsource files, including:\n\n  * make multi-line initial descriptions single line\n  * denote some function names, constants and structs as such\n  * change erroneous opening \u0027/*\u0027 to \u0027/**\u0027 in a few places\n  * reword some text for clarity\n\nSigned-off-by: Robert P. J. Day \u003crpjday@mindspring.com\u003e\nCc: \"Randy.Dunlap\" \u003crdunlap@xenotime.net\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "0f2452855d86901ba3766826ccb5606ea4e15ab9",
      "tree": "b5a48b7bc49bbfdf97434e4f9cc83607d78eb0de",
      "parents": [
        "444f378b237a0f728f5c4aba752c08d13c209344"
      ],
      "author": {
        "name": "Serge E. Hallyn",
        "email": "serue@us.ibm.com",
        "time": "Tue Jan 30 15:28:23 2007 -0600"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Tue Jan 30 13:40:36 2007 -0800"
      },
      "message": "[PATCH] namespaces: fix task exit disaster\n\nThis is based on a patch by Eric W.  Biederman, who pointed out that pid\nnamespaces are still fake, and we only have one ever active.\n\nSo for the time being, we can modify any code which could access\ntsk-\u003ensproxy-\u003epid_ns during task exit to just use \u0026init_pid_ns instead,\nand move the exit_task_namespaces call in do_exit() back above\nexit_notify(), so that an exiting nfs server has a valid tsk-\u003esighand to\nwork with.\n\nLong term, pulling pid_ns out of nsproxy might be the cleanest solution.\n\nSigned-off-by: Eric W. Biederman \u003cebiederm@xmission.com\u003e\n\n[ Eric\u0027s patch fixed to take care of free_pid() too ]\n\nSigned-off-by: Serge E. Hallyn \u003cserue@us.ibm.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "444f378b237a0f728f5c4aba752c08d13c209344",
      "tree": "248fd00bb2e60cb0890fce38b6a66fed65f977e4",
      "parents": [
        "8c8c4bafc3a20a6fb9078315ff865bc42276f9ba"
      ],
      "author": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Tue Jan 30 13:35:18 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Tue Jan 30 13:35:18 2007 -0800"
      },
      "message": "Revert \"[PATCH] namespaces: fix exit race by splitting exit\"\n\nThis reverts commit 7a238fcba0629b6f2edbcd37458bae56fcf36be5 in\npreparation for a better and simpler fix proposed by Eric Biederman\n(and fixed up by Serge Hallyn)\n\nAcked-by: Serge E. Hallyn \u003cserue@us.ibm.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "7a238fcba0629b6f2edbcd37458bae56fcf36be5",
      "tree": "ad556f0ec00637df5b4c4a2063c6b3325666d2f1",
      "parents": [
        "c0d4d573feed199b16094c072e7cb07afb01c598"
      ],
      "author": {
        "name": "Serge E. Hallyn",
        "email": "serue@us.ibm.com",
        "time": "Mon Jan 29 13:19:40 2007 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.linux-foundation.org",
        "time": "Tue Jan 30 08:26:44 2007 -0800"
      },
      "message": "[PATCH] namespaces: fix exit race by splitting exit\n\nFix exit race by splitting the nsproxy putting into two pieces.  First\npiece reduces the nsproxy refcount.  If we dropped the last reference, then\nit puts the mnt_ns, and returns the nsproxy as a hint to the caller.  Else\nit returns NULL.  The second piece of exiting task namespaces sets\ntsk-\u003ensproxy to NULL, and drops the references to other namespaces and\nfrees the nsproxy only if an nsproxy was passed in.\n\nA little awkward and should probably be reworked, but hopefully it fixes\nthe NFS oops.\n\nSigned-off-by: Serge E. Hallyn \u003cserue@us.ibm.com\u003e\nCc: Herbert Poetzl \u003cherbert@13thfloor.at\u003e\nCc: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nCc: \"Eric W. Biederman\" \u003cebiederm@xmission.com\u003e\nCc: Cedric Le Goater \u003cclg@fr.ibm.com\u003e\nCc: Daniel Hokka Zakrisson \u003cdaniel@hozac.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@osdl.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "241ceee0b442c69226fb882d61d9b9785743898f",
      "tree": "398eb111e2addcc7e5cc1f1c30006b9ec92b7a0e",
      "parents": [
        "9d572ecbd81b9ff6e6a9bc0d2598212a59eb738a"
      ],
      "author": {
        "name": "Oleg Nesterov",
        "email": "oleg@tv-sign.ru",
        "time": "Sun Dec 24 23:30:44 2006 +0300"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.osdl.org",
        "time": "Sun Dec 31 14:41:18 2006 -0800"
      },
      "message": "[PATCH] restore -\u003epdeath_signal behaviour\n\nCommit b2b2cbc4b2a2f389442549399a993a8306420baf introduced a user-\nvisible change: -\u003epdeath_signal is sent only when the entire thread\ngroup exits.\n\nWhile this change is imho good, it may break things.  So restore the\nold behaviour for now.\n\nSigned-off-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nTo: Albert Cahalan \u003cacahalan@gmail.com\u003e\nCc: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Andrew Morton \u003cakpm@osdl.org\u003e\nCc: Linus Torvalds \u003ctorvalds@osdl.org\u003e\nCc: Ingo Molnar \u003cmingo@elte.hu\u003e\nCc: Qi Yong \u003cqiyong@fc-cn.com\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@osdl.org\u003e\n"
    },
    {
      "commit": "b2b2cbc4b2a2f389442549399a993a8306420baf",
      "tree": "f734441636bbeba1c07aeeb84a05e0deac7b8d64",
      "parents": [
        "ef129412b4cbd6686d0749612cb9b76e207271f4"
      ],
      "author": {
        "name": "Eric W. Biederman",
        "email": "ebiederm@xmission.com",
        "time": "Thu Dec 21 21:28:40 2006 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.osdl.org",
        "time": "Fri Dec 22 09:03:41 2006 -0800"
      },
      "message": "[PATCH] Fix reparenting to the same thread group. (take 2)\n\nThis patch fixes the case when we reparent to a different thread in the\nsame thread group.  This modifies the code so that we do not send\nsignals and do not change the signal to send to SIGCHLD unless we have\nchange the thread group of our parents.  It also suppresses sending\npdeath_sig in this cas as well since the result of geppid doesn\u0027t\nchange.\n\nThanks to Oleg for spotting my bug of only fixing this for non-ptraced\ntasks.\n\nSigned-off-by: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nCc: Mike Galbraith \u003cefault@gmx.de\u003e\nCc: Albert Cahalan \u003cacahalan@gmail.com\u003e\nCc: Andrew Morton \u003cakpm@osdl.org\u003e\nCc: Roland McGrath \u003croland@redhat.com\u003e\nCc: Ingo Molnar \u003cmingo@elte.hu\u003e\nCc: Coywolf Qi Hunt \u003cqiyong@fc-cn.com\u003e\nAcked-by: Oleg Nesterov \u003coleg@tv-sign.ru\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@osdl.org\u003e\n"
    },
    {
      "commit": "01b2d93ca4c495f056471189ac6c4e6ac4cbbccb",
      "tree": "86aa1aabae8207e693e31ee68b526376388a36a3",
      "parents": [
        "31fccf7fe4097e62f038bdfe8f4f68ecaea8ebe7"
      ],
      "author": {
        "name": "Vadim Lobanov",
        "email": "vlobanov@speakeasy.net",
        "time": "Fri Dec 22 01:10:43 2006 -0800"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@woody.osdl.org",
        "time": "Fri Dec 22 08:55:50 2006 -0800"
      },
      "message": "[PATCH] fdtable: Provide free_fdtable() wrapper\n\nChristoph Hellwig has expressed concerns that the recent fdtable changes\nexpose the details of the RCU methodology used to release no-longer-used\nfdtable structures to the rest of the kernel.  The trivial patch below\naddresses these concerns by introducing the appropriate free_fdtable()\ncalls, which simply wrap the release RCU usage.  Since free_fdtable() is a\none-liner, it makes sense to promote it to an inline helper.\n\nSigned-off-by: Vadim Lobanov \u003cvlobanov@speakeasy.net\u003e\nCc: Christoph Hellwig \u003chch@lst.de\u003e\nSigned-off-by: Andrew Morton \u003cakpm@osdl.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@osdl.org\u003e\n"
    }
  ],
  "next": "4fd45812cbe875a620c86a096a5d46c742694b7e"
}
