diff options
author | Takashi Iwai <tiwai@suse.de> | 2012-05-19 17:21:25 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2012-05-19 17:25:23 +0200 |
commit | 09cf03b80c593b08e8b630a145e14f485200b5af (patch) | |
tree | 21a5d5b26f68bf3a4076c76e29d9eb3dc47e1bc5 /sound/pci/hda/patch_via.c | |
parent | c882246d840073a3dd0533ca164dfcbd7f6bd207 (diff) |
ALSA: hda - Fix possible races of accesses to connection list array
Like the previous fixes for cache hash accesses, a protection over
accesses to the widget connection list array must be provided.
Together with this action, remove snd_hda_get_conn_list() which can be
always race, and replace it with either snd_hda_get_num_conns() or
snd_hda_get_connections() calls.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda/patch_via.c')
-rw-r--r-- | sound/pci/hda/patch_via.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/pci/hda/patch_via.c b/sound/pci/hda/patch_via.c index db272fb5e57..82b368068e0 100644 --- a/sound/pci/hda/patch_via.c +++ b/sound/pci/hda/patch_via.c @@ -485,7 +485,7 @@ static void activate_output_mix(struct hda_codec *codec, struct nid_path *path, if (!path) return; - num = snd_hda_get_conn_list(codec, mix_nid, NULL); + num = snd_hda_get_num_conns(codec, mix_nid); for (i = 0; i < num; i++) { if (i == idx) val = AMP_IN_UNMUTE(i); |