|
@@ -2009,7 +2009,7 @@ int hugepage_madvise(struct vm_area_struct *vma,
|
|
|
/*
|
|
|
* Be somewhat over-protective like KSM for now!
|
|
|
*/
|
|
|
- if (*vm_flags & (VM_HUGEPAGE | VM_NO_THP))
|
|
|
+ if (*vm_flags & VM_NO_THP)
|
|
|
return -EINVAL;
|
|
|
*vm_flags &= ~VM_NOHUGEPAGE;
|
|
|
*vm_flags |= VM_HUGEPAGE;
|
|
@@ -2025,7 +2025,7 @@ int hugepage_madvise(struct vm_area_struct *vma,
|
|
|
/*
|
|
|
* Be somewhat over-protective like KSM for now!
|
|
|
*/
|
|
|
- if (*vm_flags & (VM_NOHUGEPAGE | VM_NO_THP))
|
|
|
+ if (*vm_flags & VM_NO_THP)
|
|
|
return -EINVAL;
|
|
|
*vm_flags &= ~VM_HUGEPAGE;
|
|
|
*vm_flags |= VM_NOHUGEPAGE;
|