)]}'
{
  "commit": "5a7aadfe2fcb0f69e2acc1fbefe22a096e792fc9",
  "tree": "dc1b649fc6aa05ecd25cab23e464894e660830d5",
  "parents": [
    "4f598458ea4450f53e8ed929ee4e66b3404a7286"
  ],
  "author": {
    "name": "Matt Helsley",
    "email": "matthltc@us.ibm.com",
    "time": "Fri Mar 26 23:51:44 2010 +0100"
  },
  "committer": {
    "name": "Rafael J. Wysocki",
    "email": "rjw@sisk.pl",
    "time": "Fri Mar 26 23:51:44 2010 +0100"
  },
  "message": "Freezer: Fix buggy resume test for tasks frozen with cgroup freezer\n\nWhen the cgroup freezer is used to freeze tasks we do not want to thaw\nthose tasks during resume. Currently we test the cgroup freezer\nstate of the resuming tasks to see if the cgroup is FROZEN.  If so\nthen we don\u0027t thaw the task. However, the FREEZING state also indicates\nthat the task should remain frozen.\n\nThis also avoids a problem pointed out by Oren Ladaan: the freezer state\ntransition from FREEZING to FROZEN is updated lazily when userspace reads\nor writes the freezer.state file in the cgroup filesystem. This means that\nresume will thaw tasks in cgroups which should be in the FROZEN state if\nthere is no read/write of the freezer.state file to trigger this\ntransition before suspend.\n\nNOTE: Another \"simple\" solution would be to always update the cgroup\nfreezer state during resume. However it\u0027s a bad choice for several reasons:\nUpdating the cgroup freezer state is somewhat expensive because it requires\nwalking all the tasks in the cgroup and checking if they are each frozen.\nWorse, this could easily make resume run in N^2 time where N is the number\nof tasks in the cgroup. Finally, updating the freezer state from this code\npath requires trickier locking because of the way locks must be ordered.\n\nInstead of updating the freezer state we rely on the fact that lazy\nupdates only manage the transition from FREEZING to FROZEN. We know that\na cgroup with the FREEZING state may actually be FROZEN so test for that\nstate too. This makes sense in the resume path even for partially-frozen\ncgroups -- those that really are FREEZING but not FROZEN.\n\nReported-by: Oren Ladaan \u003corenl@cs.columbia.edu\u003e\nSigned-off-by: Matt Helsley \u003cmatthltc@us.ibm.com\u003e\nCc: stable@kernel.org\nSigned-off-by: Rafael J. Wysocki \u003crjw@sisk.pl\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "5a361f85cfec483e0a595dcb2f4c2ee632ac56d9",
      "old_mode": 33188,
      "old_path": "include/linux/freezer.h",
      "new_id": "da7e52b099f3221cf723f008aa2ac627d276e11b",
      "new_mode": 33188,
      "new_path": "include/linux/freezer.h"
    },
    {
      "type": "modify",
      "old_id": "59e9ef6aab4002e1d99170f50156e733e8f46343",
      "old_mode": 33188,
      "old_path": "kernel/cgroup_freezer.c",
      "new_id": "eb3f34d574196a8adb00c8327500f40c9ac03c5c",
      "new_mode": 33188,
      "new_path": "kernel/cgroup_freezer.c"
    },
    {
      "type": "modify",
      "old_id": "a0480cd4daaf13ca94f8679103400c5f1a2ab068",
      "old_mode": 33188,
      "old_path": "kernel/power/process.c",
      "new_id": "71ae29052ab6c2275c6f48239b56cdd4be4cba33",
      "new_mode": 33188,
      "new_path": "kernel/power/process.c"
    }
  ]
}
