From: Christian Hildner <christian.hildner@hob.de>
To: linux-ia64@vger.kernel.org
Subject: [Linux-ia64] [PATCH] fix /proc/.../vm_info
Date: Thu, 12 Dec 2002 13:49:10 +0000 [thread overview]
Message-ID: <marc-linux-ia64-105590709805552@msgid-missing> (raw)
[-- Attachment #1: Type: text/plain, Size: 182 bytes --]
Hi,
in vm_info the information about the supported memory attributes is
wrong. The patch is based on 2.4.18, but it should also work for 2.4.20
and 2.5.x. Please apply.
Christian
[-- Attachment #2: palinfo.c_patch --]
[-- Type: text/plain, Size: 1378 bytes --]
--- palinfo.c_orig Tue Mar 19 11:22:28 2002
+++ palinfo.c Thu Dec 12 14:33:51 2002
@@ -113,14 +113,14 @@
* bit 7 - 111 - NatPage
*/
static const char *mem_attrib[]={
- "Write Back (WB)", /* 000 */
- "Uncacheable (UC)", /* 001 */
- "Reserved", /* 010 */
- "Reserved", /* 011 */
- "Uncacheable (UC)", /* 100 */
- "Uncacheable Exported (UCE)", /* 101 */
- "Write Coalescing (WC)", /* 110 */
- "NaTPage" /* 111 */
+ "Write Back (WB) ma=000", /* 000 */
+ "Uncacheable (UC) ma=001", /* 001 */
+ "Reserved ma=010", /* 010 */
+ "Reserved ma=011", /* 011 */
+ "Uncacheable (UC) ma=100", /* 100 */
+ "Uncacheable Exported (UCE) ma=101", /* 101 */
+ "Write Coalescing (WC) ma=110", /* 110 */
+ "NaTPage ma=111" /* 111 */
};
/*
@@ -339,7 +339,15 @@
if (ia64_pal_mem_attrib(&attrib) != 0) return 0;
- p += sprintf(p, "Supported memory attributes : %s\n", mem_attrib[attrib&0x7]);
+ p += sprintf(p, "Supported memory attributes : ");
+ j = 0; // first line
+ for (i=0; i < 8; i++) {
+ if (attrib & (1 << i)) {
+ if (j) p += sprintf(p, " ");
+ p += sprintf(p, "%s\n", mem_attrib[i]);
+ j = 1;
+ }
+ }
if ((status=ia64_pal_vm_page_size(&tr_pages, &vw_pages)) !=0) {
printk("ia64_pal_vm_page_size=%ld\n", status);
@@ -971,3 +979,7 @@
module_init(palinfo_init);
module_exit(palinfo_exit);
+
+
+
+
next reply other threads:[~2002-12-12 13:49 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-12-12 13:49 Christian Hildner [this message]
2002-12-12 19:56 ` [Linux-ia64] [PATCH] fix /proc/.../vm_info David Mosberger
2002-12-13 7:45 ` Christian Hildner
2002-12-13 22:09 ` David Mosberger
2002-12-13 23:40 ` David Mosberger
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=marc-linux-ia64-105590709805552@msgid-missing \
--to=christian.hildner@hob.de \
--cc=linux-ia64@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox