1__BITMAP_PARSE(9)       Basic Kernel Library Functions       __BITMAP_PARSE(9)
2
3
4

NAME

6       __bitmap_parse - convert an ASCII hex string into a bitmap.
7

SYNOPSIS

9       int __bitmap_parse(const char * buf, unsigned int buflen, int is_user,
10                          unsigned long * maskp, int nmaskbits);
11

ARGUMENTS

13       buf
14           pointer to buffer containing string.
15
16       buflen
17           buffer size in bytes. If string is smaller than this then it must
18           be terminated with a \0.
19
20       is_user
21           location of buffer, 0 indicates kernel space
22
23       maskp
24           pointer to bitmap array that will contain result.
25
26       nmaskbits
27           size of bitmap, in bits.
28

DESCRIPTION

30       Commas group hex digits into chunks. Each chunk defines exactly 32 bits
31       of the resultant bitmask. No chunk may specify a value larger than 32
32       bits (-EOVERFLOW), and if a chunk specifies a smaller value then
33       leading 0-bits are prepended.  -EINVAL is returned for illegal
34       characters and for grouping errors such as “1,,5”, “,44”, “,” and "".
35       Leading and trailing whitespace accepted, but not embedded whitespace.
36
38Kernel Hackers Manual 2.6.         June 2019                 __BITMAP_PARSE(9)
Impressum