Commit 2df63961 authored by Viresh Kumar's avatar Viresh Kumar Committed by Greg Kroah-Hartman

greybus: audio_codec: Free gccodec on codec probe failure

We aren't freeing the codec, that we allocated before failing to probe
the connection. Free it.
Signed-off-by: default avatarViresh Kumar <viresh.kumar@linaro.org>
Reviewed-by: default avatarJohan Hovold <johan@hovoldconsulting.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
parent 6e304f59
......@@ -713,6 +713,7 @@ static int gbaudio_codec_probe(struct gb_connection *connection)
kfree(topology);
base_error:
gbcodec->mgmt_connection = NULL;
gbaudio_free_codec(dev, gbcodec);
return ret;
}
......
Markdown is supported
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