|
@@ -276,15 +276,14 @@ static long madvise_willneed(struct vm_area_struct *vma,
|
|
|
{
|
|
|
struct file *file = vma->vm_file;
|
|
|
|
|
|
+ *prev = vma;
|
|
|
#ifdef CONFIG_SWAP
|
|
|
if (!file) {
|
|
|
- *prev = vma;
|
|
|
force_swapin_readahead(vma, start, end);
|
|
|
return 0;
|
|
|
}
|
|
|
|
|
|
if (shmem_mapping(file->f_mapping)) {
|
|
|
- *prev = vma;
|
|
|
force_shm_swapin_readahead(vma, start, end,
|
|
|
file->f_mapping);
|
|
|
return 0;
|
|
@@ -299,7 +298,6 @@ static long madvise_willneed(struct vm_area_struct *vma,
|
|
|
return 0;
|
|
|
}
|
|
|
|
|
|
- *prev = vma;
|
|
|
start = ((start - vma->vm_start) >> PAGE_SHIFT) + vma->vm_pgoff;
|
|
|
if (end > vma->vm_end)
|
|
|
end = vma->vm_end;
|