)]}'
{
  "commit": "901608d9045146aec6f14a7777ea4b1501c379f0",
  "tree": "0155189f48479b920855dedccba6829363376d4d",
  "parents": [
    "67d58ac47d25f7e2a105248a4aea6113131ab874"
  ],
  "author": {
    "name": "Oleg Nesterov",
    "email": "oleg@redhat.com",
    "time": "Tue Jan 06 14:40:29 2009 -0800"
  },
  "committer": {
    "name": "Linus Torvalds",
    "email": "torvalds@linux-foundation.org",
    "time": "Tue Jan 06 15:59:09 2009 -0800"
  },
  "message": "mm: introduce get_mm_hiwater_xxx(), fix taskstats-\u003ehiwater_xxx accounting\n\nxacct_add_tsk() relies on do_exit()-\u003eupdate_hiwater_xxx() and uses\nmm-\u003ehiwater_xxx directly, this leads to 2 problems:\n\n- taskstats_user_cmd() can call fill_pid()-\u003exacct_add_tsk() at any\n  moment before the task exits, so we should check the current values of\n  rss/vm anyway.\n\n- do_exit()-\u003eupdate_hiwater_xxx() calls are racy.  An exiting thread can\n  be preempted right before mm-\u003ehiwater_xxx \u003d new_val, and another thread\n  can use A_LOT of memory and exit in between.  When the first thread\n  resumes it can be the last thread in the thread group, in that case we\n  report the wrong hiwater_xxx values which do not take A_LOT into\n  account.\n\nIntroduce get_mm_hiwater_rss() and get_mm_hiwater_vm() helpers and change\nxacct_add_tsk() to use them.  The first helper will also be used by\nrusage-\u003eru_maxrss accounting.\n\nKill do_exit()-\u003eupdate_hiwater_xxx() calls.  Unless we are going to\ndecrease rss/vm there is no point to update mm-\u003ehiwater_xxx, and nobody\ncan look at this mm_struct when exit_mmap() actually unmaps the memory.\n\nSigned-off-by: Oleg Nesterov \u003coleg@redhat.com\u003e\nAcked-by: Hugh Dickins \u003chugh@veritas.com\u003e\nReviewed-by: KOSAKI Motohiro \u003ckosaki.motohiro@jp.fujitsu.com\u003e\nAcked-by: Balbir Singh \u003cbalbir@linux.vnet.ibm.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "38a3f4b1539466cb1bd483c1b2daa6d1e2dc42ab",
      "old_mode": 33188,
      "old_path": "include/linux/sched.h",
      "new_id": "ea415136ac9e27ff150ac995fddd867145c019f6",
      "new_mode": 33188,
      "new_path": "include/linux/sched.h"
    },
    {
      "type": "modify",
      "old_id": "f923724ab3c9d3ac43ed0cc9bd7980842e4e9c32",
      "old_mode": 33188,
      "old_path": "kernel/exit.c",
      "new_id": "c7740fa3252cb0ab24d8f07bd89acf47006c3d60",
      "new_mode": 33188,
      "new_path": "kernel/exit.c"
    },
    {
      "type": "modify",
      "old_id": "2dc06ab357169ba78ea7397e7aab6d03961ffb4e",
      "old_mode": 33188,
      "old_path": "kernel/tsacct.c",
      "new_id": "43f891b05a4b8911c13c5baa6420f63eb69aa3f6",
      "new_mode": 33188,
      "new_path": "kernel/tsacct.c"
    },
    {
      "type": "modify",
      "old_id": "e4507b23e6208909caaed2ffc00c090b18131447",
      "old_mode": 33188,
      "old_path": "mm/mmap.c",
      "new_id": "1f97d8aa9b05fa16784cf0f8870bd3ba66f225b5",
      "new_mode": 33188,
      "new_path": "mm/mmap.c"
    }
  ]
}
