forked from Minki/linux
ASoC: dapm: Only mark pin widgets as dirty if we actually change state
Small optimisation for noop state updates. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
This commit is contained in:
parent
5567d8c621
commit
1a8b2d9d5b
@ -1927,10 +1927,12 @@ static int snd_soc_dapm_set_pin(struct snd_soc_dapm_context *dapm,
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (w->connected != status)
|
||||
dapm_mark_dirty(w, "pin configuration");
|
||||
|
||||
w->connected = status;
|
||||
if (status == 0)
|
||||
w->force = 0;
|
||||
dapm_mark_dirty(w, "pin configuration");
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user