summaryrefslogtreecommitdiff
path: root/lib/jedec_ddr_data.c
diff options
context:
space:
mode:
authorEvan Nimmo <evan.nimmo@alliedtelesis.co.nz>2020-11-10 15:28:25 +1300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-11-18 18:25:00 +0100
commit2e4d9fac404b2674532c363ce203dc30372c7f7a (patch)
treec5afd54cd287569a2da68fa448c36f9eb484a7a0 /lib/jedec_ddr_data.c
parentbf19a74c7e33921ce79b97d973b343b8f56a9362 (diff)
of/address: Fix of_node memory leak in of_dma_is_coherent
[ Upstream commit a5bea04fcc0b3c0aec71ee1fd58fd4ff7ee36177 ] Commit dabf6b36b83a ("of: Add OF_DMA_DEFAULT_COHERENT & select it on powerpc") added a check to of_dma_is_coherent which returns early if OF_DMA_DEFAULT_COHERENT is enabled. This results in the of_node_put() being skipped causing a memory leak. Moved the of_node_get() below this check so we now we only get the node if OF_DMA_DEFAULT_COHERENT is not enabled. Fixes: dabf6b36b83a ("of: Add OF_DMA_DEFAULT_COHERENT & select it on powerpc") Signed-off-by: Evan Nimmo <evan.nimmo@alliedtelesis.co.nz> Link: https://lore.kernel.org/r/20201110022825.30895-1-evan.nimmo@alliedtelesis.co.nz Signed-off-by: Rob Herring <robh@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'lib/jedec_ddr_data.c')
0 files changed, 0 insertions, 0 deletions