Skip to content
Unverified Commit 057b8945 authored by Navid Emamdoost's avatar Navid Emamdoost Committed by Mark Brown
Browse files

spi: lpspi: fix memory leak in fsl_lpspi_probe

In fsl_lpspi_probe an SPI controller is allocated either via
spi_alloc_slave or spi_alloc_master. In all but one error cases this
controller is put by going to error handling code. This commit fixes the
case when pm_runtime_get_sync fails and it should go to the error
handling path.

Fixes: 944c01a8

 ("spi: lpspi: enable runtime pm for lpspi")
Signed-off-by: default avatarNavid Emamdoost <navid.emamdoost@gmail.com>
Link: https://lore.kernel.org/r/20190930034602.1467-1-navid.emamdoost@gmail.com
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent d3b0ffa1
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment