diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2014-07-31 15:57:51 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-09-17 09:19:17 -0700 |
commit | ae631fad83dcfa4bd905aa34db4317fc292b3120 (patch) | |
tree | 617e6d3c875d1e6ce23a44f805ead339be96a64f | |
parent | e9d0913e1754d5d0489767e03e4311ceff53891d (diff) | |
download | linux-stable-ae631fad83dcfa4bd905aa34db4317fc292b3120.tar.gz linux-stable-ae631fad83dcfa4bd905aa34db4317fc292b3120.tar.bz2 linux-stable-ae631fad83dcfa4bd905aa34db4317fc292b3120.zip |
ASoC: pxa: pxa-ssp: small leak in probe()
commit 4548728981de259d7d37d0ae968a777b09794168 upstream.
There is a small memory leak if probe() fails.
Fixes: 2023c90c3a2c ('ASoC: pxa: pxa-ssp: add DT bindings')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | sound/soc/pxa/pxa-ssp.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sound/soc/pxa/pxa-ssp.c b/sound/soc/pxa/pxa-ssp.c index a3119a00d8fa..e4558e31a9ee 100644 --- a/sound/soc/pxa/pxa-ssp.c +++ b/sound/soc/pxa/pxa-ssp.c @@ -725,7 +725,8 @@ static int pxa_ssp_probe(struct snd_soc_dai *dai) ssp_handle = of_parse_phandle(dev->of_node, "port", 0); if (!ssp_handle) { dev_err(dev, "unable to get 'port' phandle\n"); - return -ENODEV; + ret = -ENODEV; + goto err_priv; } priv->ssp = pxa_ssp_request_of(ssp_handle, "SoC audio"); |