• Chao Yu's avatar
    f2fs: clear nlink if fail to add_link · a11b9f65
    Chao Yu authored
    We don't need to keep incomplete created inode in cache, so if we fail to
    add link into directory during new inode creation, it's better to set
    nlink of inode to zero, then we can evict inode immediately. Otherwise
    release of nid belong to inode will be delayed until inode cache is being
    shrunk, it may cause a seemingly endless loop while allocating free nids
    in time of testing generic/269 case of fstest suit.
    Signed-off-by: default avatarChao Yu <yuchao0@huawei.com>
    [Jaegeuk Kim: add update_inode_page to fix kernel panic]
    Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
    a11b9f65
inode.c 12.1 KB