Merge tag 'pull-fs_context' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs

Pull fs_context updates from Al Viro:
 "Change vfs_parse_fs_string() calling conventions

  Get rid of the length argument (almost all callers pass strlen() of
  the string argument there), add vfs_parse_fs_qstr() for the cases that
  do want separate length"

* tag 'pull-fs_context' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  do_nfs4_mount(): switch to vfs_parse_fs_string()
  change the calling conventions for vfs_parse_fs_string()
This commit is contained in:
Linus Torvalds
2025-10-03 10:51:44 -07:00
13 changed files with 60 additions and 74 deletions

View File

@@ -504,10 +504,18 @@ returned.
clear the pointer, but then becomes responsible for disposing of the
object.
* ::
int vfs_parse_fs_qstr(struct fs_context *fc, const char *key,
const struct qstr *value);
A wrapper around vfs_parse_fs_param() that copies the value string it is
passed.
* ::
int vfs_parse_fs_string(struct fs_context *fc, const char *key,
const char *value, size_t v_size);
const char *value);
A wrapper around vfs_parse_fs_param() that copies the value string it is
passed.

View File

@@ -1297,3 +1297,15 @@ Several functions are renamed:
- user_path_create -> start_creating_user_path
- user_path_locked_at -> start_removing_user_path_at
- done_path_create -> end_creating_path
---
**mandatory**
Calling conventions for vfs_parse_fs_string() have changed; it does *not*
take length anymore (value ? strlen(value) : 0 is used). If you want
a different length, use
vfs_parse_fs_qstr(fc, key, &QSTR_LEN(value, len))
instead.