Skip to content

Commit

Permalink
[PATCH] relayfs: add relayfs_remove_file()
Browse files Browse the repository at this point in the history
This patch adds and exports relayfs_remove_file(), for API symmetry (with
relayfs_create_file()).

Signed-off-by: Tom Zanussi <zanussi@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Tom Zanussi authored and Linus Torvalds committed Jan 9, 2006
1 parent 907f2c7 commit 7431733
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
12 changes: 12 additions & 0 deletions fs/relayfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,17 @@ int relayfs_remove(struct dentry *dentry)
return error;
}

/**
* relayfs_remove_file - remove a file from relay filesystem
* @dentry: directory dentry
*
* Returns 0 if successful, negative otherwise.
*/
int relayfs_remove_file(struct dentry *dentry)
{
return relayfs_remove(dentry);
}

/**
* relayfs_remove_dir - remove a directory in the relay filesystem
* @dentry: directory dentry
Expand Down Expand Up @@ -600,6 +611,7 @@ EXPORT_SYMBOL_GPL(relayfs_file_operations);
EXPORT_SYMBOL_GPL(relayfs_create_dir);
EXPORT_SYMBOL_GPL(relayfs_remove_dir);
EXPORT_SYMBOL_GPL(relayfs_create_file);
EXPORT_SYMBOL_GPL(relayfs_remove_file);

MODULE_AUTHOR("Tom Zanussi <zanussi@us.ibm.com> and Karim Yaghmour <karim@opersys.com>");
MODULE_DESCRIPTION("Relay Filesystem");
Expand Down
1 change: 1 addition & 0 deletions include/linux/relayfs_fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ extern struct dentry *relayfs_create_file(const char *name,
int mode,
struct file_operations *fops,
void *data);
extern int relayfs_remove_file(struct dentry *dentry);

/**
* relay_write - write data into the channel
Expand Down

0 comments on commit 7431733

Please sign in to comment.