Commit 0e7adbe263f89ea2ef15b5af5e80a812b2a85025

Authored by Takashi Iwai
1 parent 62b7e5e09b

ALSA: hda - Disable sticky PCM stream assignment for AD codecs

The sticky PCM stream assignment introduced in 2.6.36 kernel seems
causing problems on AD codecs.  At some time later, the streaming no
longer works by unknown reason.  A simple workaround is to disable
sticky-assignment for these codecs.

Tested-by: Vasily Khoruzhick <anarsoul@gmail.com>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>

Showing 3 changed files with 11 additions and 0 deletions Side-by-side Diff

sound/pci/hda/hda_codec.c
... ... @@ -1284,6 +1284,9 @@
1284 1284 if (!nid)
1285 1285 return;
1286 1286  
  1287 + if (codec->no_sticky_stream)
  1288 + do_now = 1;
  1289 +
1287 1290 snd_printdd("hda_codec_cleanup_stream: NID=0x%x\n", nid);
1288 1291 p = get_hda_cvt_setup(codec, nid);
1289 1292 if (p) {
sound/pci/hda/hda_codec.h
... ... @@ -850,6 +850,7 @@
850 850 unsigned int pin_amp_workaround:1; /* pin out-amp takes index
851 851 * (e.g. Conexant codecs)
852 852 */
  853 + unsigned int no_sticky_stream:1; /* no sticky-PCM stream assignment */
853 854 unsigned int pins_shutup:1; /* pins are shut up */
854 855 unsigned int no_trigger_sense:1; /* don't trigger at pin-sensing */
855 856 #ifdef CONFIG_SND_HDA_POWER_SAVE
sound/pci/hda/patch_analog.c
... ... @@ -1276,6 +1276,7 @@
1276 1276 spec->multiout.no_share_stream = 1;
1277 1277  
1278 1278 codec->no_trigger_sense = 1;
  1279 + codec->no_sticky_stream = 1;
1279 1280  
1280 1281 return 0;
1281 1282 }
... ... @@ -1463,6 +1464,7 @@
1463 1464 codec->patch_ops = ad198x_patch_ops;
1464 1465  
1465 1466 codec->no_trigger_sense = 1;
  1467 + codec->no_sticky_stream = 1;
1466 1468  
1467 1469 return 0;
1468 1470 }
... ... @@ -1917,6 +1919,7 @@
1917 1919 }
1918 1920  
1919 1921 codec->no_trigger_sense = 1;
  1922 + codec->no_sticky_stream = 1;
1920 1923  
1921 1924 return 0;
1922 1925 }
... ... @@ -3236,6 +3239,7 @@
3236 3239 spec->vmaster_nid = 0x04;
3237 3240  
3238 3241 codec->no_trigger_sense = 1;
  3242 + codec->no_sticky_stream = 1;
3239 3243  
3240 3244 return 0;
3241 3245 }
... ... @@ -3450,6 +3454,7 @@
3450 3454 codec->patch_ops = ad198x_patch_ops;
3451 3455  
3452 3456 codec->no_trigger_sense = 1;
  3457 + codec->no_sticky_stream = 1;
3453 3458  
3454 3459 return 0;
3455 3460 }
... ... @@ -4423,6 +4428,7 @@
4423 4428 }
4424 4429  
4425 4430 codec->no_trigger_sense = 1;
  4431 + codec->no_sticky_stream = 1;
4426 4432  
4427 4433 return 0;
4428 4434 }
... ... @@ -4762,6 +4768,7 @@
4762 4768 }
4763 4769  
4764 4770 codec->no_trigger_sense = 1;
  4771 + codec->no_sticky_stream = 1;
4765 4772  
4766 4773 return 0;
4767 4774 }