All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eduardo Valentin <eduardo.valentin@nokia.com>
To: ext Kevin Hilman <khilman@deeprootsystems.com>,
	ext Tony Lindgren <tony@atomide.com>
Cc: "\\\"De-Schrijver Peter (Nokia-D/Helsinki)\\\""
	<Peter.De-Schrijver@nokia.com>,
	Linux-OMAP <linux-omap@vger.kernel.org>,
	Eduardo Valentin <eduardo.valentin@nokia.com>
Subject: [PATCH 3/4] mach-omap1: Add SoC info data for OMAP into /proc/cpuinfo1
Date: Mon, 26 Apr 2010 11:24:52 +0300	[thread overview]
Message-ID: <1272270293-18568-4-git-send-email-eduardo.valentin@nokia.com> (raw)
In-Reply-To: <1272270293-18568-1-git-send-email-eduardo.valentin@nokia.com>

From: Eduardo Valentin <eduardo.valentin@nokia.com>

Report OMAP data into system_soc_info. Now we get omap
information under /proc/cpuinfo.

Signed-off-by: Eduardo Valentin <eduardo.valentin@nokia.com>
---
 arch/arm/mach-omap1/id.c |   18 ++++++++++++------
 1 files changed, 12 insertions(+), 6 deletions(-)

diff --git a/arch/arm/mach-omap1/id.c b/arch/arm/mach-omap1/id.c
index a0e3560..9622e9f 100644
--- a/arch/arm/mach-omap1/id.c
+++ b/arch/arm/mach-omap1/id.c
@@ -194,11 +194,17 @@ void __init omap_check_revision(void)
 		printk(KERN_INFO "Unknown OMAP cpu type: 0x%02x\n", cpu_type);
 	}
 
-	printk(KERN_INFO "OMAP%04x", omap_revision >> 16);
-	if ((omap_revision >> 8) & 0xff)
-		printk(KERN_INFO "%x", (omap_revision >> 8) & 0xff);
-	printk(KERN_INFO " revision %i handled as %02xxx id: %08x%08x\n",
-	       die_rev, omap_revision & 0xff, system_serial_low,
-	       system_serial_high);
+	snprintf(system_soc_info, SYSTEM_SOC_INFO_SIZE, "OMAP%04x",
+							 omap_revision >> 16);
+	if ((omap_revision >> 8) & 0xff) {
+		int sz = strlen(system_soc_info);
+
+		snprintf(system_soc_info + sz, SYSTEM_SOC_INFO_SIZE - sz,
+				"%x", (omap_revision >> 8) & 0xff);
+	}
+	pr_info("%s revision %i handled as %02xxx id: %08x%08x\n",
+		system_soc_info, die_rev, omap_revision & 0xff,
+		system_serial_low, system_serial_high);
+
 }
 
-- 
1.7.0.4.361.g8b5fe.dirty


  parent reply	other threads:[~2010-04-26  8:25 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-26  8:24 [PATCH 0/4] Adding soc related info into /proc/cpuinfo Eduardo Valentin
2010-04-26  8:24 ` [PATCH 1/4] ARM: Introduce SoC Info " Eduardo Valentin
2010-04-26  8:24 ` [PATCH 2/4] mach-omap2: Add SoC info data for OMAP2,3,4 " Eduardo Valentin
2010-04-26  8:24 ` Eduardo Valentin [this message]
2010-04-26  8:24 ` [PATCH 4/4] OMAP3: PM: export chip IDCODE, Production ID and Die ID Eduardo Valentin
2010-04-26  8:33   ` Shilimkar, Santosh
2010-04-26  8:35     ` Shilimkar, Santosh
2010-04-26 18:28   ` Tony Lindgren
2010-04-27 10:13     ` Eduardo Valentin
2010-04-27 14:51       ` Tony Lindgren

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=1272270293-18568-4-git-send-email-eduardo.valentin@nokia.com \
    --to=eduardo.valentin@nokia.com \
    --cc=Peter.De-Schrijver@nokia.com \
    --cc=khilman@deeprootsystems.com \
    --cc=linux-omap@vger.kernel.org \
    --cc=tony@atomide.com \
    /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.