Scroll to navigation

BITMAP_TO_U32ARRAY(9) Basic Kernel Library Functions BITMAP_TO_U32ARRAY(9)

NAME

bitmap_to_u32array - copy the contents of bitmap to a u32 array of bits

SYNOPSIS

unsigned int bitmap_to_u32array(u32 * buf, unsigned int nwords, const unsigned long * bitmap, unsigned int nbits);

ARGUMENTS

u32 * buf

array of u32 (in host byte order), the dest bitmap, non NULL

unsigned int nwords

number of u32 words in buf

const unsigned long * bitmap

array of unsigned longs, the source bitmap, non NULL

unsigned int nbits

number of bits in bitmap

DESCRIPTION

copy min(nbits, 32*nwords) bits from bitmap to buf. Remaining bits after nbits in buf (if any) are cleared.

Return the number of bits effectively copied.

COPYRIGHT

June 2017 Kernel Hackers Manual 4.11