aboutsummaryrefslogtreecommitdiff
path: root/drivers/fpga/fpga-bridge.c
diff options
context:
space:
mode:
authorDavid Rientjes <[email protected]>2020-04-14 17:04:58 -0700
committerChristoph Hellwig <[email protected]>2020-04-25 13:17:05 +0200
commit76a19940bd62a81148c303f3df6d0cee9ae4b509 (patch)
tree71caddd9ff61acea7bb981c723e33575278431c4 /drivers/fpga/fpga-bridge.c
parent54adadf9b08571fb8b11dc9d0d3a2ddd39825efd (diff)
dma-direct: atomic allocations must come from atomic coherent pools
When a device requires unencrypted memory and the context does not allow blocking, memory must be returned from the atomic coherent pools. This avoids the remap when CONFIG_DMA_DIRECT_REMAP is not enabled and the config only requires CONFIG_DMA_COHERENT_POOL. This will be used for CONFIG_AMD_MEM_ENCRYPT in a subsequent patch. Keep all memory in these pools unencrypted. When set_memory_decrypted() fails, this prohibits the memory from being added. If adding memory to the genpool fails, and set_memory_encrypted() subsequently fails, there is no alternative other than leaking the memory. Signed-off-by: David Rientjes <[email protected]> Signed-off-by: Christoph Hellwig <[email protected]>
Diffstat (limited to 'drivers/fpga/fpga-bridge.c')
0 files changed, 0 insertions, 0 deletions