Function report |
Source Code:lib\stackdepot.c |
Create Date:2022-07-28 07:20:59 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:stack_depot_save - Save a stack trace from an array*@entries: Pointer to storage array*@nr_entries: Size of the storage array*@alloc_flags: Allocation gfp flags* Return: The handle of the stack struct stored in depot
Proto:depot_stack_handle_t stack_depot_save(unsigned long *entries, unsigned int nr_entries, gfp_t alloc_flags)
Type:depot_stack_handle_t
Parameter:
Type | Parameter | Name |
---|---|---|
unsigned long * | entries | |
unsigned int | nr_entries | |
gfp_t | alloc_flags |
228 | retval = 0 |
230 | void * prealloc = NULL |
234 | If Value for the false possibility is greater at compile time(nr_entries == 0) Then Go to fast_exit |
238 | bucket = stack_table[hash & STACK_HASH_MASK] |
245 | found = find_stack(smp_load_acquire(bucket), entries, nr_entries, hash) |
264 | alloc_flags &= ~GFP_ZONEMASK |
268 | If page Then prealloc = page_address(page) |
272 | spin_lock_irqsave( & depot_lock, flags) |
274 | found = find_stack( * bucket, entries, nr_entries, hash) |
275 | If Not found Then |
276 | new = depot_alloc_stack(entries, nr_entries, hash, & prealloc, alloc_flags) |
279 | If new Then |
288 | Else if prealloc Then |
293 | WARN_ON(!init_stack_slab( & prealloc)) |
296 | spin_unlock_irqrestore( & depot_lock, flags) |
297 | exit : |
298 | If prealloc Then |
300 | free_pages((unsignedlong)prealloc, 'Slab' size order for stack depot, 4 pages ) |
304 | fast_exit : |
305 | Return retval |
Name | Describe |
---|---|
create_dummy_stack | |
save_stack |
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 |