函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\dma\swiotlb.c Create Date:2022-07-27 11:35:49
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:Systems with larger DMA zones (those that don't support ISA) can* initialize the swiotlb later using the slab allocator if needed.* This should be just like above, but with some error catching.

函数原型:int swiotlb_late_init_with_default_size(size_t default_size)

返回类型:int

参数:

类型参数名称
size_tdefault_size
279  req_nslabs等于The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages.
280  unsigned char * vstart = NULL
282  rc等于0
284  如果非The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages.
285  The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages.等于default_size右移log of the size of each IO TLB slab. The number of slabs is command line* controllable.
286  The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages.等于@a is a power of 2 value (The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages., Maximum allowable number of contiguous slabs to map,* must be a power of 2. What is the appropriate value ?* The complexity of {map,unmap}_single is linearly dependent on this value.)
292  order等于get_order - Determine the allocation order of a memory size*@size: The size for which to get the order* Determine the allocation order of a particular sized block of memory
293  The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages.等于SLABS_PER_PAGE左移order
294  bytes等于The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages.左移log of the size of each IO TLB slab. The number of slabs is command line* controllable.
296 SLABS_PER_PAGE左移order位大于Minimum IO TLB size to bother booting with. Systems with mainly* 64bit capable cards will only lightly use the swiotlb. If we can't* allocate a contiguous 1MB, we're probably in trouble anyway.循环
297  vstart等于__get_free_pages(GFP_DMA | DOC: Action modifiers* Action modifiers* ~~~~~~~~~~~~~~~~* %__GFP_NOWARN suppresses allocation failure reports.* %__GFP_COMP address compound page metadata.* %__GFP_ZERO returns a zeroed page on success., order)
299  如果vstart退出
301  order自减
304  如果非vstart
305  The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages.等于req_nslabs
306  返回:负ENOMEM
308  如果order不等于get_order - Determine the allocation order of a memory size*@size: The size for which to get the order* Determine the allocation order of a particular sized block of memory
309  打印警告信息("only able to allocate %ld MB\n", (PAGE_SIZE << order) >> 20)
311  The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages.等于SLABS_PER_PAGE左移order
313  rc等于swiotlb_late_init_with_tbl(vstart, The number of IO TLB blocks (in groups of 64) between io_tlb_start and* io_tlb_end. This is command line adjustable via setup_io_tlb_npages.)
314  如果rcfree_pages((unsignedlong)vstart, order)
317  返回:rc