ALSA: Implement channel maps for standard onboard AC97 drivers
[firefly-linux-kernel-4.4.55.git] / sound / pci / fm801.c
index ce3e548de41da10012f6661cecb6089c698578d3..cc2e91d1553822699251c15baf950e406243df8d 100644 (file)
@@ -711,6 +711,13 @@ static int __devinit snd_fm801_pcm(struct fm801 *chip, int device, struct snd_pc
                                              snd_dma_pci_data(chip->pci),
                                              chip->multichannel ? 128*1024 : 64*1024, 128*1024);
 
+       err = snd_pcm_add_chmap_ctls(pcm, SNDRV_PCM_STREAM_PLAYBACK,
+                                    snd_pcm_alt_chmaps,
+                                    chip->multichannel ? 6 : 2, 0,
+                                    NULL);
+       if (err < 0)
+               return err;
+
        if (rpcm)
                *rpcm = pcm;
        return 0;