函数逻辑报告 |
Source Code:kernel\dma\direct.c |
Create Date:2022-07-27 11:33:10 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| 首页 | 函数Tree |
| 注解内核,赢得工具 | 下载SCCT | English |
函数名称:dma_direct_mmap
函数原型:int dma_direct_mmap(struct device *dev, struct vm_area_struct *vma, void *cpu_addr, dma_addr_t dma_addr, size_t size, unsigned long attrs)
返回类型:int
参数:
| 类型 | 参数 | 名称 |
|---|---|---|
| struct device * | dev | |
| struct vm_area_struct * | vma | |
| void * | cpu_addr | |
| dma_addr_t | dma_addr | |
| size_t | size | |
| unsigned long | attrs |
| 446 | user_count等于vma_pages(vma) |
| 447 | count等于 align the pointer to the (next) page boundary (size)右移PAGE_SHIFT determines the page size 位 |
| 448 | pfn等于PHYS_PFN(dma_to_phys(dev, dma_addr)) |
| 451 | Access permissions of this VMA. 等于Return the page attributes used for mapping dma_alloc_* memory, either in* kernel space if remapping is needed, or to userspace through dma_mmap_*. |
| 456 | 如果Offset (within vm_file) in PAGE_SIZEunits 大于等于count或user_count大于count减Offset (within vm_file) in PAGE_SIZEunits 则返回:负ENXIO |
| 458 | 返回:remap_pfn_range(vma, Our start address within vm_mm. , pfn + Offset (within vm_file) in PAGE_SIZEunits , user_count << PAGE_SHIFT determines the page size , Access permissions of this VMA. ) |
| 名称 | 描述 |
|---|---|
| dma_mmap_attrs | dma_mmap_attrs - map a coherent DMA allocation into user space*@dev: valid struct device pointer, or NULL for ISA and EISA-like devices*@vma: vm_area_struct describing requested user mapping*@cpu_addr: kernel CPU-view address returned from |
| 源代码转换工具 开放的插件接口 | X |
|---|---|
| 支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |