• Kees Cook's avatar
    bitmap: Fix return values to be unsigned · 005f1700
    Kees Cook authored
    Both nodemask and bitmap routines had mixed return values that provided
    potentially signed return values that could never happen. This was
    leading to the compiler getting confusing about the range of possible
    return values (it was thinking things could be negative where they could
    not be). In preparation for fixing nodemask, fix all the bitmap routines
    that should be returning unsigned (or bool) values.
    
    Cc: Yury Norov <yury.norov@gmail.com>
    Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk>
    Cc: Christophe de Dinechin <dinechin@redhat.com>
    Cc: Alexey Dobriyan <adobriyan@gmail.com>
    Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
    Cc: Andrew Morton <akpm@linux-foundation.org>
    Cc: Zhen Lei <thunder.leizhen@huawei.com>
    Signed-off-by: default avatarKees Cook <keescook@chromium.org>
    Signed-off-by: default avatarYury Norov <yury.norov@gmail.com>
    005f1700
bitmap.c 2.34 KB