From d5b6816943c149941f88f4985234997417d05bab Mon Sep 17 00:00:00 2001 From: Muli Ben-Yehuda Date: Tue, 17 Jul 2007 04:05:15 -0700 Subject: [PATCH] --- yaml --- r: 60866 b: refs/heads/master c: 3b20b9b4e985fcc48b4eea401cb289a856422c93 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/sound/oss/trident.c | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index e4f78283a312..dba8f6ed9bc1 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: d8f75b9183d613d3c29ea451a1cfb793daad5034 +refs/heads/master: 3b20b9b4e985fcc48b4eea401cb289a856422c93 diff --git a/trunk/sound/oss/trident.c b/trunk/sound/oss/trident.c index 3e408f491927..2e3e78e1bf67 100644 --- a/trunk/sound/oss/trident.c +++ b/trunk/sound/oss/trident.c @@ -2702,6 +2702,7 @@ trident_open(struct inode *inode, struct file *file) struct trident_card *card = devs; struct trident_state *state = NULL; struct dmabuf *dmabuf = NULL; + unsigned long flags; /* Added by Matt Wu 01-05-2001 */ /* TODO: there's some redundacy here wrt the check below */ @@ -2779,7 +2780,9 @@ trident_open(struct inode *inode, struct file *file) /* set default channel attribute to normal playback */ dmabuf->channel->attribute = CHANNEL_PB; } + spin_lock_irqsave(&card->lock, flags); trident_set_dac_rate(state, 8000); + spin_unlock_irqrestore(&card->lock, flags); } if (file->f_mode & FMODE_READ) { @@ -2797,7 +2800,9 @@ trident_open(struct inode *inode, struct file *file) dmabuf->channel->attribute = (CHANNEL_REC | PCM_LR | MONO_MIX); } + spin_lock_irqsave(&card->lock, flags); trident_set_adc_rate(state, 8000); + spin_unlock_irqrestore(&card->lock, flags); /* Added by Matt Wu 01-05-2001 */ if (card->pci_id == PCI_DEVICE_ID_ALI_5451)