Skip to content
Snippets Groups Projects
Select Git revision
  • 3b5fdd260e66fcc4fa6273990fb1deb6656ceb2b
  • master default protected
  • android-msm-bullhead-3.10-nougat_kgdb_less_changes
  • android-msm-bullhead-3.10-nougat_kgdb
  • android-msm-bullhead-3.10-nougat_klist
  • android-4.4
  • android-msm-vega-4.4-oreo-daydream
  • android-msm-wahoo-4.4-p-preview-5
  • android-msm-wahoo-4.4-pie
  • android-msm-marlin-3.18-p-preview-5
  • android-msm-marlin-3.18-pie
  • android-msm-wahoo-2018.07-oreo-m2
  • android-msm-wahoo-2018.07-oreo-m4
  • android-msm-wahoo-4.4-p-preview-4
  • android-msm-bullhead-3.10-oreo-m6
  • android-msm-angler-3.10-oreo-m6
  • android-msm-marlin-3.18-p-preview-4
  • android-msm-stargazer-3.18-oreo-wear-dr
  • android-msm-catshark-3.18-oreo-wear-dr
  • android-msm-wahoo-4.4-oreo-m2
  • android-msm-wahoo-4.4-oreo-m4
  • android-daydreamos-8.0.0_r0.5
  • android-8.1.0_r0.92
  • android-8.1.0_r0.91
  • android-daydreamos-8.0.0_r0.4
  • android-p-preview-5_r0.2
  • android-p-preview-5_r0.1
  • android-9.0.0_r0.5
  • android-9.0.0_r0.4
  • android-9.0.0_r0.2
  • android-9.0.0_r0.1
  • android-8.1.0_r0.81
  • android-8.1.0_r0.80
  • android-8.1.0_r0.78
  • android-8.1.0_r0.76
  • android-8.1.0_r0.75
  • android-8.1.0_r0.72
  • android-8.1.0_r0.70
  • android-p-preview-4_r0.2
  • android-p-preview-4_r0.1
  • android-wear-8.0.0_r0.30
41 results

firmware_class.c

Blame
  • user avatar
    Taniya Das authored
    Peripheral loader requesting for dma allocation could have regions which
    are either carveout or cma region. In case of a carveout which could be
    large area, the allocation could fail due to constraints of vmalloc
    space.
    To avoid allocation failure, set the dma attribute to NO_KERNEL_MAPPING
    for all requested allocations.
    
    When NO_KERNEL_MAPPING is set as an attribute, dma allocation for
    carveout will return a dummy allocated address and for a cma region a
    valid address will be returned, but the kernel mapping for that address
    will not exist.
    
    When peripheral loader requires the firmware data to be copied or the
    address region to be zeroed-out, it will perform:
    
    map_fw_mem will invoke dma_remap api which will take care of
    	- ioremap the address for carveout and provide a valid virtual
    	  address for a requested size.
    	- remap the address, update the kernel mapping for cma regions
    	  and provide a valid virtual address for a requested size.
    
    unmap_fw_mem will invoke dma_unremap api will take care of
    	- iounmap the address for carveout regions for a requested size.
    	- remove the kernel mapping for requested size.
    
    Pass the buffer size from firmware driver to peripheral loader for
    dma_unremap.
    
    Change-Id: Ic1feecbd604008da62ef7a84b07ab8cad2baee94
    Signed-off-by: default avatarTaniya Das <tdas@codeaurora.org>
    3b5fdd26
    History
    firmware_class.c 42.31 KiB