mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
migration: migrate_vmas should check "vma"
migrate_vmas() should check "vma" not "vma->vm_next" for for-loop condition. Signed-off-by: Daisuke Nishimura <[email protected]> Cc: Christoph Lameter <[email protected]> Cc: Johannes Weiner <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
17c9d12e12
commit
1001c9fb87
1 changed files with 1 additions and 1 deletions
|
|
@ -1129,7 +1129,7 @@ int migrate_vmas(struct mm_struct *mm, const nodemask_t *to,
|
|||
struct vm_area_struct *vma;
|
||||
int err = 0;
|
||||
|
||||
for(vma = mm->mmap; vma->vm_next && !err; vma = vma->vm_next) {
|
||||
for (vma = mm->mmap; vma && !err; vma = vma->vm_next) {
|
||||
if (vma->vm_ops && vma->vm_ops->migrate) {
|
||||
err = vma->vm_ops->migrate(vma, to, from, flags);
|
||||
if (err)
|
||||
|
|
|
|||
Loading…
Reference in a new issue