mirror of
https://github.com/torvalds/linux.git
synced 2024-11-21 19:41:42 +00:00
NOMMU: Fix SYSV IPC SHM
Fix the SYSV IPC SHM to work with the changes applied by the new fault handler patches when CONFIG_MMU=n. Signed-off-by: David Howells <dhowells@redhat.com> Cc: Nick Piggin <nickpiggin@yahoo.com.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
6a302358d8
commit
2e92a3baee
@ -295,5 +295,10 @@ unsigned long ramfs_nommu_get_unmapped_area(struct file *file,
|
||||
*/
|
||||
int ramfs_nommu_mmap(struct file *file, struct vm_area_struct *vma)
|
||||
{
|
||||
return vma->vm_flags & VM_SHARED ? 0 : -ENOSYS;
|
||||
if (!(vma->vm_flags & VM_SHARED))
|
||||
return -ENOSYS;
|
||||
|
||||
file_accessed(file);
|
||||
vma->vm_ops = &generic_file_vm_ops;
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user