1ALLOCATE_RESOURCE(9)          Hardware Interfaces         ALLOCATE_RESOURCE(9)
2
3
4

NAME

6       allocate_resource - allocate empty slot in the resource tree given
7       range & alignment. The resource will be reallocated with a new size if
8       it was already allocated
9

SYNOPSIS

11       int allocate_resource(struct resource * root, struct resource * new,
12                             resource_size_t size, resource_size_t min,
13                             resource_size_t max, resource_size_t align,
14                             resource_size_t (*alignf) (void *, const struct resource *, resource_size_t, resource_size_t),
15                             void * alignf_data);
16

ARGUMENTS

18       root
19           root resource descriptor
20
21       new
22           resource descriptor desired by caller
23
24       size
25           requested resource region size
26
27       min
28           minimum boundary to allocate
29
30       max
31           maximum boundary to allocate
32
33       align
34           alignment requested, in bytes
35
36       alignf
37           alignment function, optional, called if not NULL
38
39       alignf_data
40           arbitrary data to pass to the alignf function
41
43Kernel Hackers Manual 3.10         June 2019              ALLOCATE_RESOURCE(9)
Impressum