aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/uio
diff options
context:
space:
mode:
authorJean-Samuel Chenard <jsamch@gmail.com>2008-03-14 06:28:36 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2008-03-25 01:33:49 -0400
commitc9698d6b1a90929e427a165bd8283f803f57d9bd (patch)
treed73c313d4fb05014ce5cf593c97d0ee44cdc5cd3 /drivers/uio
parent7c12c92fba4bd985ed6d909e5537468b268dcaa4 (diff)
UIO: add pgprot_noncached() to UIO mmap code
Mapping of physical memory in UIO needs pgprot_noncached() to ensure that IO memory is not cached. Without pgprot_noncached(), it (accidentally) works on x86 and arm, but fails on PPC. Signed-off-by: Jean-Samuel Chenard <jsamch@gmail.com> Signed-off-by: Hans J Koch <hjk@linutronix.de> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/uio')
-rw-r--r--drivers/uio/uio.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/uio/uio.c b/drivers/uio/uio.c
index e8a01f264540..11759080ca54 100644
--- a/drivers/uio/uio.c
+++ b/drivers/uio/uio.c
@@ -470,6 +470,8 @@ static int uio_mmap_physical(struct vm_area_struct *vma)
470 470
471 vma->vm_flags |= VM_IO | VM_RESERVED; 471 vma->vm_flags |= VM_IO | VM_RESERVED;
472 472
473 vma->vm_page_prot = pgprot_noncached(vma->vm_page_prot);
474
473 return remap_pfn_range(vma, 475 return remap_pfn_range(vma,
474 vma->vm_start, 476 vma->vm_start,
475 idev->info->mem[mi].addr >> PAGE_SHIFT, 477 idev->info->mem[mi].addr >> PAGE_SHIFT,