]> Git Repo - linux.git/commitdiff
Merge branch 'topic/misc' into for-linus
authorTakashi Iwai <[email protected]>
Mon, 21 May 2012 10:51:35 +0000 (12:51 +0200)
committerTakashi Iwai <[email protected]>
Mon, 21 May 2012 10:51:35 +0000 (12:51 +0200)
1  2 
sound/pci/Kconfig
sound/pci/hda/hda_intel.c
sound/pci/rme9652/hdsp.c

diff --combined sound/pci/Kconfig
index 5ca0939e4223b6104893fd77ccb3e1f5f982bd6c,30f0863ff55f1b87a3be4892662e79e28f8fd1b5..ff3af6e77d610adc5cfba4748bdf25ac587238d7
@@@ -2,8 -2,8 +2,8 @@@
  
  config SND_TEA575X
        tristate
 -      depends on SND_FM801_TEA575X_BOOL || SND_ES1968_RADIO || RADIO_SF16FMR2
 -      default SND_FM801 || SND_ES1968 || RADIO_SF16FMR2
 +      depends on SND_FM801_TEA575X_BOOL || SND_ES1968_RADIO || RADIO_SF16FMR2 || RADIO_MAXIRADIO
 +      default SND_FM801 || SND_ES1968 || RADIO_SF16FMR2 || RADIO_MAXIRADIO
  
  menuconfig SND_PCI
        bool "PCI sound devices"
@@@ -228,7 -228,7 +228,7 @@@ config SND_OXYGE
          Say Y here to include support for sound cards based on the
          C-Media CMI8788 (Oxygen HD Audio) chip:
           * Asound A-8788
-          * Asus Xonar DG
+          * Asus Xonar DG/DGX
           * AuzenTech X-Meridian
           * AuzenTech X-Meridian 2G
           * Bgears b-Enspirer
index 7ee46aba6ea7522bffe5b7e70da71544aeee2f5b,fc33eb9e0174e98e4b0b4e1b38ea5e68c8ec7ff2..4ab8102f87ea63ccb83ccbb6c97df2d17fa13eb2
@@@ -497,7 -497,6 +497,7 @@@ enum 
        AZX_DRIVER_NVIDIA,
        AZX_DRIVER_TERA,
        AZX_DRIVER_CTX,
 +      AZX_DRIVER_CTHDA,
        AZX_DRIVER_GENERIC,
        AZX_NUM_DRIVERS, /* keep this as last entry */
  };
  #define AZX_DCAPS_OLD_SSYNC   (1 << 20)       /* Old SSYNC reg for ICH */
  #define AZX_DCAPS_BUFSIZE     (1 << 21)       /* no buffer size alignment */
  #define AZX_DCAPS_ALIGN_BUFSIZE       (1 << 22)       /* buffer size alignment */
 +#define AZX_DCAPS_4K_BDLE_BOUNDARY (1 << 23)  /* BDLE in 4k boundary */
  
  /* quirks for ATI SB / AMD Hudson */
  #define AZX_DCAPS_PRESET_ATI_SB \
        (AZX_DCAPS_NVIDIA_SNOOP | AZX_DCAPS_RIRB_DELAY | AZX_DCAPS_NO_MSI |\
         AZX_DCAPS_ALIGN_BUFSIZE)
  
 +#define AZX_DCAPS_PRESET_CTHDA \
 +      (AZX_DCAPS_NO_MSI | AZX_DCAPS_POSFIX_LPIB | AZX_DCAPS_4K_BDLE_BOUNDARY)
 +
  static char *driver_short_names[] __devinitdata = {
        [AZX_DRIVER_ICH] = "HDA Intel",
        [AZX_DRIVER_PCH] = "HDA Intel PCH",
        [AZX_DRIVER_NVIDIA] = "HDA NVidia",
        [AZX_DRIVER_TERA] = "HDA Teradici", 
        [AZX_DRIVER_CTX] = "HDA Creative", 
 +      [AZX_DRIVER_CTHDA] = "HDA Creative",
        [AZX_DRIVER_GENERIC] = "HD-Audio Generic",
  };
  
