Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 79565
b: refs/heads/master
c: fccca7f
h: refs/heads/master
i:
  79563: 739f730
v: v3
  • Loading branch information
Trond Myklebust authored and Trond Myklebust committed Jan 30, 2008
1 parent a104d55 commit 56a84fb
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 15 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: 149a051f82d2b3860fe32fa182dbc83a66274894
refs/heads/master: fccca7fc6aab4e6b519e2d606ef34632e4f50e33
10 changes: 3 additions & 7 deletions trunk/block/as-iosched.c
Original file line number Diff line number Diff line change
Expand Up @@ -1275,13 +1275,9 @@ static void as_merged_requests(struct request_queue *q, struct request *req,
* Don't copy here but swap, because when anext is
* removed below, it must contain the unused context
*/
if (rioc != nioc) {
double_spin_lock(&rioc->lock, &nioc->lock,
rioc < nioc);
swap_io_context(&rioc, &nioc);
double_spin_unlock(&rioc->lock, &nioc->lock,
rioc < nioc);
}
double_spin_lock(&rioc->lock, &nioc->lock, rioc < nioc);
swap_io_context(&rioc, &nioc);
double_spin_unlock(&rioc->lock, &nioc->lock, rioc < nioc);
}
}

Expand Down
11 changes: 5 additions & 6 deletions trunk/fs/nfs/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -537,12 +537,6 @@ static int nfs_readdir(struct file *filp, void *dirent, filldir_t filldir)

lock_kernel();

res = nfs_revalidate_mapping_nolock(inode, filp->f_mapping);
if (res < 0) {
unlock_kernel();
return res;
}

/*
* filp->f_pos points to the dirent entry number.
* *desc->dir_cookie has the cookie for the next entry. We have
Expand All @@ -564,6 +558,10 @@ static int nfs_readdir(struct file *filp, void *dirent, filldir_t filldir)
desc->entry = &my_entry;

nfs_block_sillyrename(dentry);
res = nfs_revalidate_mapping_nolock(inode, filp->f_mapping);
if (res < 0)
goto out;

while(!desc->entry->eof) {
res = readdir_search_pagecache(desc);

Expand Down Expand Up @@ -594,6 +592,7 @@ static int nfs_readdir(struct file *filp, void *dirent, filldir_t filldir)
break;
}
}
out:
nfs_unblock_sillyrename(dentry);
unlock_kernel();
if (res > 0)
Expand Down
2 changes: 1 addition & 1 deletion trunk/fs/nfs/unlink.c
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ static int nfs_do_call_unlink(struct dentry *parent, struct inode *dir, struct n
spin_lock(&alias->d_lock);
if (!(alias->d_flags & DCACHE_NFSFS_RENAMED)) {
alias->d_fsdata = data;
alias->d_flags ^= DCACHE_NFSFS_RENAMED;
alias->d_flags |= DCACHE_NFSFS_RENAMED;
ret = 1;
}
spin_unlock(&alias->d_lock);
Expand Down

0 comments on commit 56a84fb

Please sign in to comment.