diff options
author | c4llv07e <igor@c4llv07e.xyz> | 2025-05-06 17:50:27 +0300 |
---|---|---|
committer | c4llv07e <igor@c4llv07e.xyz> | 2025-05-06 17:50:27 +0300 |
commit | 352bea70e563ecfb2034f09faf03a43102c0dbf7 (patch) | |
tree | e3c91547930a77ab0e73da18f215a3ac4185e7a5 /etcfs.c | |
download | etcfs-352bea70e563ecfb2034f09faf03a43102c0dbf7.tar.gz etcfs-352bea70e563ecfb2034f09faf03a43102c0dbf7.tar.bz2 etcfs-352bea70e563ecfb2034f09faf03a43102c0dbf7.zip |
Init commit
Diffstat (limited to 'etcfs.c')
-rw-r--r-- | etcfs.c | 28 |
1 files changed, 28 insertions, 0 deletions
@@ -0,0 +1,28 @@ +#include <linux/module.h> +#include <linux/kernel.h> +#include <linux/fs.h> + +static struct file_system_type etc_fs_type = { + .name = "etcfs", + .f_flasgs = FS_USERNS_MOUNT, +}; + +static int __init etcfs_init(void) { + int err; + err = register_filesystem(etcfs); + if (err) { + return err; + } + return 0; +} + +static int __exit etcfs_exit(void) { + return 0; +} + +module_init(etcfs_init); +module_exit(etcfs_exit); + +MODULE_LICENSE("GPL"); +MODULE_AUTHOR("c4llv07e <igor@c4llv07e.xyz>"); +MODULE_DESCRIPTION("Read-only preconfigured etc filesystem"); |