cpufreq: deprecate proc_sys_intf, and inform users of removal ~2005-01-01
PATCH 1/1 cpufreq: deprecate proc_sys_intf, and inform users of removal ~2005-01-01
The /proc/sys/cpu/ interface was deprecated already when cpufreq was merged into the kernel. With 2.7. not appearing soon, let's do the same what's suggested for devfs and others: inform users of it being deprecated.
Signed-off-by Dominik Brodowski <[email protected]>
drivers/cpufreq/cpufreq_userspace.c +13 -0
@@ -154,6 +154,9 @@#ifdef CONFIG_CPU_FREQ_24_API +#warning The /proc/sys/cpu/ and sysctl interface to cpufreq will be removed from the 2.6. kernel series soon after 2005-01-01 + +static unsigned int warning_print =0 ;/*********************** cpufreq_sysctl interface ********************/ static int
@@ -169,6 +172,11 @@return 0 ; } +if (!warning_print) { + warning_print++; +printk (KERN_INFO "Access to /proc/sys/cpu/ is deprecated and will be removed from (new) 2.6. kernels soon after 2005-01-01" ); + } +if (write) {unsigned int freq;
@@ -204,6 +212,11 @@if (!cpu_online (cpu))return -EINVAL ; +if (!warning_print) { + warning_print++; +printk (KERN_INFO "Access to /proc/sys/cpu/ is deprecated and will be removed from (new) 2.6. kernels soon after 2005-01-01" ); + } +if (oldval && oldlenp) {size_t oldlen;