mirror of
https://github.com/torvalds/linux.git
synced 2026-09-24 06:24:02 +02:00
ASoC: ti: j721e-evm: Avoid mixing goto with guard()
The previous guard(mutex) conversion mixed cleanup helpers with
goto-based error handling, which is discouraged by the cleanup.h
guidelines.
Restore mutex_lock()/mutex_unlock() instead.
Fixes: 6f4cf77320 ("ASoC: ti: j721e-evm: Use guard() for mutex locks")
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
Link: https://patch.msgid.link/20260701041310.230725-3-phucduc.bui@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
02fd694e60
commit
47a0dde9a3
|
|
@ -4,6 +4,7 @@
|
|||
* Author: Peter Ujfalusi <peter.ujfalusi@ti.com>
|
||||
*/
|
||||
|
||||
#include <linux/cleanup.h>
|
||||
#include <linux/clk.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/of.h>
|
||||
|
|
@ -263,7 +264,7 @@ static int j721e_audio_startup(struct snd_pcm_substream *substream)
|
|||
int ret = 0;
|
||||
int i;
|
||||
|
||||
guard(mutex)(&priv->mutex);
|
||||
mutex_lock(&priv->mutex);
|
||||
|
||||
domain->active++;
|
||||
|
||||
|
|
@ -303,6 +304,7 @@ static int j721e_audio_startup(struct snd_pcm_substream *substream)
|
|||
out:
|
||||
if (ret)
|
||||
domain->active--;
|
||||
mutex_unlock(&priv->mutex);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user