Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1498414

Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA balancing

From Jan Kara <jack@suse.cz>
Newsgroups linux.kernel
Subject Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA balancing
Date 2016-10-10 18:40 +0200
Message-ID <sqLMm-3uW-29@gated-at.bofh.it> (permalink)
References (5 earlier) <spFpD-2pN-31@gated-at.bofh.it> <spGc1-32z-21@gated-at.bofh.it> <spHUt-4gr-5@gated-at.bofh.it> <sqE89-7l8-3@gated-at.bofh.it> <sqE89-7l8-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Mon 10-10-16 09:28:28, Lorenzo Stoakes wrote:
> On Mon, Oct 10, 2016 at 09:47:12AM +0200, Jan Kara wrote:
> > Yeah, so my cleanups where mostly concerned about mmap_sem locking and
> > reducing number of places which cared about those. Regarding flags for
> > get_user_pages() / get_vaddr_frames(), I agree that using flags argument
> > as Linus suggests will make it easier to see what the callers actually
> > want. So I'm for that.
> 
> Great, thanks Jan! I have a draft patch that needs a little tweaking/further
> testing but isn't too far off.
> 
> One thing I am wondering about is whether functions that have write/force
> parameters replaced with gup_flags should mask against (FOLL_WRITE | FOLL_FORCE)
> to prevent callers from doing unexpected things with other FOLL_* flags?
> 
> I'm inclined _not_ to because it adds a rather non-obvious restriction on this
> parameter, reduces clarity about which flags are actually being used (which is
> the point of the patch in the first place), and the caller ought to know what
> they are doing.

Yeah, just leave flags as is. There is no strong reason to restrict them.

								Honza
-- 
Jan Kara <jack@suse.com>
SUSE Labs, CR

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Lorenzo Stoakes <lstoakes@gmail.com> - 2016-09-25 20:50 +0200
  Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA balancing Linus Torvalds <torvalds@linux-foundation.org> - 2016-09-25 23:00 +0200
    Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA balancing Linus Torvalds <torvalds@linux-foundation.org> - 2016-09-26 00:30 +0200
    Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Rik van Riel <riel@redhat.com> - 2016-09-26 00:40 +0200
      Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA balancing Linus Torvalds <torvalds@linux-foundation.org> - 2016-09-26 01:00 +0200
        Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Hugh Dickins <hughd@google.com> - 2016-09-26 01:30 +0200
        Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Rik van Riel <riel@redhat.com> - 2016-09-26 02:50 +0200
          Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA balancing Linus Torvalds <torvalds@linux-foundation.org> - 2016-09-26 03:10 +0200
        Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Lorenzo Stoakes <lstoakes@gmail.com> - 2016-10-07 12:10 +0200
          Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA balancing Linus Torvalds <torvalds@linux-foundation.org> - 2016-10-07 17:40 +0200
            Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Lorenzo Stoakes <lstoakes@gmail.com> - 2016-10-07 18:30 +0200
              Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Hugh Dickins <hughd@google.com> - 2016-10-07 20:20 +0200
                Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Lorenzo Stoakes <lstoakes@gmail.com> - 2016-10-07 20:30 +0200
                Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Lorenzo Stoakes <lstoakes@gmail.com> - 2016-10-10 10:30 +0200
                Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Jan Kara <jack@suse.cz> - 2016-10-10 18:40 +0200
                Re: [PATCH] mm: check VMA flags to avoid invalid PROT_NONE NUMA  balancing Jan Kara <jack@suse.cz> - 2016-10-10 10:40 +0200

csiph-web