lkml.org 
[lkml]   [2014]   [Jan]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 0/2] mm->def_flags cleanups (Was: Change khugepaged to respect MMF_THP_DISABLE flag)
On 01/22, Oleg Nesterov wrote:
>
> On 01/22, Alex Thorlton wrote:
> > > + case PR_SET_THP_DISABLE:
> > > + case PR_GET_THP_DISABLE:
> > > + down_write(&me->mm->mmap_sem);
> > > + if (option == PR_SET_THP_DISABLE) {
> > > + if (arg2)
> > > + me->mm->def_flags |= VM_NOHUGEPAGE;
> > > + else
> > > + me->mm->def_flags &= ~VM_NOHUGEPAGE;
> > > + } else {
> > > + error = !!(me->mm->flags && VM_NOHUGEPAGE);
> >
> > Should be:
> >
> > error = !!(me->mm->def_flags && VM_NOHUGEPAGE);
>
> No, we need to return 1 if this bit is set ;)

Damn, you are right of course, we need "&". I didn't notice "&&"
in the patch I sent and misunderstood your "&&" above ;) Sorry.

Oleg.



\
 
 \ /
  Last update: 2014-01-22 21:01    [W:0.080 / U:1.312 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site