)]}'
{
  "commit": "33b53716bc4b3ff3da2bc41581226424443f9d5a",
  "tree": "a5127c750fe3297365dad1f5e3881666f363e11c",
  "parents": [
    "431e1ecabddcd7cbba237182ddf431771f98bb4c"
  ],
  "author": {
    "name": "Grant Erickson",
    "email": "marathon96@gmail.com",
    "time": "Fri Apr 08 08:51:32 2011 -0700"
  },
  "committer": {
    "name": "David Woodhouse",
    "email": "David.Woodhouse@intel.com",
    "time": "Wed May 25 01:59:43 2011 +0100"
  },
  "message": "mtd: create function to perform large allocations\n\nIntroduce a common function to handle large, contiguous kmalloc buffer\nallocations by exponentially backing off on the size of the requested\nkernel transfer buffer until it succeeds or until the requested\ntransfer buffer size falls below the page size.\n\nThis helps ensure the operation can succeed under low-memory, highly-\nfragmented situations albeit somewhat more slowly.\n\nArtem: so this patch solves the problem that the kernel tries to kmalloc too\nlarge buffers, which (a) may fail and does fail - people complain about this,\nand (b) slows down the system in case of high memory fragmentation, because\nthe kernel starts dropping caches, writing back, swapping, etc. But we do not\nreally have to allocate a lot of memory to do the I/O, we may do this even with\nas little as one min. I/O unit (NAND page) of RAM. So the idea of this patch is\nthat if the user asks to read or write a lot, we try to kmalloc a lot, with GFP\nflags which make the kernel _not_ drop caches, etc. If we can allocate it - good,\nif not - we try to allocate twice as less, and so on, until we reach the min.\nI/O unit size, which is our last resort allocation and use the normal\nGFP_KERNEL flag.\n\nArtem: re-write the allocation function so that it makes sure the allocated\nbuffer is aligned to the min. I/O size of the flash.\n\nSigned-off-by: Grant Erickson \u003cmarathon96@gmail.com\u003e\nTested-by: Ben Gardiner \u003cbengardiner@nanometrics.ca\u003e\nTested-by: Stefano Babic \u003csbabic@denx.de\u003e\nSigned-off-by: Artem Bityutskiy \u003cArtem.Bityutskiy@nokia.com\u003e\nSigned-off-by: David Woodhouse \u003cDavid.Woodhouse@intel.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "da69bc8a5a7d6f92c313fe2df32c644b9a0614f6",
      "old_mode": 33188,
      "old_path": "drivers/mtd/mtdcore.c",
      "new_id": "a50348b60d79c62cda4311e18b3264403f057400",
      "new_mode": 33188,
      "new_path": "drivers/mtd/mtdcore.c"
    },
    {
      "type": "modify",
      "old_id": "9d5306bad117fcc850bf3c440127b56efb1ce027",
      "old_mode": 33188,
      "old_path": "include/linux/mtd/mtd.h",
      "new_id": "06b489a7605be3fd0c36a4ba5337efe4f3c5a0e4",
      "new_mode": 33188,
      "new_path": "include/linux/mtd/mtd.h"
    }
  ]
}
