summaryrefslogtreecommitdiffstats
path: root/sound/pci/ymfpci
diff options
context:
space:
mode:
authorClemens Ladisch <clemens@ladisch.de>2011-09-16 23:08:28 +0200
committerTakashi Iwai <tiwai@suse.de>2011-09-20 08:56:56 +0200
commit5b0416a3c2f301e67d307ffc26ba43dff2d0d435 (patch)
tree4d4314764b7a43a182248df1f6cbcead79bff193 /sound/pci/ymfpci
parentd5b702a64b4c273c8eed7e4e721364493d01fdc9 (diff)
downloadlinux-5b0416a3c2f301e67d307ffc26ba43dff2d0d435.tar.bz2
ALSA: ymfpci: allow to disable the SRC
Add the PCM rules to allow disabling the PCM playback and capture SRCs. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/ymfpci')
-rw-r--r--sound/pci/ymfpci/ymfpci_main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/sound/pci/ymfpci/ymfpci_main.c b/sound/pci/ymfpci/ymfpci_main.c
index 88c5c5c28d02..66ea71b2a70d 100644
--- a/sound/pci/ymfpci/ymfpci_main.c
+++ b/sound/pci/ymfpci/ymfpci_main.c
@@ -906,6 +906,9 @@ static int snd_ymfpci_playback_open_1(struct snd_pcm_substream *substream)
5334, UINT_MAX);
if (err < 0)
return err;
+ err = snd_pcm_hw_rule_noresample(runtime, 48000);
+ if (err < 0)
+ return err;
ypcm = kzalloc(sizeof(*ypcm), GFP_KERNEL);
if (ypcm == NULL)
@@ -1028,6 +1031,9 @@ static int snd_ymfpci_capture_open(struct snd_pcm_substream *substream,
5334, UINT_MAX);
if (err < 0)
return err;
+ err = snd_pcm_hw_rule_noresample(runtime, 48000);
+ if (err < 0)
+ return err;
ypcm = kzalloc(sizeof(*ypcm), GFP_KERNEL);
if (ypcm == NULL)