Patchwork bios: mtrr: add uncached string for DEFAULT type

login
register
mail settings
Submitter Alex Hung
Date April 17, 2013, 9:52 a.m.
Message ID <1366192336-29064-1-git-send-email-alex.hung@canonical.com>
Download mbox | patch
Permalink /patch/237196/
State Accepted
Headers show

Comments

Alex Hung - April 17, 2013, 9:52 a.m.
In Section 11.11 of Intel® 64 and IA-32 Architectures Software Developer's
Manual Volume 3, it implies physical memory unconfigured in MTRR is uncached.

Signed-off-by: Alex Hung <alex.hung@canonical.com>
---
 src/bios/mtrr/mtrr.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Ivan Hu - April 18, 2013, 2:09 a.m.
On 04/17/2013 05:52 PM, Alex Hung wrote:
> In Section 11.11 of Intel® 64 and IA-32 Architectures Software Developer's
> Manual Volume 3, it implies physical memory unconfigured in MTRR is uncached.
>
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>   src/bios/mtrr/mtrr.c |    2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/bios/mtrr/mtrr.c b/src/bios/mtrr/mtrr.c
> index 0a83d58..284d153 100644
> --- a/src/bios/mtrr/mtrr.c
> +++ b/src/bios/mtrr/mtrr.c
> @@ -73,7 +73,7 @@ static char *cache_to_string(int type)
>   	if (type & WRITE_PROTECT)
>   		strcat(str," Write-Protect");
>   	if (type & DEFAULT)
> -		strcat(str," Default");
> +		strcat(str," Default (Most probably Uncached)");
>   	if (type & UNKNOWN)
>   		strcat(str," Unknown");
>   	return str;
>


Acked-by: Ivan Hu <ivan.hu@canonical.com>
Colin King - April 18, 2013, 7:17 a.m.
On 17/04/13 10:52, Alex Hung wrote:
> In Section 11.11 of Intel® 64 and IA-32 Architectures Software Developer's
> Manual Volume 3, it implies physical memory unconfigured in MTRR is uncached.
>
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>   src/bios/mtrr/mtrr.c |    2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/bios/mtrr/mtrr.c b/src/bios/mtrr/mtrr.c
> index 0a83d58..284d153 100644
> --- a/src/bios/mtrr/mtrr.c
> +++ b/src/bios/mtrr/mtrr.c
> @@ -73,7 +73,7 @@ static char *cache_to_string(int type)
>   	if (type & WRITE_PROTECT)
>   		strcat(str," Write-Protect");
>   	if (type & DEFAULT)
> -		strcat(str," Default");
> +		strcat(str," Default (Most probably Uncached)");
>   	if (type & UNKNOWN)
>   		strcat(str," Unknown");
>   	return str;
>
This clarifies the default setting as discussed in IRC yesterday.

Acked-by: Colin Ian King <colin.king@canonical.com>

Patch

diff --git a/src/bios/mtrr/mtrr.c b/src/bios/mtrr/mtrr.c
index 0a83d58..284d153 100644
--- a/src/bios/mtrr/mtrr.c
+++ b/src/bios/mtrr/mtrr.c
@@ -73,7 +73,7 @@  static char *cache_to_string(int type)
 	if (type & WRITE_PROTECT)
 		strcat(str," Write-Protect");
 	if (type & DEFAULT)
-		strcat(str," Default");
+		strcat(str," Default (Most probably Uncached)");
 	if (type & UNKNOWN)
 		strcat(str," Unknown");
 	return str;