From b38dfae22e0b3382770d77bc8a7bcb7eabc6510c Mon Sep 17 00:00:00 2001 From: Randy Dunlap Date: Mon, 10 Apr 2006 22:54:22 -0700 Subject: [PATCH] --- yaml --- r: 25522 b: refs/heads/master c: 235963b2edc080b577000031b9ad75804dd83c88 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/Documentation/mtrr.txt | 23 +++++++++++++++++++++-- 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 5bb606f281fc..b15bc5081a29 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 8c37bea1a0506f45111c64bac4325173e066b22d +refs/heads/master: 235963b2edc080b577000031b9ad75804dd83c88 diff --git a/trunk/Documentation/mtrr.txt b/trunk/Documentation/mtrr.txt index b78af1c32996..c39ac395970e 100644 --- a/trunk/Documentation/mtrr.txt +++ b/trunk/Documentation/mtrr.txt @@ -138,19 +138,29 @@ Reading MTRRs from a C program using ioctl()'s: */ #include +#include #include #include #include #include #include #include -#define MTRR_NEED_STRINGS #include #define TRUE 1 #define FALSE 0 #define ERRSTRING strerror (errno) +static char *mtrr_strings[MTRR_NUM_TYPES] = +{ + "uncachable", /* 0 */ + "write-combining", /* 1 */ + "?", /* 2 */ + "?", /* 3 */ + "write-through", /* 4 */ + "write-protect", /* 5 */ + "write-back", /* 6 */ +}; int main () { @@ -232,13 +242,22 @@ Creating MTRRs from a C programme using ioctl()'s: #include #include #include -#define MTRR_NEED_STRINGS #include #define TRUE 1 #define FALSE 0 #define ERRSTRING strerror (errno) +static char *mtrr_strings[MTRR_NUM_TYPES] = +{ + "uncachable", /* 0 */ + "write-combining", /* 1 */ + "?", /* 2 */ + "?", /* 3 */ + "write-through", /* 4 */ + "write-protect", /* 5 */ + "write-back", /* 6 */ +}; int main (int argc, char **argv) {