summaryrefslogtreecommitdiffstats
path: root/fs/fs.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/fs.c')
-rw-r--r--fs/fs.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/fs/fs.c b/fs/fs.c
index 1901c94ad1..9a5887f580 100644
--- a/fs/fs.c
+++ b/fs/fs.c
@@ -328,6 +328,20 @@ int automount_add(const char *path, const char *cmd)
}
EXPORT_SYMBOL(automount_add);
+void cdev_create_default_automount(struct cdev *cdev)
+{
+ char *path, *cmd;
+
+ path = basprintf("/mnt/%s", cdev->name);
+ cmd = basprintf("mount %s", cdev->name);
+
+ make_directory(path);
+ automount_add(path, cmd);
+
+ free(cmd);
+ free(path);
+}
+
void automount_print(void)
{
struct automount *am;