Skip to content

Commit 2930afe

Browse files
author
Al Viro
committed
export_operations->open(): constify path argument
for the method and its sole instance... Reviewed-by: Jan Kara <jack@suse.cz> Reviewed-by: Christian Brauner <brauner@kernel.org> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
1 parent 9c71fe0 commit 2930afe

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

fs/pidfs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -847,7 +847,7 @@ static int pidfs_export_permission(struct handle_to_path_ctx *ctx,
847847
return 0;
848848
}
849849

850-
static struct file *pidfs_export_open(struct path *path, unsigned int oflags)
850+
static struct file *pidfs_export_open(const struct path *path, unsigned int oflags)
851851
{
852852
/*
853853
* Clear O_LARGEFILE as open_by_handle_at() forces it and raise

include/linux/exportfs.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ struct export_operations {
270270
int (*commit_blocks)(struct inode *inode, struct iomap *iomaps,
271271
int nr_iomaps, struct iattr *iattr);
272272
int (*permission)(struct handle_to_path_ctx *ctx, unsigned int oflags);
273-
struct file * (*open)(struct path *path, unsigned int oflags);
273+
struct file * (*open)(const struct path *path, unsigned int oflags);
274274
#define EXPORT_OP_NOWCC (0x1) /* don't collect v3 wcc data */
275275
#define EXPORT_OP_NOSUBTREECHK (0x2) /* no subtree checking */
276276
#define EXPORT_OP_CLOSE_BEFORE_UNLINK (0x4) /* close files before unlink */

0 commit comments

Comments
 (0)