From 0242672310ab8556d453fe83dd6fe14b5832d141 Mon Sep 17 00:00:00 2001 From: Wu Fengguang Date: Sat, 1 Aug 2009 18:47:41 +0800 Subject: [PATCH] --- yaml --- r: 156379 b: refs/heads/master c: cdb1fbf23181c133fb24f12ad14ccea7dc399599 h: refs/heads/master i: 156377: 97ecd0da931226e47fb8f6b52f39799880cc1134 156375: 3dfd88d879450ac7bf0d7a719288dbb2223965c0 v: v3 --- [refs] | 2 +- trunk/sound/pci/hda/hda_intel.c | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index b12a43e7954f..c272915f621b 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a678cdee25a387c8fc3b2754974695412baf1d85 +refs/heads/master: cdb1fbf23181c133fb24f12ad14ccea7dc399599 diff --git a/trunk/sound/pci/hda/hda_intel.c b/trunk/sound/pci/hda/hda_intel.c index ddabc827ac44..b6e6314d0069 100644 --- a/trunk/sound/pci/hda/hda_intel.c +++ b/trunk/sound/pci/hda/hda_intel.c @@ -513,6 +513,7 @@ static int azx_alloc_cmd_io(struct azx *chip) static void azx_init_cmd_io(struct azx *chip) { + spin_lock_irq(&chip->reg_lock); /* CORB set up */ chip->corb.addr = chip->rb.addr; chip->corb.buf = (u32 *)chip->rb.area; @@ -544,13 +545,16 @@ static void azx_init_cmd_io(struct azx *chip) azx_writew(chip, RINTCNT, 1); /* enable rirb dma and response irq */ azx_writeb(chip, RIRBCTL, ICH6_RBCTL_DMA_EN | ICH6_RBCTL_IRQ_EN); + spin_unlock_irq(&chip->reg_lock); } static void azx_free_cmd_io(struct azx *chip) { + spin_lock_irq(&chip->reg_lock); /* disable ringbuffer DMAs */ azx_writeb(chip, RIRBCTL, 0); azx_writeb(chip, CORBCTL, 0); + spin_unlock_irq(&chip->reg_lock); } static unsigned int azx_command_addr(u32 cmd)