]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
merge 2.6.13-rc4 with ACPI's to-linus tree
authorLen Brown <len.brown@intel.com>
Sat, 30 Jul 2005 05:55:32 +0000 (01:55 -0400)
committerLen Brown <len.brown@intel.com>
Sat, 30 Jul 2005 05:55:32 +0000 (01:55 -0400)
1  2 
arch/i386/pci/irq.c
sound/pci/intel8x0.c

diff --combined arch/i386/pci/irq.c
index 187350ccf8645bfd7a1391a8c71353f4800ba2f4,d291fb7f13571b2a45e54e42668ccd25423509e8..86348b68fda1a0e5621e48c1b3edb15f173f5cc0
@@@ -56,7 -56,6 +56,7 @@@ struct irq_router_handler 
  };
  
  int (*pcibios_enable_irq)(struct pci_dev *dev) = NULL;
 +void (*pcibios_disable_irq)(struct pci_dev *dev) = NULL;
  
  /*
   *  Check passed address for the PCI IRQ Routing Table signature
@@@ -551,6 -550,13 +551,13 @@@ static __init int intel_router_probe(st
  static __init int via_router_probe(struct irq_router *r, struct pci_dev *router, u16 device)
  {
        /* FIXME: We should move some of the quirk fixup stuff here */
+       if (router->device == PCI_DEVICE_ID_VIA_82C686 &&
+                       device == PCI_DEVICE_ID_VIA_82C586_0) {
+               /* Asus k7m bios wrongly reports 82C686A as 586-compatible */
+               device = PCI_DEVICE_ID_VIA_82C686;
+       }
        switch(device)
        {
                case PCI_DEVICE_ID_VIA_82C586_0:
diff --combined sound/pci/intel8x0.c
index 28ac005c21b5ca9381e62316a4a94e24ddbbb857,7c806bd9cc90a7c647ac128270366f440f0c8b48..d7af3e47443263810fc075e1b7e9e513c01996fc
@@@ -424,6 -424,7 +424,7 @@@ struct _snd_intel8x0 
        unsigned xbox: 1;               /* workaround for Xbox AC'97 detection */
  
        int spdif_idx;  /* SPDIF BAR index; *_SPBAR or -1 if use PCMOUT */
+       unsigned int sdm_saved; /* SDM reg value */
  
        ac97_bus_t *ac97_bus;
        ac97_t *ac97[3];
@@@ -2373,8 -2374,8 +2374,11 @@@ static int intel8x0_suspend(snd_card_t 
        for (i = 0; i < 3; i++)
                if (chip->ac97[i])
                        snd_ac97_suspend(chip->ac97[i]);
+       if (chip->device_type == DEVICE_INTEL_ICH4)
+               chip->sdm_saved = igetbyte(chip, ICHREG(SDM));
++
 +      if (chip->irq >= 0)
 +              free_irq(chip->irq, (void *)chip);
        pci_disable_device(chip->pci);
        return 0;
  }
@@@ -2386,10 -2387,18 +2390,20 @@@ static int intel8x0_resume(snd_card_t *
  
        pci_enable_device(chip->pci);
        pci_set_master(chip->pci);
 -      snd_intel8x0_chip_init(chip, 0);
 +      request_irq(chip->irq, snd_intel8x0_interrupt, SA_INTERRUPT|SA_SHIRQ, card->shortname, (void *)chip);
 +      synchronize_irq(chip->irq);
 +      snd_intel8x0_chip_init(chip, 1);
  
+       /* re-initialize mixer stuff */
+       if (chip->device_type == DEVICE_INTEL_ICH4) {
+               /* enable separate SDINs for ICH4 */
+               iputbyte(chip, ICHREG(SDM), chip->sdm_saved);
+               /* use slot 10/11 for SPDIF */
+               iputdword(chip, ICHREG(GLOB_CNT),
+                         (igetdword(chip, ICHREG(GLOB_CNT)) & ~ICH_PCM_SPDIF_MASK) |
+                         ICH_PCM_SPDIF_1011);
+       }
        /* refill nocache */
        if (chip->fix_nocache)
                fill_nocache(chip->bdbars.area, chip->bdbars.bytes, 1);
@@@ -2455,8 -2464,7 +2469,7 @@@ static void __devinit intel8x0_measure_
        }
        do_gettimeofday(&start_time);
        spin_unlock_irq(&chip->reg_lock);
-       set_current_state(TASK_UNINTERRUPTIBLE);
-       schedule_timeout(HZ / 20);
+       msleep(50);
        spin_lock_irq(&chip->reg_lock);
        /* check the position */
        pos = ichdev->fragsize1;