summaryrefslogtreecommitdiffstats
path: root/fs/hostfs
diff options
context:
space:
mode:
authorTiwei Bie <tiwei.btw@antgroup.com>2024-10-11 06:04:38 +0200
committerJohannes Berg <johannes.berg@intel.com>2024-10-23 09:52:49 +0200
commitd26627b2c7b50c0b8a5ee3cafa7a3e3913c25a92 (patch)
tree3f9feec1993270a7f87b06499a331fefc5a25a13 /fs/hostfs
parentum: Do not propagate noreboot parameter to kernel (diff)
downloadlinux-d26627b2c7b50c0b8a5ee3cafa7a3e3913c25a92.tar.xz
linux-d26627b2c7b50c0b8a5ee3cafa7a3e3913c25a92.zip
hostfs: Do not propagate hostfs parameter to kernel
This parameter is UML specific and is unknown to kernel. It should not be propagated to kernel, otherwise it will be passed to user space as an environment option by kernel with a warning like: Unknown kernel command line parameters "hostfs=/foo", will be passed to user space. Signed-off-by: Tiwei Bie <tiwei.btw@antgroup.com> Link: https://patch.msgid.link/20241011040441.1586345-7-tiwei.btw@antgroup.com Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'fs/hostfs')
-rw-r--r--fs/hostfs/hostfs_kern.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/hostfs/hostfs_kern.c b/fs/hostfs/hostfs_kern.c
index 6d1cf2436ead..8d47c6b70c9f 100644
--- a/fs/hostfs/hostfs_kern.c
+++ b/fs/hostfs/hostfs_kern.c
@@ -57,6 +57,7 @@ static int __init hostfs_args(char *options, int *add)
{
char *ptr;
+ *add = 0;
ptr = strchr(options, ',');
if (ptr != NULL)
*ptr++ = '\0';