aboutsummaryrefslogtreecommitdiffstats
path: root/arch/xtensa
diff options
context:
space:
mode:
authorChristoph Lameter <clameter@sgi.com>2006-06-25 08:46:47 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2006-06-25 13:00:55 -0400
commit68402ddc677005ed1b1359bbc1f279548cfc0928 (patch)
tree83da62a2b55e2ea7e0c46ed79c0d6498d36e1942 /arch/xtensa
parent9f1a3cfcffaed2fbb3206179295c79ca8289f5c3 (diff)
[PATCH] mm: remove VM_LOCKED before remap_pfn_range and drop VM_SHM
Remove VM_LOCKED before remap_pfn range from device drivers and get rid of VM_SHM. remap_pfn_range() already sets VM_IO. There is no need to set VM_SHM since it does nothing. VM_LOCKED is of no use since the remap_pfn_range does not place pages on the LRU. The pages are therefore never subject to swap anyways. Remove all the vm_flags settings before calling remap_pfn_range. After removing all the vm_flag settings no use of VM_SHM is left. Drop it. Signed-off-by: Christoph Lameter <clameter@sgi.com> Acked-by: Hugh Dickins <hugh@veritas.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/xtensa')
-rw-r--r--arch/xtensa/kernel/pci.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/arch/xtensa/kernel/pci.c b/arch/xtensa/kernel/pci.c
index de19501aa809..c6f471b9eaa0 100644
--- a/arch/xtensa/kernel/pci.c
+++ b/arch/xtensa/kernel/pci.c
@@ -350,17 +350,6 @@ __pci_mmap_make_offset(struct pci_dev *dev, struct vm_area_struct *vma,
350} 350}
351 351
352/* 352/*
353 * Set vm_flags of VMA, as appropriate for this architecture, for a pci device
354 * mapping.
355 */
356static __inline__ void
357__pci_mmap_set_flags(struct pci_dev *dev, struct vm_area_struct *vma,
358 enum pci_mmap_state mmap_state)
359{
360 vma->vm_flags |= VM_SHM | VM_LOCKED | VM_IO;
361}
362
363/*
364 * Set vm_page_prot of VMA, as appropriate for this architecture, for a pci 353 * Set vm_page_prot of VMA, as appropriate for this architecture, for a pci
365 * device mapping. 354 * device mapping.
366 */ 355 */
@@ -399,7 +388,6 @@ int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma,
399 if (ret < 0) 388 if (ret < 0)
400 return ret; 389 return ret;
401 390
402 __pci_mmap_set_flags(dev, vma, mmap_state);
403 __pci_mmap_set_pgprot(dev, vma, mmap_state, write_combine); 391 __pci_mmap_set_pgprot(dev, vma, mmap_state, write_combine);
404 392
405 ret = io_remap_pfn_range(vma, vma->vm_start, vma->vm_pgoff, 393 ret = io_remap_pfn_range(vma, vma->vm_start, vma->vm_pgoff,