mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-09-04 20:19:47 +08:00
gfs2: Remove GIF_ALLOC_FAILED flag
Get rid of the GIF_ALLOC_FAILED flag; we can now be confident that the additional consistency check isn't needed. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
This commit is contained in:
parent
00983d248c
commit
2c6e2cb9e7
@ -375,7 +375,6 @@ struct gfs2_glock {
|
|||||||
|
|
||||||
enum {
|
enum {
|
||||||
GIF_QD_LOCKED = 1,
|
GIF_QD_LOCKED = 1,
|
||||||
GIF_ALLOC_FAILED = 2,
|
|
||||||
GIF_SW_PAGED = 3,
|
GIF_SW_PAGED = 3,
|
||||||
GIF_FREE_VFS_INODE = 5,
|
GIF_FREE_VFS_INODE = 5,
|
||||||
GIF_GLOP_PENDING = 6,
|
GIF_GLOP_PENDING = 6,
|
||||||
|
@ -444,11 +444,9 @@ static void gfs2_final_release_pages(struct gfs2_inode *ip)
|
|||||||
struct inode *inode = &ip->i_inode;
|
struct inode *inode = &ip->i_inode;
|
||||||
struct gfs2_glock *gl = ip->i_gl;
|
struct gfs2_glock *gl = ip->i_gl;
|
||||||
|
|
||||||
if (unlikely(!gl)) {
|
/* This can only happen during incomplete inode creation. */
|
||||||
/* This can only happen during incomplete inode creation. */
|
if (unlikely(!gl))
|
||||||
BUG_ON(!test_bit(GIF_ALLOC_FAILED, &ip->i_flags));
|
|
||||||
return;
|
return;
|
||||||
}
|
|
||||||
|
|
||||||
truncate_inode_pages(gfs2_glock2aspace(gl), 0);
|
truncate_inode_pages(gfs2_glock2aspace(gl), 0);
|
||||||
truncate_inode_pages(&inode->i_data, 0);
|
truncate_inode_pages(&inode->i_data, 0);
|
||||||
@ -902,7 +900,6 @@ fail_gunlock3:
|
|||||||
fail_gunlock2:
|
fail_gunlock2:
|
||||||
gfs2_glock_put(io_gl);
|
gfs2_glock_put(io_gl);
|
||||||
fail_dealloc_inode:
|
fail_dealloc_inode:
|
||||||
set_bit(GIF_ALLOC_FAILED, &ip->i_flags);
|
|
||||||
dealloc_error = 0;
|
dealloc_error = 0;
|
||||||
if (ip->i_eattr)
|
if (ip->i_eattr)
|
||||||
dealloc_error = gfs2_ea_dealloc(ip, xattr_initialized);
|
dealloc_error = gfs2_ea_dealloc(ip, xattr_initialized);
|
||||||
|
@ -443,11 +443,9 @@ void gfs2_journal_wipe(struct gfs2_inode *ip, u64 bstart, u32 blen)
|
|||||||
struct buffer_head *bh;
|
struct buffer_head *bh;
|
||||||
int ty;
|
int ty;
|
||||||
|
|
||||||
if (!ip->i_gl) {
|
/* This can only happen during incomplete inode creation. */
|
||||||
/* This can only happen during incomplete inode creation. */
|
if (!ip->i_gl)
|
||||||
BUG_ON(!test_bit(GIF_ALLOC_FAILED, &ip->i_flags));
|
|
||||||
return;
|
return;
|
||||||
}
|
|
||||||
|
|
||||||
gfs2_ail1_wipe(sdp, bstart, blen);
|
gfs2_ail1_wipe(sdp, bstart, blen);
|
||||||
while (blen) {
|
while (blen) {
|
||||||
|
@ -487,11 +487,9 @@ static void gfs2_dirty_inode(struct inode *inode, int flags)
|
|||||||
int need_endtrans = 0;
|
int need_endtrans = 0;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
if (unlikely(!ip->i_gl)) {
|
/* This can only happen during incomplete inode creation. */
|
||||||
/* This can only happen during incomplete inode creation. */
|
if (unlikely(!ip->i_gl))
|
||||||
BUG_ON(!test_bit(GIF_ALLOC_FAILED, &ip->i_flags));
|
|
||||||
return;
|
return;
|
||||||
}
|
|
||||||
|
|
||||||
if (gfs2_withdrawing_or_withdrawn(sdp))
|
if (gfs2_withdrawing_or_withdrawn(sdp))
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user