Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 229039
b: refs/heads/master
c: 1a427ab
h: refs/heads/master
i:
  229037: 52d604b
  229035: a3ff194
  229031: 8fc161b
  229023: 35c2425
v: v3
  • Loading branch information
Dave Chinner authored and Dave Chinner committed Dec 16, 2010
1 parent dd8f120 commit 0954967
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 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: 1a3e8f3da09c7082d25b512a0ffe569391e4c09a
refs/heads/master: 1a427ab0c1b205d1bda8da0b77ea9d295ac23c57
8 changes: 4 additions & 4 deletions trunk/fs/xfs/linux-2.6/xfs_sync.c
Original file line number Diff line number Diff line change
Expand Up @@ -620,12 +620,12 @@ xfs_inode_set_reclaim_tag(
struct xfs_perag *pag;

pag = xfs_perag_get(mp, XFS_INO_TO_AGNO(mp, ip->i_ino));
write_lock(&pag->pag_ici_lock);
spin_lock(&pag->pag_ici_lock);
spin_lock(&ip->i_flags_lock);
__xfs_inode_set_reclaim_tag(pag, ip);
__xfs_iflags_set(ip, XFS_IRECLAIMABLE);
spin_unlock(&ip->i_flags_lock);
write_unlock(&pag->pag_ici_lock);
spin_unlock(&pag->pag_ici_lock);
xfs_perag_put(pag);
}

Expand Down Expand Up @@ -833,12 +833,12 @@ xfs_reclaim_inode(
* added to the tree assert that it's been there before to catch
* problems with the inode life time early on.
*/
write_lock(&pag->pag_ici_lock);
spin_lock(&pag->pag_ici_lock);
if (!radix_tree_delete(&pag->pag_ici_root,
XFS_INO_TO_AGINO(ip->i_mount, ip->i_ino)))
ASSERT(0);
__xfs_inode_clear_reclaim(pag, ip);
write_unlock(&pag->pag_ici_lock);
spin_unlock(&pag->pag_ici_lock);

/*
* Here we do an (almost) spurious inode lock in order to coordinate
Expand Down
2 changes: 1 addition & 1 deletion trunk/fs/xfs/xfs_ag.h
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ typedef struct xfs_perag {

atomic_t pagf_fstrms; /* # of filestreams active in this AG */

rwlock_t pag_ici_lock; /* incore inode lock */
spinlock_t pag_ici_lock; /* incore inode cache lock */
struct radix_tree_root pag_ici_root; /* incore inode cache root */
int pag_ici_reclaimable; /* reclaimable inodes */
struct mutex pag_ici_reclaim_lock; /* serialisation point */
Expand Down
10 changes: 5 additions & 5 deletions trunk/fs/xfs/xfs_iget.c
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ xfs_iget_cache_hit(
goto out_error;
}

write_lock(&pag->pag_ici_lock);
spin_lock(&pag->pag_ici_lock);
spin_lock(&ip->i_flags_lock);
ip->i_flags &= ~(XFS_IRECLAIMABLE | XFS_IRECLAIM);
ip->i_flags |= XFS_INEW;
Expand All @@ -273,7 +273,7 @@ xfs_iget_cache_hit(
&xfs_iolock_active, "xfs_iolock_active");

spin_unlock(&ip->i_flags_lock);
write_unlock(&pag->pag_ici_lock);
spin_unlock(&pag->pag_ici_lock);
} else {
/* If the VFS inode is being torn down, pause and try again. */
if (!igrab(inode)) {
Expand Down Expand Up @@ -351,7 +351,7 @@ xfs_iget_cache_miss(
BUG();
}

write_lock(&pag->pag_ici_lock);
spin_lock(&pag->pag_ici_lock);

/* insert the new inode */
error = radix_tree_insert(&pag->pag_ici_root, agino, ip);
Expand All @@ -366,14 +366,14 @@ xfs_iget_cache_miss(
ip->i_udquot = ip->i_gdquot = NULL;
xfs_iflags_set(ip, XFS_INEW);

write_unlock(&pag->pag_ici_lock);
spin_unlock(&pag->pag_ici_lock);
radix_tree_preload_end();

*ipp = ip;
return 0;

out_preload_end:
write_unlock(&pag->pag_ici_lock);
spin_unlock(&pag->pag_ici_lock);
radix_tree_preload_end();
if (lock_flags)
xfs_iunlock(ip, lock_flags);
Expand Down
2 changes: 1 addition & 1 deletion trunk/fs/xfs/xfs_mount.c
Original file line number Diff line number Diff line change
Expand Up @@ -472,7 +472,7 @@ xfs_initialize_perag(
goto out_unwind;
pag->pag_agno = index;
pag->pag_mount = mp;
rwlock_init(&pag->pag_ici_lock);
spin_lock_init(&pag->pag_ici_lock);
mutex_init(&pag->pag_ici_reclaim_lock);
INIT_RADIX_TREE(&pag->pag_ici_root, GFP_ATOMIC);
spin_lock_init(&pag->pag_buf_lock);
Expand Down

0 comments on commit 0954967

Please sign in to comment.