]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
staging: bcm2835-audio: Don't leak workqueue if open fails
authorTuomas Tynkkynen <tuomas@tuxera.com>
Thu, 12 Jul 2018 21:54:17 +0000 (00:54 +0300)
committerJuerg Haefliger <juergh@canonical.com>
Wed, 24 Jul 2019 01:49:22 +0000 (19:49 -0600)
commitefb68922244b6b3adccdcc82fb42861654e5365d
treee8b43d3146c938a4f188d6b598b14a715c709cbe
parentf4477275014e48fa970973003f151293b53273e1
staging: bcm2835-audio: Don't leak workqueue if open fails

BugLink: https://bugs.launchpad.net/bugs/1836117
[ Upstream commit 678c5b119307c40f9a17152512f9c949d0ec7292 ]

Currently, if bcm2835_audio_open() fails partway, the allocated
workqueue is leaked. Avoid that.

While at it, propagate the return value of
bcm2835_audio_open_connection() on failure instead of returning -1.

Signed-off-by: Tuomas Tynkkynen <tuomas@tuxera.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
drivers/staging/vc04_services/bcm2835-audio/bcm2835-vchiq.c