vserver 1.9.3
[linux-2.6.git] / drivers / cpufreq / proc_intf.c
index a0eaf6f..6739778 100644 (file)
 #include <linux/proc_fs.h>
 #include <asm/uaccess.h>
 
+#warning This module will be removed from the 2.6. kernel series soon after 2005-01-01
 
 #define CPUFREQ_ALL_CPUS               ((NR_CPUS))
 
+static unsigned int warning_print = 0;
+
 /**
  * cpufreq_parse_policy - parse a policy string
  * @input_string: the string to parse.
@@ -110,6 +113,13 @@ static int cpufreq_proc_read (
        if (off != 0)
                goto end;
 
+       if (!warning_print) {
+               warning_print++;
+               printk(KERN_INFO "Access to /proc/cpufreq is deprecated and "
+                       "will be removed from (new) 2.6. kernels soon "
+                       "after 2005-01-01\n");
+       }
+
        p += sprintf(p, "          minimum CPU frequency  -  maximum CPU frequency  -  policy\n");
        for (i=0;i<NR_CPUS;i++) {
                if (!cpu_online(i))
@@ -179,6 +189,13 @@ static int cpufreq_proc_write (
        
        if (copy_from_user(proc_string, buffer, count))
                return -EFAULT;
+
+       if (!warning_print) {
+               warning_print++;
+               printk(KERN_INFO "Access to /proc/cpufreq is deprecated and "
+                       "will be removed from (new) 2.6. kernels soon "
+                       "after 2005-01-01\n");
+       }
        
        proc_string[count] = '\0';