Skip to content

Commit

Permalink
mount options: fix capifs
Browse files Browse the repository at this point in the history
Add a .show_options super operation to capifs.

Use generic_show_options() and save the complete option string in
capifs_remount().

Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Acked-by: Karsten Keil <kkeil@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Miklos Szeredi authored and Linus Torvalds committed Feb 8, 2008
1 parent 552c3c6 commit e55e212
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions drivers/isdn/capi/capifs.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ static int capifs_remount(struct super_block *s, int *flags, char *data)
gid_t gid = 0;
umode_t mode = 0600;
char *this_char;
char *new_opt = kstrdup(data, GFP_KERNEL);

this_char = NULL;
while ((this_char = strsep(&data, ",")) != NULL) {
Expand All @@ -72,18 +73,24 @@ static int capifs_remount(struct super_block *s, int *flags, char *data)
return -EINVAL;
}
}

kfree(s->s_options);
s->s_options = new_opt;

config.setuid = setuid;
config.setgid = setgid;
config.uid = uid;
config.gid = gid;
config.mode = mode;

return 0;
}

static struct super_operations capifs_sops =
{
.statfs = simple_statfs,
.remount_fs = capifs_remount,
.show_options = generic_show_options,
};


Expand Down

0 comments on commit e55e212

Please sign in to comment.