Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 125820
b: refs/heads/master
c: e4bc7b4
h: refs/heads/master
v: v3
  • Loading branch information
Jan Kara authored and Mark Fasheh committed Jan 5, 2009
1 parent bdc1cbe commit cd25a8f
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1497d3ad487b64eeea83ac203263802755438949
refs/heads/master: e4bc7b4b7ff783779b6928d55a9308910bf180a3
10 changes: 6 additions & 4 deletions trunk/fs/dquot.c
Original file line number Diff line number Diff line change
Expand Up @@ -1570,18 +1570,20 @@ static inline void reset_enable_flags(struct quota_info *dqopt, int type,
{
switch (type) {
case USRQUOTA:
dqopt->flags &= ~DQUOT_USR_ENABLED;
if (remount)
dqopt->flags |= DQUOT_USR_SUSPENDED;
else
else {
dqopt->flags &= ~DQUOT_USR_ENABLED;
dqopt->flags &= ~DQUOT_USR_SUSPENDED;
}
break;
case GRPQUOTA:
dqopt->flags &= ~DQUOT_GRP_ENABLED;
if (remount)
dqopt->flags |= DQUOT_GRP_SUSPENDED;
else
else {
dqopt->flags &= ~DQUOT_GRP_ENABLED;
dqopt->flags &= ~DQUOT_GRP_SUSPENDED;
}
break;
}
}
Expand Down
6 changes: 4 additions & 2 deletions trunk/include/linux/quotaops.h
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,10 @@ static inline struct mem_dqinfo *sb_dqinfo(struct super_block *sb, int type)
static inline int sb_has_quota_enabled(struct super_block *sb, int type)
{
if (type == USRQUOTA)
return sb_dqopt(sb)->flags & DQUOT_USR_ENABLED;
return sb_dqopt(sb)->flags & DQUOT_GRP_ENABLED;
return (sb_dqopt(sb)->flags & DQUOT_USR_ENABLED)
&& !(sb_dqopt(sb)->flags & DQUOT_USR_SUSPENDED);
return (sb_dqopt(sb)->flags & DQUOT_GRP_ENABLED)
&& !(sb_dqopt(sb)->flags & DQUOT_GROUP_SUSPENDED);
}

static inline int sb_any_quota_enabled(struct super_block *sb)
Expand Down

0 comments on commit cd25a8f

Please sign in to comment.