All of lore.kernel.org
 help / color / mirror / Atom feed
From: Deepak Saxena <dsaxena@plexity.net>
To: linux-kernel@vger.kernel.org
Cc: Andrew Morton <akpm@osdl.org>, greg@kroah.com
Subject: [PATCH 1/3] [Generic] Transition /proc/cpuinfo -> sysfs
Date: Wed, 11 Aug 2004 15:42:56 -0700	[thread overview]
Message-ID: <20040811224256.GA7095@plexity.net> (raw)
In-Reply-To: <20040811224117.GA6450@plexity.net>


- Add printk to cpuinfo_open reminding user to transition to sysfs
- Add arch_cpuinfo field to struct cpu

diff -Nru a/fs/proc/proc_misc.c b/fs/proc/proc_misc.c
--- a/fs/proc/proc_misc.c	Wed Aug 11 14:46:15 2004
+++ b/fs/proc/proc_misc.c	Wed Aug 11 14:46:15 2004
@@ -258,11 +258,18 @@
 	return proc_calc_metrics(page, start, off, count, eof, len);
 }
 
+#define	CPUINFO_REMOVAL_DATE "September 1st, 2005"
 extern struct seq_operations cpuinfo_op;
 static int cpuinfo_open(struct inode *inode, struct file *file)
 {
+	printk(KERN_WARNING "Using depecrated /proc/cpuinfo interface\n");
+	printk(KERN_WARNING "This interface will be deleted on %s\n", 
+			CPUINFO_REMOVAL_DATE);
+	printk(KERN_WARNING "Please use syfs interface instead\n");
+
 	return seq_open(file, &cpuinfo_op);
 }
+
 static struct file_operations proc_cpuinfo_operations = {
 	.open		= cpuinfo_open,
 	.read		= seq_read,
diff -Nru a/include/linux/cpu.h b/include/linux/cpu.h
--- a/include/linux/cpu.h	Wed Aug 11 14:46:15 2004
+++ b/include/linux/cpu.h	Wed Aug 11 14:46:15 2004
@@ -28,6 +28,7 @@
 struct cpu {
 	int node_id;		/* The node which contains the CPU */
 	int no_control;		/* Should the sysfs control file be created? */
+	void *arch_cpuinfo;	/* Per-cpu arch data */
 	struct sys_device sysdev;
 };
 

-- 
Deepak Saxena - dsaxena at plexity dot net - http://www.plexity.net/

"Unlike me, many of you have accepted the situation of your imprisonment and
 will die here like rotten cabbages." - Number 6

  reply	other threads:[~2004-08-11 22:43 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-08-11 22:41 [PATCH 0/3] Transition /proc/cpuinfo -> sysfs Deepak Saxena
2004-08-11 22:42 ` Deepak Saxena [this message]
2004-08-11 22:44 ` [PATCH 2/3] [i386] " Deepak Saxena
2004-08-11 22:47 ` [PATCH 3/3] [ARM] " Deepak Saxena
2004-08-11 22:47 ` [PATCH 0/3] " Deepak Saxena
2004-08-11 23:13 ` Dave Jones
2004-08-11 23:42   ` Deepak Saxena
2004-08-11 23:59     ` Dave Jones
2004-08-12  2:45       ` Deepak Saxena
2004-08-12 11:07         ` Dave Jones
2004-08-15  6:11       ` Andrew Morton
2004-08-15  6:33         ` Greg KH
2004-08-12  5:03 ` Lamont R. Peterson
2004-08-12 10:56   ` Dave Jones

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040811224256.GA7095@plexity.net \
    --to=dsaxena@plexity.net \
    --cc=akpm@osdl.org \
    --cc=greg@kroah.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.