函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\slab.c Create Date:2022-07-27 17:19:56
Last Modify:2022-05-23 17:02:55 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:释放内存

函数原型:void kfree(const void *objp)

返回类型:void

参数:

类型参数名称
const void *objp
3791  trace_kfree(_RET_IP_, objp)
3793  如果此条件成立可能性小(为编译器优化)(ZERO_OR_NULL_PTR(objp))则返回
3795  local_irq_save(flags)
3796  kfree_debugcheck(objp)
3797  c等于virt_to_cache(objp)
3798  如果非c
3799  local_irq_restore(flags)
3800  返回
3802  Called when kernel memory is freed (or unmapped), or if a lock* is destroyed or reinitialized - this code checks whether there is* any held lock in the memory range of to :
3804  debug_check_no_obj_freed(objp, The size of an object without metadata )
3805  Release an obj back to its cache. If the obj has a constructed state, it must* be in this state _before_ it is released. Called with disabled ints.
3806  local_irq_restore(flags)
调用者
名称描述
lock_torture_stats_printPrint torture statistics
lock_torture_cleanupForward reference.
lock_torture_init
__test_cycle
stress_inorder_work
stress_reorder_work
stress_one_work
stress
pm_qos_power_release
pm_vt_switch_unregisterpm_vt_switch_unregister - stop tracking a device's VT switching needs*@dev: device* Remove @dev from the vt switch list.
resume_store
free_mem_extents_mem_extents - Free a list of memory extents.*@list: List of extents to free.
create_mem_extentsreate_mem_extents - Create a list of memory extents.*@list: List to put the extents into.*@gfp_mask: Mask to use for memory allocations.* The extents represent contiguous ranges of PFNs.
create_basic_memory_bitmapsreate_basic_memory_bitmaps - Create bitmaps to hold basic page information
free_basic_memory_bitmaps_basic_memory_bitmaps - Free memory bitmaps holding basic information.* Free memory bitmaps allocated by create_basic_memory_bitmaps(). The* auxiliary pointers are necessary so that the bitmaps themselves are not* referred to while they are being freed.
free_all_swap_pages_all_swap_pages - free swap pages allocated for saving image data.* It also frees the extents used to register which swap entries had been* allocated.
save_image_lzosave_image_lzo - Save the suspend image data compressed with LZO.*@handle: Swap map handle to use for saving the image.*@snapshot: Image to read data from.*@nr_to_write: Number of pages to save.
release_swap_readerThe following functions allow us to read data using a swap map* in a file-alike way
swap_read_page
load_image_lzoload_image_lzo - Load compressed image data and decompress them with LZO.*@handle: Swap map handle to use for loading data.*@snapshot: Image to copy uncompressed data into.*@nr_to_read: Number of pages to load.
wakelock_lookup_add
em_create_pd
devkmsg_write
devkmsg_release
syslog_print
syslog_print_all
__free_irqInternal function to unregister an irqaction - used to free* regular and special interrupts that are part of the architecture.
free_irq_irq - free an interrupt allocated with request_irq*@irq: Interrupt line to free*@dev_id: Device identity to free* Remove an interrupt handler
__cleanup_nmiThis function must be called with desc->lock held
request_threaded_irq注册中断线程
request_nmiquest_nmi - allocate an interrupt line for NMI delivery*@irq: Interrupt line to allocate*@handler: Function to be called when the IRQ occurs
free_percpu_irq_percpu_irq - free an interrupt allocated with request_percpu_irq*@irq: Interrupt line to free*@dev_id: Device identity to free* Remove a percpu interrupt handler. The handler is removed, but* the interrupt line is not disabled. This must be done on each
free_percpu_nmi
__request_percpu_irq__request_percpu_irq - allocate a percpu interrupt line*@irq: Interrupt line to allocate*@handler: Function to be called when the IRQ occurs
request_percpu_nmiquest_percpu_nmi - allocate a percpu interrupt line for NMI delivery*@irq: Interrupt line to allocate*@handler: Function to be called when the IRQ occurs
__irq_domain_alloc_fwnodeq_domain_alloc_fwnode - Allocate a fwnode_handle suitable for* identifying an irq domain*@type: Type of irqchip_fwnode
irq_domain_free_fwnodeq_domain_free_fwnode - Free a non-OF-backed fwnode_handle* Free a fwnode_handle allocated with irq_domain_alloc_fwnode.
__irq_domain_add__irq_domain_add() - Allocate a new irq_domain data structure*@fwnode: firmware node for the interrupt controller*@size: Size of linear map; 0 for radix mapping only*@hwirq_max: Maximum number of interrupts supported by controller*@direct_max: Maximum
irq_domain_removeq_domain_remove() - Remove an irq domain.*@domain: domain to remove* This routine is used to remove an irq domain. The caller must ensure* that all mappings within the domain have been disposed of prior to* use, depending on the revmap type.
irq_domain_update_bus_token
irq_sim_initq_sim_init - Initialize the interrupt simulator: allocate a range of* dummy interrupts.*@sim: The interrupt simulator object to initialize.*@num_irqs: Number of interrupts to allocate* On success: return the base of the allocated interrupt range.
irq_sim_finiq_sim_fini - Deinitialize the interrupt simulator: free the interrupt* descriptors and allocated memory.*@sim: The interrupt simulator to tear down.
alloc_msi_entryalloc_msi_entry - Allocate an initialize msi_entry*@dev: Pointer to the device for which this is allocated*@nvec: The number of vectors used in this entry*@affinity: Optional pointer to an affinity mask array size of @nvec* If @affinity is not NULL then
free_msi_entry
alloc_node_to_cpumask
free_node_to_cpumask
__irq_build_affinity_masks
irq_create_affinity_masksq_create_affinity_masks - Create affinity masks for multiqueue spreading*@nvecs: The total number of vectors*@affd: Description of the affinity requirements* Returns the irq_affinity_desc pointer or NULL if allocation failed.
irq_alloc_matrixq_alloc_matrix - Allocate a irq_matrix structure and initialize it*@matrix_bits: Number of matrix bits must be <= IRQ_MATRIX_BITS*@alloc_start: From which bit the allocation search starts*@alloc_end: At which bit the allocation search ends, i
mempool_exitmempool_exit - exit a mempool initialized with mempool_init()*@pool: pointer to the memory pool which was initialized with* mempool_init().* Free all reserved elements in @pool and @pool itself. This function* only sleeps if the free_fn() function sleeps.
mempool_destroymempool_destroy - deallocate a memory pool*@pool: pointer to the memory pool which was allocated via* mempool_create().* Free all reserved elements in @pool and @pool itself. This function* only sleeps if the free_fn() function sleeps.
mempool_create_node
mempool_resizemempool_resize - resize an existing memory pool*@pool: pointer to the memory pool which was allocated via* mempool_create().*@new_min_nr: the new minimum number of elements guaranteed to be* allocated for this pool.* This function shrinks/grows the pool
mempool_kfree
prealloc_shrinkerAdd a shrinker callback to be called from the vm.
free_prealloced_shrinker
unregister_shrinkerRemove one
kfree_constkfree_const - conditionally free memory*@x: pointer to the memory* Function calls kfree only if @x is not in .rodata section.
memdup_usermemdup_user - duplicate memory region from user space*@src: source address in user space*@len: number of bytes to copy* Return: an ERR_PTR() on failure. Result is physically* contiguous, to be freed by kfree().
memdup_user_nulmemdup_user_nul - duplicate memory region from user space and NUL-terminate*@src: source address in user space*@len: number of bytes to copy* Return: an ERR_PTR() on failure.
kvfreekvfree() - Free memory.*@addr: Pointer to allocated memory.* kvfree frees memory allocated by any of vmalloc(), kmalloc() or kvmalloc().* It is slightly more efficient to use kfree() or vfree() if you are certain* that you know which one to use.
vmstat_stop
bdi_alloc_node
release_bdi