)]}'
{
  "commit": "336cdb4003200a90f4fc52a4e9ccc2baa570fffb",
  "tree": "dcb7f736738232c0e853a1ba796ca35d5b18c503",
  "parents": [
    "91525300baf162e83e923b09ca286f9205e21522"
  ],
  "author": {
    "name": "Kiyoshi Ueda",
    "email": "k-ueda@ct.jp.nec.com",
    "time": "Tue Dec 11 17:40:30 2007 -0500"
  },
  "committer": {
    "name": "Jens Axboe",
    "email": "jens.axboe@oracle.com",
    "time": "Mon Jan 28 10:35:53 2008 +0100"
  },
  "message": "blk_end_request: add new request completion interface (take 4)\n\nThis patch adds 2 new interfaces for request completion:\n  o blk_end_request()   : called without queue lock\n  o __blk_end_request() : called with queue lock held\n\nblk_end_request takes \u0027error\u0027 as an argument instead of \u0027uptodate\u0027,\nwhich current end_that_request_* take.\nThe meanings of values are below and the value is used when bio is\ncompleted.\n    0 : success\n  \u003c 0 : error\n\nSome device drivers call some generic functions below between\nend_that_request_{first/chunk} and end_that_request_last().\n  o add_disk_randomness()\n  o blk_queue_end_tag()\n  o blkdev_dequeue_request()\nThese are called in the blk_end_request interfaces as a part of\ngeneric request completion.\nSo all device drivers become to call above functions.\nTo decide whether to call blkdev_dequeue_request(), blk_end_request\nuses list_empty(\u0026rq-\u003equeuelist) (blk_queued_rq() macro is added for it).\nSo drivers must re-initialize it using list_init() or so before calling\nblk_end_request if drivers use it for its specific purpose.\n(Currently, there is no driver which completes request without\n re-initializing the queuelist after used it.  So rq-\u003equeuelist\n can be used for the purpose above.)\n\n\"Normal\" drivers can be converted to use blk_end_request()\nin a standard way shown below.\n\n a) end_that_request_{chunk/first}\n    spin_lock_irqsave()\n    (add_disk_randomness(), blk_queue_end_tag(), blkdev_dequeue_request())\n    end_that_request_last()\n    spin_unlock_irqrestore()\n    \u003d\u003e blk_end_request()\n\n b) spin_lock_irqsave()\n    end_that_request_{chunk/first}\n    (add_disk_randomness(), blk_queue_end_tag(), blkdev_dequeue_request())\n    end_that_request_last()\n    spin_unlock_irqrestore()\n    \u003d\u003e spin_lock_irqsave()\n       __blk_end_request()\n       spin_unlock_irqsave()\n\n c) spin_lock_irqsave()\n    (add_disk_randomness(), blk_queue_end_tag(), blkdev_dequeue_request())\n    end_that_request_last()\n    spin_unlock_irqrestore()\n    \u003d\u003e blk_end_request()   or   spin_lock_irqsave()\n                                __blk_end_request()\n                                spin_unlock_irqrestore()\n\nSigned-off-by: Kiyoshi Ueda \u003ck-ueda@ct.jp.nec.com\u003e\nSigned-off-by: Jun\u0027ichi Nomura \u003cj-nomura@ce.jp.nec.com\u003e\nSigned-off-by: Jens Axboe \u003cjens.axboe@oracle.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "3d0422f48453c0019ad8d1de25eaa4643bb379fe",
      "old_mode": 33188,
      "old_path": "block/ll_rw_blk.c",
      "new_id": "5c01911af47c87ca61e9f4e241d7145c64e2d417",
      "new_mode": 33188,
      "new_path": "block/ll_rw_blk.c"
    },
    {
      "type": "modify",
      "old_id": "49b7a4c31a6d5d35af9c3e11e24791afe86faaf4",
      "old_mode": 33188,
      "old_path": "include/linux/blkdev.h",
      "new_id": "3b212f02db8df6b5570306e24fe8d482e7a69fec",
      "new_mode": 33188,
      "new_path": "include/linux/blkdev.h"
    }
  ]
}
