diff options
-rw-r--r-- | sound/pci/hda/hda_intel.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c index ddabc827ac44..b6e6314d0069 100644 --- a/sound/pci/hda/hda_intel.c +++ b/sound/pci/hda/hda_intel.c | |||
@@ -513,6 +513,7 @@ static int azx_alloc_cmd_io(struct azx *chip) | |||
513 | 513 | ||
514 | static void azx_init_cmd_io(struct azx *chip) | 514 | static void azx_init_cmd_io(struct azx *chip) |
515 | { | 515 | { |
516 | spin_lock_irq(&chip->reg_lock); | ||
516 | /* CORB set up */ | 517 | /* CORB set up */ |
517 | chip->corb.addr = chip->rb.addr; | 518 | chip->corb.addr = chip->rb.addr; |
518 | chip->corb.buf = (u32 *)chip->rb.area; | 519 | chip->corb.buf = (u32 *)chip->rb.area; |
@@ -544,13 +545,16 @@ static void azx_init_cmd_io(struct azx *chip) | |||
544 | azx_writew(chip, RINTCNT, 1); | 545 | azx_writew(chip, RINTCNT, 1); |
545 | /* enable rirb dma and response irq */ | 546 | /* enable rirb dma and response irq */ |
546 | azx_writeb(chip, RIRBCTL, ICH6_RBCTL_DMA_EN | ICH6_RBCTL_IRQ_EN); | 547 | azx_writeb(chip, RIRBCTL, ICH6_RBCTL_DMA_EN | ICH6_RBCTL_IRQ_EN); |
548 | spin_unlock_irq(&chip->reg_lock); | ||
547 | } | 549 | } |
548 | 550 | ||
549 | static void azx_free_cmd_io(struct azx *chip) | 551 | static void azx_free_cmd_io(struct azx *chip) |
550 | { | 552 | { |
553 | spin_lock_irq(&chip->reg_lock); | ||
551 | /* disable ringbuffer DMAs */ | 554 | /* disable ringbuffer DMAs */ |
552 | azx_writeb(chip, RIRBCTL, 0); | 555 | azx_writeb(chip, RIRBCTL, 0); |
553 | azx_writeb(chip, CORBCTL, 0); | 556 | azx_writeb(chip, CORBCTL, 0); |
557 | spin_unlock_irq(&chip->reg_lock); | ||
554 | } | 558 | } |
555 | 559 | ||
556 | static unsigned int azx_command_addr(u32 cmd) | 560 | static unsigned int azx_command_addr(u32 cmd) |