diff options
author | Haavard Skinnemoen <hskinnemoen@atmel.com> | 2007-05-09 05:35:33 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-09 15:30:57 -0400 |
commit | 880169dd2edc4297b7811a0542be9766ca6945bc (patch) | |
tree | 38f9ecb7507c37982291fa9f131682daf91c3c27 | |
parent | 5a87ede94595f58934000e26e8b13398e63868b5 (diff) |
fbdev: add support for AVR32
Provide framebuffer page protection flags and definitions of
fb_readl/fb_writel for AVR32.
Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | drivers/video/fbmem.c | 4 | ||||
-rw-r--r-- | include/linux/fb.h | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/drivers/video/fbmem.c b/drivers/video/fbmem.c index 08d4e11d9121..38c2e2558f5e 100644 --- a/drivers/video/fbmem.c +++ b/drivers/video/fbmem.c | |||
@@ -1236,6 +1236,10 @@ fb_mmap(struct file *file, struct vm_area_struct * vma) | |||
1236 | pgprot_val(vma->vm_page_prot) |= _PAGE_NO_CACHE; | 1236 | pgprot_val(vma->vm_page_prot) |= _PAGE_NO_CACHE; |
1237 | #elif defined(__arm__) || defined(__sh__) || defined(__m32r__) | 1237 | #elif defined(__arm__) || defined(__sh__) || defined(__m32r__) |
1238 | vma->vm_page_prot = pgprot_writecombine(vma->vm_page_prot); | 1238 | vma->vm_page_prot = pgprot_writecombine(vma->vm_page_prot); |
1239 | #elif defined(__avr32__) | ||
1240 | vma->vm_page_prot = __pgprot((pgprot_val(vma->vm_page_prot) | ||
1241 | & ~_PAGE_CACHABLE) | ||
1242 | | (_PAGE_BUFFER | _PAGE_DIRTY)); | ||
1239 | #elif defined(__ia64__) | 1243 | #elif defined(__ia64__) |
1240 | if (efi_range_is_wc(vma->vm_start, vma->vm_end - vma->vm_start)) | 1244 | if (efi_range_is_wc(vma->vm_start, vma->vm_end - vma->vm_start)) |
1241 | vma->vm_page_prot = pgprot_writecombine(vma->vm_page_prot); | 1245 | vma->vm_page_prot = pgprot_writecombine(vma->vm_page_prot); |
diff --git a/include/linux/fb.h b/include/linux/fb.h index dff7a728948c..c654d0e9ce33 100644 --- a/include/linux/fb.h +++ b/include/linux/fb.h | |||
@@ -868,7 +868,7 @@ struct fb_info { | |||
868 | #define fb_writeq sbus_writeq | 868 | #define fb_writeq sbus_writeq |
869 | #define fb_memset sbus_memset_io | 869 | #define fb_memset sbus_memset_io |
870 | 870 | ||
871 | #elif defined(__i386__) || defined(__alpha__) || defined(__x86_64__) || defined(__hppa__) || (defined(__sh__) && !defined(__SH5__)) || defined(__powerpc__) | 871 | #elif defined(__i386__) || defined(__alpha__) || defined(__x86_64__) || defined(__hppa__) || (defined(__sh__) && !defined(__SH5__)) || defined(__powerpc__) || defined(__avr32__) |
872 | 872 | ||
873 | #define fb_readb __raw_readb | 873 | #define fb_readb __raw_readb |
874 | #define fb_readw __raw_readw | 874 | #define fb_readw __raw_readw |