aboutsummaryrefslogtreecommitdiff
path: root/drivers/fpga/fpga-bridge.c
diff options
context:
space:
mode:
authorMiles Chen <[email protected]>2018-02-22 19:22:20 +0800
committerChristoph Hellwig <[email protected]>2018-02-22 15:02:33 -0800
commitaf1da686843750809738c01e153320106e890804 (patch)
treeed3a996f8f9dce16a0ba24b015a1e16bea5920c1 /drivers/fpga/fpga-bridge.c
parenta638af00b27266c09ab7ac69141e6f4ac6c00eff (diff)
dma-debug: fix memory leak in debug_dma_alloc_coherent
Marty reported a memory leakage introduced by commit 3aaabbf1c39e ("lib/dma-debug.c: fix incorrect pfn calculation"). Fix it by checking the virtual address before allocating the entry. This patch also use virt_addr_valid() instead of virt_to_page() to check if a virtual address is linear. Fixes: 3aaabbf1 ("lib/dma-debug.c: fix incorrect pfn calculation") Reported-by: Marty Faltesek <[email protected]> Signed-off-by: Miles Chen <[email protected]> Acked-by: Robin Murphy <[email protected]> Signed-off-by: Christoph Hellwig <[email protected]>
Diffstat (limited to 'drivers/fpga/fpga-bridge.c')
0 files changed, 0 insertions, 0 deletions