diff options
author | Steven Whitehouse <swhiteho@redhat.com> | 2006-06-24 15:42:21 -0400 |
---|---|---|
committer | Steven Whitehouse <swhiteho@redhat.com> | 2006-06-24 15:42:21 -0400 |
commit | af18ddb8864b096e3ed4732e2d4b21c956dcfe3a (patch) | |
tree | 7077bfdc2d7425153f90350739cadf8b5b3cf8e3 | |
parent | a53311d4d9e1cde15aebc2048847ea19fb33ac3a (diff) |
[GFS2] Eliminate one instance of __GFP_NOFAIL
This removes one instance of GFP_NOFAIL from the glock callback
function. It also fixes a bug where a , was used at a line end
rather than ; causing unintended results.
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
-rw-r--r-- | fs/gfs2/glock.c | 8 | ||||
-rw-r--r-- | fs/gfs2/ops_inode.c | 6 |
2 files changed, 7 insertions, 7 deletions
diff --git a/fs/gfs2/glock.c b/fs/gfs2/glock.c index 35bac90878a5..dbeb4ad836bd 100644 --- a/fs/gfs2/glock.c +++ b/fs/gfs2/glock.c | |||
@@ -416,7 +416,7 @@ void gfs2_holder_uninit(struct gfs2_holder *gh) | |||
416 | * @gl: the glock | 416 | * @gl: the glock |
417 | * @state: the state we're requesting | 417 | * @state: the state we're requesting |
418 | * @flags: the modifier flags | 418 | * @flags: the modifier flags |
419 | * @gfp_flags: __GFP_NOFAIL | 419 | * @gfp_flags: |
420 | * | 420 | * |
421 | * Figure out how big an impact this function has. Either: | 421 | * Figure out how big an impact this function has. Either: |
422 | * 1) Replace it with a cache of structures hanging off the struct gfs2_sbd | 422 | * 1) Replace it with a cache of structures hanging off the struct gfs2_sbd |
@@ -720,6 +720,7 @@ static void gfs2_glmutex_unlock(struct gfs2_glock *gl) | |||
720 | * @gl: the glock | 720 | * @gl: the glock |
721 | * @state: the state the caller wants us to change to | 721 | * @state: the state the caller wants us to change to |
722 | * | 722 | * |
723 | * Note: This may fail sliently if we are out of memory. | ||
723 | */ | 724 | */ |
724 | 725 | ||
725 | static void handle_callback(struct gfs2_glock *gl, unsigned int state) | 726 | static void handle_callback(struct gfs2_glock *gl, unsigned int state) |
@@ -744,8 +745,9 @@ restart: | |||
744 | } else { | 745 | } else { |
745 | spin_unlock(&gl->gl_spin); | 746 | spin_unlock(&gl->gl_spin); |
746 | 747 | ||
747 | new_gh = gfs2_holder_get(gl, state, LM_FLAG_TRY, | 748 | new_gh = gfs2_holder_get(gl, state, LM_FLAG_TRY, GFP_KERNEL); |
748 | GFP_KERNEL | __GFP_NOFAIL), | 749 | if (!new_gh) |
750 | return; | ||
749 | set_bit(HIF_DEMOTE, &new_gh->gh_iflags); | 751 | set_bit(HIF_DEMOTE, &new_gh->gh_iflags); |
750 | set_bit(HIF_DEALLOC, &new_gh->gh_iflags); | 752 | set_bit(HIF_DEALLOC, &new_gh->gh_iflags); |
751 | 753 | ||
diff --git a/fs/gfs2/ops_inode.c b/fs/gfs2/ops_inode.c index 5d5ebbcba534..8895baafc640 100644 --- a/fs/gfs2/ops_inode.c +++ b/fs/gfs2/ops_inode.c | |||
@@ -962,10 +962,8 @@ static int setattr_chown(struct inode *inode, struct iattr *attr) | |||
962 | brelse(dibh); | 962 | brelse(dibh); |
963 | 963 | ||
964 | if (ouid != NO_QUOTA_CHANGE || ogid != NO_QUOTA_CHANGE) { | 964 | if (ouid != NO_QUOTA_CHANGE || ogid != NO_QUOTA_CHANGE) { |
965 | gfs2_quota_change(ip, -ip->i_di.di_blocks, | 965 | gfs2_quota_change(ip, -ip->i_di.di_blocks, ouid, ogid); |
966 | ouid, ogid); | 966 | gfs2_quota_change(ip, ip->i_di.di_blocks, nuid, ngid); |
967 | gfs2_quota_change(ip, ip->i_di.di_blocks, | ||
968 | nuid, ngid); | ||
969 | } | 967 | } |
970 | 968 | ||
971 | out_end_trans: | 969 | out_end_trans: |