Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 17225
b: refs/heads/master
c: c8ca063
h: refs/heads/master
i:
  17223: 04360eb
v: v3
  • Loading branch information
Arnd Bergmann authored and Paul Mackerras committed Jan 9, 2006
1 parent 0ca276d commit 5fd84f4
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 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: 762cf6dac2623473e83bb271f2bbe97d2355c64d
refs/heads/master: c8ca0633e5f2bceab7b4eba4475820fd7674dece
20 changes: 10 additions & 10 deletions trunk/arch/powerpc/platforms/cell/spufs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -162,10 +162,10 @@ static int spufs_rmdir(struct inode *root, struct dentry *dir_dentry)
{
struct dentry *dentry, *tmp;
struct spu_context *ctx;
int err;

/* remove all entries */
err = 0;
down(&root->i_sem);
down(&dir_dentry->d_inode->i_sem);
list_for_each_entry_safe(dentry, tmp, &dir_dentry->d_subdirs, d_child) {
spin_lock(&dcache_lock);
spin_lock(&dentry->d_lock);
Expand All @@ -181,16 +181,16 @@ static int spufs_rmdir(struct inode *root, struct dentry *dir_dentry)
spin_unlock(&dcache_lock);
}
}
shrink_dcache_parent(dir_dentry);
up(&dir_dentry->d_inode->i_sem);
up(&root->i_sem);

/* We have to give up the mm_struct */
ctx = SPUFS_I(dir_dentry->d_inode)->i_ctx;
spu_forget(ctx);

if (!err) {
shrink_dcache_parent(dir_dentry);
err = simple_rmdir(root, dir_dentry);
}
return err;
/* XXX Do we need to hold i_sem here ? */
return simple_rmdir(root, dir_dentry);
}

static int spufs_dir_close(struct inode *inode, struct file *file)
Expand All @@ -201,10 +201,10 @@ static int spufs_dir_close(struct inode *inode, struct file *file)

dentry = file->f_dentry;
dir = dentry->d_parent->d_inode;
down(&dir->i_sem);
ret = spufs_rmdir(dir, file->f_dentry);

ret = spufs_rmdir(dir, dentry);
WARN_ON(ret);
up(&dir->i_sem);

return dcache_dir_close(inode, file);
}

Expand Down

0 comments on commit 5fd84f4

Please sign in to comment.