)]}'
{
  "commit": "574823bfab82d9d8fa47f422778043fbb4b4f50e",
  "tree": "62ee7a3d62dc1be896c689480a825a684bb1d71e",
  "parents": [
    "94bd8a05cd4de344a9a57e52ef7d99550251984f"
  ],
  "author": {
    "name": "Linus Torvalds",
    "email": "torvalds@linux-foundation.org",
    "time": "Sat Jan 05 17:50:59 2019 -0800"
  },
  "committer": {
    "name": "Linus Torvalds",
    "email": "torvalds@linux-foundation.org",
    "time": "Sun Jan 06 13:43:02 2019 -0800"
  },
  "message": "Change mincore() to count \"mapped\" pages rather than \"cached\" pages\n\nThe semantics of what \"in core\" means for the mincore() system call are\nsomewhat unclear, but Linux has always (since 2.3.52, which is when\nmincore() was initially done) treated it as \"page is available in page\ncache\" rather than \"page is mapped in the mapping\".\n\nThe problem with that traditional semantic is that it exposes a lot of\nsystem cache state that it really probably shouldn\u0027t, and that users\nshouldn\u0027t really even care about.\n\nSo let\u0027s try to avoid that information leak by simply changing the\nsemantics to be that mincore() counts actual mapped pages, not pages\nthat might be cheaply mapped if they were faulted (note the \"might be\"\npart of the old semantics: being in the cache doesn\u0027t actually guarantee\nthat you can access them without IO anyway, since things like network\nfilesystems may have to revalidate the cache before use).\n\nIn many ways the old semantics were somewhat insane even aside from the\ninformation leak issue.  From the very beginning (and that beginning is\na long time ago: 2.3.52 was released in March 2000, I think), the code\nhad a comment saying\n\n  Later we can get more picky about what \"in core\" means precisely.\n\nand this is that \"later\".  Admittedly it is much later than is really\ncomfortable.\n\nNOTE! This is a real semantic change, and it is for example known to\nchange the output of \"fincore\", since that program literally does a\nmmmap without populating it, and then doing \"mincore()\" on that mapping\nthat doesn\u0027t actually have any pages in it.\n\nI\u0027m hoping that nobody actually has any workflow that cares, and the\ninfo leak is real.\n\nWe may have to do something different if it turns out that people have\nvalid reasons to want the old semantics, and if we can limit the\ninformation leak sanely.\n\nCc: Kevin Easton \u003ckevin@guarana.org\u003e\nCc: Jiri Kosina \u003cjikos@kernel.org\u003e\nCc: Masatake YAMATO \u003cyamato@redhat.com\u003e\nCc: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nCc: Greg KH \u003cgregkh@linuxfoundation.org\u003e\nCc: Peter Zijlstra \u003cpeterz@infradead.org\u003e\nCc: Michal Hocko \u003cmhocko@suse.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "218099b5ed31d1e971d8d64b0951a31b8e310c01",
      "old_mode": 33188,
      "old_path": "mm/mincore.c",
      "new_id": "f0f91461a9f45c350fd8fccc0ccaf6c9578e4b3a",
      "new_mode": 33188,
      "new_path": "mm/mincore.c"
    }
  ]
}
