提交 a52ce121 编写于 作者: S Sean Paul 提交者: Catalin Marinas

arm64: Use DMA_ERROR_CODE to denote failed allocation

This patch replaces the static assignment of ~0 to dma_handle with
DMA_ERROR_CODE to be consistent with other platforms.
Signed-off-by: NSean Paul <seanpaul@chromium.org>
Signed-off-by: NCatalin Marinas <catalin.marinas@arm.com>
上级 7acf71d1
......@@ -122,7 +122,7 @@ static void *__dma_alloc_noncoherent(struct device *dev, size_t size,
no_map:
__dma_free_coherent(dev, size, ptr, *dma_handle, attrs);
no_mem:
*dma_handle = ~0;
*dma_handle = DMA_ERROR_CODE;
return NULL;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册