lkml.org 
[lkml]   [2013]   [Jan]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH 1/3] mm: use long type for page counts in mm_populate() and get_user_pages()
    On Wed, 30 Jan 2013 16:26:18 -0800
    Michel Lespinasse <walken@google.com> wrote:

    > Use long type for page counts in mm_populate() so as to avoid integer
    > overflow

    Would prefer to use unsigned long if we're churning this code. A "page
    count" can never be negative and we avoid the various possible
    overflow/signedness issues.

    However get_user_pages() and follow_hugetlb_page() return "page count
    or -ve errno", so we're somewhat screwed there. And that's the bulk of
    the patch :(

    btw, what twit merged a follow_hugetlb_page() which takes an
    undocumented argument called "i". Sigh.



    \
     
     \ /
      Last update: 2013-01-31 02:01    [W:2.667 / U:0.888 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site