[Devel] [PATCH rh7] simfs: drop it as well as VZ_QUOTA
Konstantin Khorenko
khorenko at virtuozzo.com
Thu Jun 25 04:18:49 PDT 2015
This reverts code added by following commits:
18382da simfs: add stub module
3e035f9 simfs: dumb stub module
4a6ae8b SIMFS: replace with bindmount
7dc8c56 SIMFS: port to 3.6
74a6e1f MS/SIMFS: export statfs_by_dentry
* simfs without quota is just a bindmount, so no need to have at all
* OpenVZ service required "simfs" module, but this is not true
for Virtuozzo 7
* right now Virtuozzo 7 vzctl is unable to create Container on simfs
* vzctl is planned to be taught to be able to create Containers
using bindmounts instead of simfs
https://jira.sw.ru/browse/PSBM-34494
=> let's drop SIMFS and leftovers of VZ_QUOTA code
https://jira.sw.ru/browse/PSBM-20810
Signed-off-by: Konstantin Khorenko <khorenko at virtuozzo.com>
---
config.OpenVZ | 4 ++--
config.OpenVZ.debug | 4 ++--
fs/Kconfig | 4 ----
fs/Makefile | 2 --
fs/namespace.c | 5 -----
fs/quota/Kconfig | 12 ------------
fs/simfs.c | 36 ------------------------------------
fs/statfs.c | 3 +--
include/linux/fs.h | 2 --
include/linux/sched.h | 4 ----
10 files changed, 5 insertions(+), 71 deletions(-)
delete mode 100644 fs/simfs.c
diff --git a/config.OpenVZ b/config.OpenVZ
index 7850c4b..1691fd3 100644
--- a/config.OpenVZ
+++ b/config.OpenVZ
@@ -5264,6 +5264,8 @@ CONFIG_LEGACY_PTY_COUNT=256
CONFIG_CHECKPOINT_RESTORE=y
+CONFIG_QUOTA_COMPAT=y
+
#
# OpenVZ
#
@@ -5281,8 +5283,6 @@ CONFIG_VTTYS=y
CONFIG_VZ_FAIRSCHED=y
CONFIG_BLK_DEV_PLOOP=m
-CONFIG_VZ_QUOTA=m
-CONFIG_SIM_FS=m
CONFIG_MPILIB_EXTRA=y
diff --git a/config.OpenVZ.debug b/config.OpenVZ.debug
index 28fe885..c3739ac 100644
--- a/config.OpenVZ.debug
+++ b/config.OpenVZ.debug
@@ -5375,6 +5375,8 @@ CONFIG_LEGACY_PTY_COUNT=256
CONFIG_CHECKPOINT_RESTORE=y
+CONFIG_QUOTA_COMPAT=y
+
#
# OpenVZ
#
@@ -5392,8 +5394,6 @@ CONFIG_VTTYS=y
CONFIG_VZ_FAIRSCHED=y
CONFIG_BLK_DEV_PLOOP=m
-CONFIG_VZ_QUOTA=m
-CONFIG_SIM_FS=m
CONFIG_MPILIB_EXTRA=y
diff --git a/fs/Kconfig b/fs/Kconfig
index eaf7c12..c229f82 100644
--- a/fs/Kconfig
+++ b/fs/Kconfig
@@ -68,10 +68,6 @@ source "fs/quota/Kconfig"
source "fs/autofs4/Kconfig"
source "fs/fuse/Kconfig"
-config SIM_FS
- tristate "simfs stub modules"
- default m
-
config GENERIC_ACL
bool
select FS_POSIX_ACL
diff --git a/fs/Makefile b/fs/Makefile
index bcc9fed..4fe6df3 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -52,8 +52,6 @@ obj-$(CONFIG_FHANDLE) += fhandle.o
obj-y += quota/
-obj-$(CONFIG_SIM_FS) += simfs.o
-
obj-$(CONFIG_PROC_FS) += proc/
obj-$(CONFIG_SYSFS) += sysfs/
obj-$(CONFIG_CONFIGFS_FS) += configfs/
diff --git a/fs/namespace.c b/fs/namespace.c
index 154746c..b9dfd0c 100644
--- a/fs/namespace.c
+++ b/fs/namespace.c
@@ -2432,11 +2432,6 @@ long do_mount(const char *dev_name, const char *dir_name,
if (retval)
return retval;
- if (data_page && type_page && !strcmp(type_page, "simfs")) {
- flags |= MS_BIND;
- dev_name = data_page;
- }
-
retval = security_sb_mount(dev_name, &path,
type_page, flags, data_page);
if (!retval && !may_mount())
diff --git a/fs/quota/Kconfig b/fs/quota/Kconfig
index fc463e1..09cdf0b 100644
--- a/fs/quota/Kconfig
+++ b/fs/quota/Kconfig
@@ -73,18 +73,6 @@ config QFMT_V2
also supports 64-bit inode and block quota limits. If you need this
functionality say Y here.
-config VZ_QUOTA
- tristate "Virtuozzo Disk Quota support"
- select QUOTA
- select QUOTA_COMPAT
- select VZ_DEV
- default m
- help
- Virtuozzo Disk Quota imposes disk quota on directories with their
- files and subdirectories in total. Such disk quota is used to
- account and limit disk usage by Virtuozzo VPS, but also may be used
- separately.
-
config QUOTACTL
bool
default n
diff --git a/fs/simfs.c b/fs/simfs.c
deleted file mode 100644
index 5c87ce6..0000000
--- a/fs/simfs.c
+++ /dev/null
@@ -1,36 +0,0 @@
-#include <linux/fs.h>
-#include <linux/module.h>
-
-static struct dentry * sim_fs_mount(struct file_system_type *type, int flags,
- const char *dev_name, void *data)
-{
- return ERR_PTR(-ENODEV);
-}
-
-static struct file_system_type sim_fs_type = {
- .owner = THIS_MODULE,
- .name = "simfs",
- .mount = sim_fs_mount,
-};
-
-static int __init init_simfs(void)
-{
- int err;
-
- err = register_filesystem(&sim_fs_type);
- if (err)
- return err;
-
- return 0;
-}
-
-static void __exit exit_simfs(void)
-{
- unregister_filesystem(&sim_fs_type);
-}
-
-MODULE_DESCRIPTION("simfs stub");
-MODULE_LICENSE("GPL v2");
-
-module_init(init_simfs);
-module_exit(exit_simfs);
diff --git a/fs/statfs.c b/fs/statfs.c
index 3490d70..3bdc8cb 100644
--- a/fs/statfs.c
+++ b/fs/statfs.c
@@ -61,7 +61,7 @@ static int statfs_by_sb(struct super_block *sb, struct dentry *dentry, struct ks
return retval;
}
-int statfs_by_dentry(struct dentry *dentry, struct kstatfs *buf)
+static int statfs_by_dentry(struct dentry *dentry, struct kstatfs *buf)
{
int retval;
@@ -70,7 +70,6 @@ int statfs_by_dentry(struct dentry *dentry, struct kstatfs *buf)
retval = statfs_by_sb(dentry->d_sb, dentry, buf);
return retval;
}
-EXPORT_SYMBOL(statfs_by_dentry);
int vfs_statfs(struct path *path, struct kstatfs *buf)
{
diff --git a/include/linux/fs.h b/include/linux/fs.h
index fdade5c..8f3d827 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -1973,7 +1973,6 @@ struct file_system_type {
#define FS_USERNS_MOUNT 8 /* Can be mounted by userns root */
#define FS_USERNS_DEV_MOUNT 16 /* A userns mount does not imply MNT_NODEV */
#define FS_VIRTUALIZED 64 /* Can mount this fstype inside ve */
-#define FS_MANGLE_PROC 128 /* hide some /proc/mounts info inside VE */
#define FS_RENAME_DOES_D_MOVE 32768 /* FS will handle d_move() during rename() internally. */
/*
* f_op->mmap must be called with vma=NULL before taking mmap_sem;
@@ -2050,7 +2049,6 @@ extern void drop_collected_mounts(struct vfsmount *);
extern int iterate_mounts(int (*)(struct vfsmount *, void *), void *,
struct vfsmount *);
extern int vfs_statfs(struct path *, struct kstatfs *);
-extern int statfs_by_dentry(struct dentry *, struct kstatfs *);
extern int user_statfs(const char __user *, struct kstatfs *);
extern int fd_statfs(int, struct kstatfs *);
extern int vfs_ustat(dev_t, struct kstatfs *);
diff --git a/include/linux/sched.h b/include/linux/sched.h
index f4a5e3d..6980dae 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -1502,10 +1502,6 @@ struct task_struct {
#ifdef CONFIG_BEANCOUNTERS
struct task_beancounter task_bc;
#endif
-#if defined(CONFIG_VZ_QUOTA) || defined(CONFIG_VZ_QUOTA_MODULE)
- unsigned long magic;
- struct inode *ino;
-#endif
#ifdef CONFIG_VE
struct ve_struct *task_ve;
#endif
--
1.8.3.1
More information about the Devel
mailing list