summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOleg Nesterov <oleg@redhat.com>2026-08-30 17:33:43 +0200
committerJoel Granados <joel.granados@kernel.org>2026-09-15 12:46:09 +0200
commit7ebb35e03e47a360dfaca62d69d9791ffee29d9b (patch)
tree1edcf8ea1b4036391e7eec3670986218173a1703
parentf105dc5141f7edd7c4526614111bdc7ac5a60825 (diff)
downloadlinux-next-7ebb35e03e47a360dfaca62d69d9791ffee29d9b.tar.gz
linux-next-7ebb35e03e47a360dfaca62d69d9791ffee29d9b.zip
sysctl: remove redundant CONFIG_PROC_FS checks
Now that CONFIG_PROC_SYSCTL is gone, CONFIG_SYSCTL depends on CONFIG_PROC_FS directly in fs/proc/Kconfig, so the double guard defined(CONFIG_SYSCTL) && defined(CONFIG_PROC_FS) is redundant. Simplify to "#ifdef CONFIG_SYSCTL". Signed-off-by: Oleg Nesterov <oleg@redhat.com> Signed-off-by: Joel Granados <joel.granados@kernel.org>
-rw-r--r--drivers/parport/procfs.c6
-rw-r--r--fs/dcache.c2
-rw-r--r--fs/file_table.c2
3 files changed, 5 insertions, 5 deletions
diff --git a/drivers/parport/procfs.c b/drivers/parport/procfs.c
index 3880460e67f2..1bfafc2a5724 100644
--- a/drivers/parport/procfs.c
+++ b/drivers/parport/procfs.c
@@ -26,7 +26,7 @@
#include <linux/uaccess.h>
-#if defined(CONFIG_SYSCTL) && defined(CONFIG_PROC_FS)
+#ifdef CONFIG_SYSCTL
#define PARPORT_MIN_TIMESLICE_VALUE 1ul
#define PARPORT_MAX_TIMESLICE_VALUE ((unsigned long) HZ)
@@ -560,7 +560,7 @@ static void __exit parport_default_proc_unregister(void)
parport_bus_exit();
}
-#else /* no sysctl or no procfs*/
+#else /* CONFIG_SYSCTL */
int parport_proc_register(struct parport *pp)
{
@@ -591,7 +591,7 @@ static void __exit parport_default_proc_unregister (void)
{
parport_bus_exit();
}
-#endif
+#endif /* CONFIG_SYSCTL */
subsys_initcall(parport_default_proc_register)
module_exit(parport_default_proc_unregister)
diff --git a/fs/dcache.c b/fs/dcache.c
index 1b1a81f10da6..7ce421e9191f 100644
--- a/fs/dcache.c
+++ b/fs/dcache.c
@@ -144,7 +144,7 @@ static DEFINE_PER_CPU(long, nr_dentry_unused);
static DEFINE_PER_CPU(long, nr_dentry_negative);
static int dentry_negative_policy;
-#if defined(CONFIG_SYSCTL) && defined(CONFIG_PROC_FS)
+#ifdef CONFIG_SYSCTL
/* Statistics gathering. */
static struct dentry_stat_t dentry_stat = {
.age_limit = 45,
diff --git a/fs/file_table.c b/fs/file_table.c
index c68b8c0a4097..08ca3631b726 100644
--- a/fs/file_table.c
+++ b/fs/file_table.c
@@ -122,7 +122,7 @@ unsigned long get_max_files(void)
}
EXPORT_SYMBOL_GPL(get_max_files);
-#if defined(CONFIG_SYSCTL) && defined(CONFIG_PROC_FS)
+#ifdef CONFIG_SYSCTL
/*
* Handle nr_files sysctl