Skip to content

Commit

Permalink
x86: set strong uncacheable where UC is really desired
Browse files Browse the repository at this point in the history
Also use _PAGE_PWT for all the mappings which need uncache mapping.
Instead of existing PAT2 which is UC- (and can be overwritten by MTRRs),
we now use PAT3 which is strong uncacheable.

This makes it consistent with pgprot_noncached()

Signed-off-by: Suresh Siddha <suresh.b.siddha@intel.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
  • Loading branch information
Siddha, Suresh B authored and Ingo Molnar committed Jan 30, 2008
1 parent fbd3bfd commit 4138cc3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion arch/x86/mm/ioremap_32.c
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ EXPORT_SYMBOL(__ioremap);
void __iomem *ioremap_nocache (unsigned long phys_addr, unsigned long size)
{
unsigned long last_addr;
void __iomem *p = __ioremap(phys_addr, size, _PAGE_PCD);
void __iomem *p = __ioremap(phys_addr, size, _PAGE_PCD | _PAGE_PWT);
if (!p)
return p;

Expand Down
2 changes: 1 addition & 1 deletion arch/x86/mm/ioremap_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ EXPORT_SYMBOL(__ioremap);

void __iomem *ioremap_nocache (unsigned long phys_addr, unsigned long size)
{
return __ioremap(phys_addr, size, _PAGE_PCD);
return __ioremap(phys_addr, size, _PAGE_PCD | _PAGE_PWT);
}
EXPORT_SYMBOL(ioremap_nocache);

Expand Down

0 comments on commit 4138cc3

Please sign in to comment.