)]}'
{
  "commit": "a6c15c2b0fbfd5c0a84f5f0e1e3f20f85d2b8692",
  "tree": "87af8336e669c8e63fda7d57b0650b5a806f77ff",
  "parents": [
    "9f7dd93de07420b423336d5d0028959e94778ddb"
  ],
  "author": {
    "name": "Vasily Averin",
    "email": "vvs@sw.ru",
    "time": "Sun Jul 15 23:40:46 2007 -0700"
  },
  "committer": {
    "name": "Linus Torvalds",
    "email": "torvalds@woody.linux-foundation.org",
    "time": "Mon Jul 16 09:05:46 2007 -0700"
  },
  "message": "ext3/ext4: orphan list corruption due bad inode\n\nAfter ext3 orphan list check has been added into ext3_destroy_inode()\n(please see my previous patch) the following situation has been detected:\n\n EXT3-fs warning (device sda6): ext3_unlink: Deleting nonexistent file (37901290), 0\n Inode 00000101a15b7840: orphan list check failed!\n 00000773 6f665f00 74616d72 00000573 65725f00 06737270 66000000 616d726f\n...\n Call Trace: [\u003cffffffff80211ea9\u003e] ext3_destroy_inode+0x79/0x90\n  [\u003cffffffff801a2b16\u003e] sys_unlink+0x126/0x1a0\n  [\u003cffffffff80111479\u003e] error_exit+0x0/0x81\n  [\u003cffffffff80110aba\u003e] system_call+0x7e/0x83\n\nFirst messages said that unlinked inode has i_nlink\u003d0, then ext3_unlink()\nadds this inode into orphan list.\n\nSecond message means that this inode has not been removed from orphan list.\n Inode dump has showed that i_fop \u003d \u0026bad_file_ops and it can be set in\nmake_bad_inode() only.  Then I\u0027ve found that ext3_read_inode() can call\nmake_bad_inode() without any error/warning messages, for example in the\nfollowing case:\n\n...\n        if (inode-\u003ei_nlink \u003d\u003d 0) {\n                if (inode-\u003ei_mode \u003d\u003d 0 ||\n                    !(EXT3_SB(inode-\u003ei_sb)-\u003es_mount_state \u0026 EXT3_ORPHAN_FS)) {\n                        /* this inode is deleted */\n                        brelse (bh);\n                        goto bad_inode;\n...\n\nBad inode can live some time, ext3_unlink can add it to orphan list, but\next3_delete_inode() do not deleted this inode from orphan list.  As result\nwe can have orphan list corruption detected in ext3_destroy_inode().\n\nHowever it is not clear for me how to fix this issue correctly.\n\nAs far as i see is_bad_inode() is called after iget() in all places\nexcluding ext3_lookup() and ext3_get_parent().  I believe it makes sense to\nadd bad inode check to these functions too and call iput if bad inode\ndetected.\n\nSigned-off-by:\tVasily Averin \u003cvvs@sw.ru\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "9bb046df827a7a7a4d694dad36d727a71237a652",
      "old_mode": 33188,
      "old_path": "fs/ext3/namei.c",
      "new_id": "1586807b81779ef9c02008e6828c9df50d4f000c",
      "new_mode": 33188,
      "new_path": "fs/ext3/namei.c"
    },
    {
      "type": "modify",
      "old_id": "2811e5720ad019d18e9976ac8afc21e3c885768b",
      "old_mode": 33188,
      "old_path": "fs/ext4/namei.c",
      "new_id": "2de339dd755431fdde691de2f299d5fe62a4d28a",
      "new_mode": 33188,
      "new_path": "fs/ext4/namei.c"
    }
  ]
}
