)]}'
{
  "commit": "e3816255bf4b6377bb405331e2ee0dc14d841b80",
  "tree": "0589828bf3ea1633c80d5ff2ba127a0c28ad525b",
  "parents": [
    "1fa795a853255fcc93e5d3e2a92d161a2ed96eb8"
  ],
  "author": {
    "name": "Denis V. Lunev",
    "email": "den@openvz.org",
    "time": "Mon Jun 15 13:52:52 2015 +0300"
  },
  "committer": {
    "name": "Michael S. Tsirkin",
    "email": "mst@redhat.com",
    "time": "Tue Jun 23 17:08:21 2015 +0200"
  },
  "message": "balloon: add a feature bit to let Guest OS deflate balloon on oom\n\nExcessive virtio_balloon inflation can cause invocation of OOM-killer,\nwhen Linux is under severe memory pressure. Various mechanisms are\nresponsible for correct virtio_balloon memory management. Nevertheless it\nis often the case that these control tools does not have enough time to\nreact on fast changing memory load. As a result OS runs out of memory and\ninvokes OOM-killer. The balancing of memory by use of the virtio balloon\nshould not cause the termination of processes while there are pages in the\nballoon. Now there is no way for virtio balloon driver to free memory at\nthe last moment before some process get killed by OOM-killer.\n\nThis does not provide a security breach as balloon itself is running\ninside Guest OS and is working in the cooperation with the host. Thus\nsome improvements from Guest side should be considered as normal.\n\nTo solve the problem, introduce a virtio_balloon callback which is\nexpected to be called from the oom notifier call chain in out_of_memory()\nfunction. If virtio balloon could release some memory, it will make the\nsystem return and retry the allocation that forced the out of memory\nkiller to run.\n\nThis behavior should be enabled if and only if appropriate feature bit\nis set on the device. It is off by default.\n\nThis functionality was recently merged into vanilla Linux.\n\n  commit 5a10b7dbf904bfe01bb9fcc6298f7df09eed77d5\n  Author: Raushaniya Maksudova \u003crmaksudova@parallels.com\u003e\n  Date:   Mon Nov 10 09:36:29 2014 +1030\n\nThis patch adds respective control bits into QEMU. It introduces\ndeflate-on-oom option for balloon device which does the trick.\n\nSigned-off-by: Denis V. Lunev \u003cden@openvz.org\u003e\nCC: Raushaniya Maksudova \u003crmaksudova@parallels.com\u003e\nCC: Anthony Liguori \u003caliguori@amazon.com\u003e\nCC: Michael S. Tsirkin \u003cmst@redhat.com\u003e\nReviewed-by: Michael S. Tsirkin \u003cmst@redhat.com\u003e\nSigned-off-by: Michael S. Tsirkin \u003cmst@redhat.com\u003e\n\nAcked-by: James Bottomley \u003cJBottomley@Odin.com\u003e\nReviewed-by: Christian Borntraeger \u003cborntraeger@de.ibm.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "78bc14fc85e267052b59e4a45aa840d5129411b8",
      "old_mode": 33188,
      "old_path": "hw/virtio/virtio-balloon.c",
      "new_id": "2990f8de5d79b00a740480f37d2885b57186646d",
      "new_mode": 33188,
      "new_path": "hw/virtio/virtio-balloon.c"
    },
    {
      "type": "modify",
      "old_id": "346a9fdb7d41b165b1bbb129c9f0ca63aec0c068",
      "old_mode": 33188,
      "old_path": "include/hw/virtio/virtio-balloon.h",
      "new_id": "09c2ce4dcd6b5b3fc54a4e1da4c4bce66b3dc0e6",
      "new_mode": 33188,
      "new_path": "include/hw/virtio/virtio-balloon.h"
    }
  ]
}