@@@ -789,13 -783,11 +789,13 @@@ static unsigned int azx_rirb_get_respon
  {
        struct azx *chip = bus->private_data;
        unsigned long timeout;
 +      unsigned long loopcounter;
        int do_poll = 0;
  
   again:
        timeout = jiffies + msecs_to_jiffies(1000);
 -      for (;;) {
 +
 +      for (loopcounter = 0;; loopcounter++) {
                if (chip->polling_mode || do_poll) {
                        spin_lock_irq(&chip->reg_lock);
                        azx_update_rirb(chip);
                }
                if (time_after(jiffies, timeout))
                        break;
 -              if (bus->needs_damn_long_delay)
 +              if (bus->needs_damn_long_delay || loopcounter > 3000)
                        msleep(2); /* temporary workaround */
                else {
                        udelay(10);
@@@ -1291,8 -1283,7 +1291,8 @@@ static irqreturn_t azx_interrupt(int ir
  /*
   * set up a BDL entry
   */
 -static int setup_bdle(struct snd_pcm_substream *substream,
 +static int setup_bdle(struct azx *chip,
 +                    struct snd_pcm_substream *substream,
                      struct azx_dev *azx_dev, u32 **bdlp,
                      int ofs, int size, int with_ioc)
  {
                bdl[1] = cpu_to_le32(upper_32_bits(addr));
                /* program the size field of the BDL entry */
                chunk = snd_pcm_sgbuf_get_chunk_size(substream, ofs, size);
 +              /* one BDLE cannot cross 4K boundary on CTHDA chips */
 +              if (chip->driver_caps & AZX_DCAPS_4K_BDLE_BOUNDARY) {
 +                      u32 remain = 0x1000 - (ofs & 0xfff);
 +                      if (chunk > remain)
 +                              chunk = remain;
 +              }
                bdl[2] = cpu_to_le32(chunk);
                /* program the IOC to enable interrupt
                 * only when the whole fragment is processed
@@@ -1369,7 -1354,7 +1369,7 @@@ static int azx_setup_periods(struct az
                                   bdl_pos_adj[chip->dev_index]);
                        pos_adj = 0;
                } else {
 -                      ofs = setup_bdle(substream, azx_dev,
 +                      ofs = setup_bdle(chip, substream, azx_dev,
                                         &bdl, ofs, pos_adj,
                                         !substream->runtime->no_period_wakeup);
                        if (ofs < 0)
                pos_adj = 0;
        for (i = 0; i < periods; i++) {
                if (i == periods - 1 && pos_adj)
 -                      ofs = setup_bdle(substream, azx_dev, &bdl, ofs,
 +                      ofs = setup_bdle(chip, substream, azx_dev, &bdl, ofs,
                                         period_bytes - pos_adj, 0);
                else
 -                      ofs = setup_bdle(substream, azx_dev, &bdl, ofs,
 +                      ofs = setup_bdle(chip, substream, azx_dev, &bdl, ofs,
                                         period_bytes,
                                         !substream->runtime->no_period_wakeup);
                if (ofs < 0)
@@@ -2566,6 -2551,8 +2566,8 @@@ static struct snd_pci_quirk probe_mask_
        /* forced codec slots */
        SND_PCI_QUIRK(0x1043, 0x1262, "ASUS W5Fm", 0x103),
        SND_PCI_QUIRK(0x1046, 0x1262, "ASUS W5F", 0x103),
+       /* WinFast VP200 H (Teradici) user reported broken communication */
+       SND_PCI_QUIRK(0x3a21, 0x040d, "WinFast VP200 H", 0x101),
        {}
  };
  
@@@ -3131,11 -3118,6 +3133,11 @@@ static DEFINE_PCI_DEVICE_TABLE(azx_ids
          .driver_data = AZX_DRIVER_CTX | AZX_DCAPS_CTX_WORKAROUND |
          AZX_DCAPS_RIRB_PRE_DELAY | AZX_DCAPS_POSFIX_LPIB },
  #endif
 +      /* CTHDA chips */
 +      { PCI_DEVICE(0x1102, 0x0010),
 +        .driver_data = AZX_DRIVER_CTHDA | AZX_DCAPS_PRESET_CTHDA },
 +      { PCI_DEVICE(0x1102, 0x0012),
 +        .driver_data = AZX_DRIVER_CTHDA | AZX_DCAPS_PRESET_CTHDA },
        /* Vortex86MX */
        { PCI_DEVICE(0x17f3, 0x3010), .driver_data = AZX_DRIVER_GENERIC },
        /* VMware HDAudio */
  MODULE_DEVICE_TABLE(pci, azx_ids);
  
  /* pci_driver definition */
- static struct pci_driver driver = {
+ static struct pci_driver azx_driver = {
        .name = KBUILD_MODNAME,
        .id_table = azx_ids,
        .probe = azx_probe,
  #endif
  };
  
- static int __init alsa_card_azx_init(void)
- {
-       return pci_register_driver(&driver);
- }
- static void __exit alsa_card_azx_exit(void)
- {
-       pci_unregister_driver(&driver);
- }
- module_init(alsa_card_azx_init)
- module_exit(alsa_card_azx_exit)
+ module_pci_driver(azx_driver);
diff --combined sound/pci/rme9652/hdsp.c
index 0b2aea2ce1729086db78b38b134777935d04fb00,5cc31a400810699ca882b5a5ff216000ccb0a108..0d6930c4f4b7bc4c2d4cecd0a074cbd30b3305bb
@@@ -5170,7 -5170,6 +5170,7 @@@ static int snd_hdsp_create_hwdep(struc
        strcpy(hw->name, "HDSP hwdep interface");
  
        hw->ops.ioctl = snd_hdsp_hwdep_ioctl;
 +      hw->ops.ioctl_compat = snd_hdsp_hwdep_ioctl;
  
        return 0;
  }
@@@ -5636,22 -5635,11 +5636,11 @@@ static void __devexit snd_hdsp_remove(s
        pci_set_drvdata(pci, NULL);
  }
  
- static struct pci_driver driver = {
+ static struct pci_driver hdsp_driver = {
        .name =     KBUILD_MODNAME,
        .id_table = snd_hdsp_ids,
        .probe =    snd_hdsp_probe,
        .remove = __devexit_p(snd_hdsp_remove),
  };
  
- static int __init alsa_card_hdsp_init(void)
- {
-       return pci_register_driver(&driver);
- }
- static void __exit alsa_card_hdsp_exit(void)
- {
-       pci_unregister_driver(&driver);
- }
- module_init(alsa_card_hdsp_init)
- module_exit(alsa_card_hdsp_exit)
+ module_pci_driver(hdsp_driver);
This page took 0.08397 seconds and 4 git commands to generate.