summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorJoel Granados <joel.granados@kernel.org>2025-10-14 14:04:16 +0300
committerJoel Granados <joel.granados@kernel.org>2025-11-27 17:45:37 +0300
commit54932988c4230925d2bf0023509ac2fee59a089a (patch)
treef6e18f496b1d26186117188374c08a8672e151b6 /include/linux
parent24a08eefddb33c7a259975e932c434b85f70d684 (diff)
downloadlinux-54932988c4230925d2bf0023509ac2fee59a089a.tar.xz
sysctl: Move jiffies converters to kernel/time/jiffies.c
Move integer jiffies converters (proc_dointvec{_,_ms_,_userhz_}jiffies and proc_dointvec_ms_jiffies_minmax) to kernel/time/jiffies.c. Error stubs for when CONFIG_PRCO_SYSCTL is not defined are not reproduced because all the jiffies converters go through proc_dointvec_conv which is already stubbed. This is part of the greater effort to move sysctl logic out of kernel/sysctl.c thereby reducing merge conflicts in kernel/sysctl.c. Signed-off-by: Joel Granados <joel.granados@kernel.org>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/jiffies.h10
-rw-r--r--include/linux/sysctl.h7
2 files changed, 10 insertions, 7 deletions
diff --git a/include/linux/jiffies.h b/include/linux/jiffies.h
index 0d1927da8055..72d589a8a0d6 100644
--- a/include/linux/jiffies.h
+++ b/include/linux/jiffies.h
@@ -611,4 +611,14 @@ extern unsigned long nsecs_to_jiffies(u64 n);
#define TIMESTAMP_SIZE 30
+struct ctl_table;
+int proc_dointvec_jiffies(const struct ctl_table *table, int dir, void *buffer,
+ size_t *lenp, loff_t *ppos);
+int proc_dointvec_ms_jiffies_minmax(const struct ctl_table *table, int dir,
+ void *buffer, size_t *lenp, loff_t *ppos);
+int proc_dointvec_userhz_jiffies(const struct ctl_table *table, int dir,
+ void *buffer, size_t *lenp, loff_t *ppos);
+int proc_dointvec_ms_jiffies(const struct ctl_table *table, int dir, void *buffer,
+ size_t *lenp, loff_t *ppos);
+
#endif
diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h
index fa78136617ad..db4020f6933b 100644
--- a/include/linux/sysctl.h
+++ b/include/linux/sysctl.h
@@ -192,13 +192,6 @@ int proc_douintvec_minmax(const struct ctl_table *table, int write, void *buffer
size_t *lenp, loff_t *ppos);
int proc_dou8vec_minmax(const struct ctl_table *table, int write, void *buffer,
size_t *lenp, loff_t *ppos);
-int proc_dointvec_jiffies(const struct ctl_table *, int, void *, size_t *, loff_t *);
-int proc_dointvec_ms_jiffies_minmax(const struct ctl_table *table, int write,
- void *buffer, size_t *lenp, loff_t *ppos);
-int proc_dointvec_userhz_jiffies(const struct ctl_table *, int, void *, size_t *,
- loff_t *);
-int proc_dointvec_ms_jiffies(const struct ctl_table *, int, void *, size_t *,
- loff_t *);
int proc_doulongvec_minmax(const struct ctl_table *, int, void *, size_t *, loff_t *);
int proc_doulongvec_ms_jiffies_minmax(const struct ctl_table *table, int, void *,
size_t *, loff_t *);