btrfs: clear __GFP_FS flag in the space cache inode

the object id of the space cache inode's key is allocated from the relative
root, just like the regular file. So we can't identify space cache inode by
checking the object id of the inode's key, and we have to clear __GFP_FS flag
at the time we look up the space cache inode.

Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
Signed-off-by: Liu Bo <liubo2009@cn.fujitsu.com>
Signed-off-by: Chris Mason <chris.mason@oracle.com>

authored by Miao Xie and committed by Chris Mason adae52b9 6e8df2ae

+2 -2
+2
fs/btrfs/free-space-cache.c
··· 81 81 return ERR_PTR(-ENOENT); 82 82 } 83 83 84 + inode->i_mapping->flags &= ~__GFP_FS; 85 + 84 86 spin_lock(&block_group->lock); 85 87 if (!root->fs_info->closing) { 86 88 block_group->inode = igrab(inode);
-2
fs/btrfs/inode.c
··· 2535 2535 BTRFS_I(inode)->flags = btrfs_inode_flags(leaf, inode_item); 2536 2536 2537 2537 alloc_group_block = btrfs_inode_block_group(leaf, inode_item); 2538 - if (location.objectid == BTRFS_FREE_SPACE_OBJECTID) 2539 - inode->i_mapping->flags &= ~__GFP_FS; 2540 2538 2541 2539 /* 2542 2540 * try to precache a NULL acl entry for files that don't have