summaryrefslogtreecommitdiff
path: root/fs/debugfs/inode.c
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2025-09-05 17:09:18 +0100
committerMark Brown <broonie@kernel.org>2025-09-05 17:09:18 +0100
commit92b9c2b7a88c07324d70ea877cfe2d90ac823dbf (patch)
treec5c6df6a87eb3df891ce33191b80fe3aefac5add /fs/debugfs/inode.c
parent9d35d068fb138160709e04e3ee97fe29a6f8615b (diff)
parentb497e1a1a2b10c4ddb28064fba229365ae03311a (diff)
regulator: pf530x: NXP PF530x regulator driver
Merge series from Woodrow Douglass <wdouglass@carnegierobotics.com>: I wrote this driver to read settings and state from the nxp pf530x regulator. Please consider it for inclusion, any criticism is welcome.
Diffstat (limited to 'fs/debugfs/inode.c')
-rw-r--r--fs/debugfs/inode.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/fs/debugfs/inode.c b/fs/debugfs/inode.c
index a0357b0cf362..c12d649df6a5 100644
--- a/fs/debugfs/inode.c
+++ b/fs/debugfs/inode.c
@@ -183,6 +183,9 @@ static int debugfs_reconfigure(struct fs_context *fc)
struct debugfs_fs_info *sb_opts = sb->s_fs_info;
struct debugfs_fs_info *new_opts = fc->s_fs_info;
+ if (!new_opts)
+ return 0;
+
sync_filesystem(sb);
/* structure copy of new mount options to sb */
@@ -282,10 +285,16 @@ static int debugfs_fill_super(struct super_block *sb, struct fs_context *fc)
static int debugfs_get_tree(struct fs_context *fc)
{
+ int err;
+
if (!(debugfs_allow & DEBUGFS_ALLOW_API))
return -EPERM;
- return get_tree_single(fc, debugfs_fill_super);
+ err = get_tree_single(fc, debugfs_fill_super);
+ if (err)
+ return err;
+
+ return debugfs_reconfigure(fc);
}
static void debugfs_free_fc(struct fs_context *fc)