mirror of
https://github.com/torvalds/linux.git
synced 2026-07-27 17:47:41 +02:00
ASoC: SDCA: Fix bad move of jack_state initialisation
The initialisation of jack_state was accidentally moved until after its
use, correct this.
Fixes: cb3c257e08 ("ASoC: SDCA: Add correct masks whilst reporting SDCA jack status")
Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Link: https://patch.msgid.link/20260505090811.3697153-1-ckeepax@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
bf2831e4f4
commit
36c543cc51
|
|
@ -203,6 +203,8 @@ int sdca_jack_set_jack(struct sdca_interrupt_info *info, struct snd_soc_jack *ja
|
|||
if (!range)
|
||||
return -EINVAL;
|
||||
|
||||
jack_state = interrupt->priv;
|
||||
|
||||
for (j = 0; j < range->rows; j++) {
|
||||
enum sdca_terminal_type type;
|
||||
|
||||
|
|
@ -211,7 +213,6 @@ int sdca_jack_set_jack(struct sdca_interrupt_info *info, struct snd_soc_jack *ja
|
|||
jack_state->mask |= type_get_mask(type);
|
||||
}
|
||||
|
||||
jack_state = interrupt->priv;
|
||||
jack_state->jack = jack;
|
||||
|
||||
/* Report initial state in case IRQ was already handled */
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user