Function report |
Source Code:mm\percpu.c |
Create Date:2022-07-28 14:25:51 |
Last Modify:2022-05-23 13:52:24 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:pcpu_next_fit_region - finds fit areas for a given allocation request*@chunk: chunk of interest*@alloc_bits: size of allocation*@align: alignment of area (max PAGE_SIZE)*@bit_off: chunk offset*@bits: size of free area* Finds the next free region that is
Proto:static void pcpu_next_fit_region(struct pcpu_chunk *chunk, int alloc_bits, int align, int *bit_off, int *bits)
Type:void
Parameter:
Type | Parameter | Name |
---|---|---|
struct pcpu_chunk * | chunk | |
int | alloc_bits | |
int | align | |
int * | bit_off | |
int * | bits |
422 | i = pcpu_off_to_block_index( * bit_off) |
423 | block_off = pcpu_off_to_block_off( * bit_off) |
426 | bits = 0 |
430 | If bits Then |
432 | If bits >= alloc_bits Then Return |
434 | If size of free space alongthe left side of the block == PCPU_BITMAP_BLOCK_BITS Then Continue |
439 | bits = @a is a power of 2 value (lock relative startingposition of the contig hint , align) - lock relative startingposition of the contig hint |
445 | If contig hint for block && lock relative startingposition of the contig hint >= block_off && contig hint for block >= bits + alloc_bits Then |
452 | bit_off = pcpu_block_off_to_off(i, start) |
453 | Return |
456 | block_off = 0 |
458 | bit_off = @a is a power of 2 value (PCPU_BITMAP_BLOCK_BITS - size of free space alongthe right side of the block , align) |
460 | bits = PCPU_BITMAP_BLOCK_BITS - bit_off |
461 | bit_off = pcpu_block_off_to_off(i, * bit_off) |
462 | If bits >= alloc_bits Then Return |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |