summaryrefslogtreecommitdiffstats
path: root/sound/pci
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2013-09-19 18:46:43 +0200
committerTakashi Iwai <tiwai@suse.de>2013-09-19 18:46:43 +0200
commit43cdd088b1b10306d4eb6d9208b62c7f60abffeb (patch)
tree8dd799379a241c1b47b736299c306eb77f06e6ff /sound/pci
parentbf69aa906ccddacc9e966794869431374953738a (diff)
parent4028b6c4c03f213260e9290ff3a6b5439aad07ce (diff)
downloadlinux-stable-43cdd088b1b10306d4eb6d9208b62c7f60abffeb.tar.gz
linux-stable-43cdd088b1b10306d4eb6d9208b62c7f60abffeb.tar.bz2
linux-stable-43cdd088b1b10306d4eb6d9208b62c7f60abffeb.zip
Merge branch 'for-linus' into for-next
Diffstat (limited to 'sound/pci')
-rw-r--r--sound/pci/Kconfig12
-rw-r--r--sound/pci/ens1370.c2
-rw-r--r--sound/pci/es1968.c2
-rw-r--r--sound/pci/fm801.c2
-rw-r--r--sound/pci/hda/hda_intel.c36
-rw-r--r--sound/pci/via82xx.c2
6 files changed, 43 insertions, 13 deletions
diff --git a/sound/pci/Kconfig b/sound/pci/Kconfig
index fe6fa93a6262..46ed9e8ae0fd 100644
--- a/sound/pci/Kconfig
+++ b/sound/pci/Kconfig
@@ -1,10 +1,5 @@
# ALSA PCI drivers
-config SND_TEA575X
- tristate
- depends on SND_FM801_TEA575X_BOOL || SND_ES1968_RADIO || RADIO_SF16FMR2 || RADIO_MAXIRADIO || RADIO_SHARK
- default SND_FM801 || SND_ES1968 || RADIO_SF16FMR2 || RADIO_MAXIRADIO || RADIO_SHARK
-
menuconfig SND_PCI
bool "PCI sound devices"
depends on PCI
@@ -542,7 +537,11 @@ config SND_ES1968_INPUT
config SND_ES1968_RADIO
bool "Enable TEA5757 radio tuner support for es1968"
depends on SND_ES1968
+ depends on MEDIA_RADIO_SUPPORT
depends on VIDEO_V4L2=y || VIDEO_V4L2=SND_ES1968
+ select RADIO_ADAPTERS
+ select RADIO_TEA575X
+
help
Say Y here to include support for TEA5757 radio tuner integrated on
some MediaForte cards (e.g. SF64-PCE2).
@@ -562,7 +561,10 @@ config SND_FM801
config SND_FM801_TEA575X_BOOL
bool "ForteMedia FM801 + TEA5757 tuner"
depends on SND_FM801
+ depends on MEDIA_RADIO_SUPPORT
depends on VIDEO_V4L2=y || VIDEO_V4L2=SND_FM801
+ select RADIO_ADAPTERS
+ select RADIO_TEA575X
help
Say Y here to include support for soundcards based on the ForteMedia
FM801 chip with a TEA5757 tuner (MediaForte SF256-PCS, SF256-PCP and
diff --git a/sound/pci/ens1370.c b/sound/pci/ens1370.c
index ca8929b9a5d6..61262f396004 100644
--- a/sound/pci/ens1370.c
+++ b/sound/pci/ens1370.c
@@ -1842,7 +1842,7 @@ static int snd_ensoniq_create_gameport(struct ensoniq *ensoniq, int dev)
default:
if (!request_region(io_port, 8, "ens137x: gameport")) {
- printk(KERN_WARNING "ens137x: gameport io port 0x%#x in use\n",
+ printk(KERN_WARNING "ens137x: gameport io port %#x in use\n",
io_port);
return -EBUSY;
}
diff --git a/sound/pci/es1968.c b/sound/pci/es1968.c
index 5e2ec9687731..b0e3d92c4656 100644
--- a/sound/pci/es1968.c
+++ b/sound/pci/es1968.c
@@ -113,7 +113,7 @@
#include <sound/initval.h>
#ifdef CONFIG_SND_ES1968_RADIO
-#include <sound/tea575x-tuner.h>
+#include <media/tea575x.h>
#endif
#define CARD_NAME "ESS Maestro1/2"
diff --git a/sound/pci/fm801.c b/sound/pci/fm801.c
index 706c5b67b708..45bc8a95b7c4 100644
--- a/sound/pci/fm801.c
+++ b/sound/pci/fm801.c
@@ -37,7 +37,7 @@
#include <asm/io.h>
#ifdef CONFIG_SND_FM801_TEA575X_BOOL
-#include <sound/tea575x-tuner.h>
+#include <media/tea575x.h>
#endif
MODULE_AUTHOR("Jaroslav Kysela <perex@perex.cz>");
diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
index 7f88dd6aff6e..6e61a019aa5e 100644
--- a/sound/pci/hda/hda_intel.c
+++ b/sound/pci/hda/hda_intel.c
@@ -555,6 +555,9 @@ struct azx {
#ifdef CONFIG_SND_HDA_DSP_LOADER
struct azx_dev saved_azx_dev;
#endif
+
+ /* secondary power domain for hdmi audio under vga device */
+ struct dev_pm_domain hdmi_pm_domain;
};
#define CREATE_TRACE_POINTS
@@ -1397,8 +1400,9 @@ static irqreturn_t azx_interrupt(int irq, void *dev_id)
int i, ok;
#ifdef CONFIG_PM_RUNTIME
- if (chip->pci->dev.power.runtime_status != RPM_ACTIVE)
- return IRQ_NONE;
+ if (chip->driver_caps & AZX_DCAPS_PM_RUNTIME)
+ if (chip->pci->dev.power.runtime_status != RPM_ACTIVE)
+ return IRQ_NONE;
#endif
spin_lock(&chip->reg_lock);
@@ -1409,7 +1413,7 @@ static irqreturn_t azx_interrupt(int irq, void *dev_id)
}
status = azx_readl(chip, INTSTS);
- if (status == 0) {
+ if (status == 0 || status == 0xffffffff) {
spin_unlock(&chip->reg_lock);
return IRQ_NONE;
}
@@ -2971,6 +2975,12 @@ static int azx_runtime_suspend(struct device *dev)
struct snd_card *card = dev_get_drvdata(dev);
struct azx *chip = card->private_data;
+ if (chip->disabled)
+ return 0;
+
+ if (!(chip->driver_caps & AZX_DCAPS_PM_RUNTIME))
+ return 0;
+
/* enable controller wake up event */
azx_writew(chip, WAKEEN, azx_readw(chip, WAKEEN) |
STATESTS_INT_MASK);
@@ -2991,6 +3001,12 @@ static int azx_runtime_resume(struct device *dev)
struct hda_codec *codec;
int status;
+ if (chip->disabled)
+ return 0;
+
+ if (!(chip->driver_caps & AZX_DCAPS_PM_RUNTIME))
+ return 0;
+
if (chip->driver_caps & AZX_DCAPS_I915_POWERWELL)
hda_display_power(true);
@@ -3020,6 +3036,9 @@ static int azx_runtime_idle(struct device *dev)
struct snd_card *card = dev_get_drvdata(dev);
struct azx *chip = card->private_data;
+ if (chip->disabled)
+ return 0;
+
if (!power_save_controller ||
!(chip->driver_caps & AZX_DCAPS_PM_RUNTIME))
return -EBUSY;
@@ -3102,13 +3121,19 @@ static void azx_vs_set_state(struct pci_dev *pci,
"%s: %s via VGA-switcheroo\n", pci_name(chip->pci),
disabled ? "Disabling" : "Enabling");
if (disabled) {
+ pm_runtime_put_sync_suspend(&pci->dev);
azx_suspend(&pci->dev);
+ /* when we get suspended by vga switcheroo we end up in D3cold,
+ * however we have no ACPI handle, so pci/acpi can't put us there,
+ * put ourselves there */
+ pci->current_state = PCI_D3cold;
chip->disabled = true;
if (snd_hda_lock_devices(chip->bus))
snd_printk(KERN_WARNING SFX "%s: Cannot lock devices!\n",
pci_name(chip->pci));
} else {
snd_hda_unlock_devices(chip->bus);
+ pm_runtime_get_noresume(&pci->dev);
chip->disabled = false;
azx_resume(&pci->dev);
}
@@ -3163,6 +3188,9 @@ static int register_vga_switcheroo(struct azx *chip)
if (err < 0)
return err;
chip->vga_switcheroo_registered = 1;
+
+ /* register as an optimus hdmi audio power domain */
+ vga_switcheroo_init_domain_pm_optimus_hdmi_audio(&chip->pci->dev, &chip->hdmi_pm_domain);
return 0;
}
#else
@@ -3914,7 +3942,7 @@ static int azx_probe_continue(struct azx *chip)
power_down_all_codecs(chip);
azx_notifier_register(chip);
azx_add_card_list(chip);
- if (chip->driver_caps & AZX_DCAPS_PM_RUNTIME)
+ if ((chip->driver_caps & AZX_DCAPS_PM_RUNTIME) || chip->use_vga_switcheroo)
pm_runtime_put_noidle(&pci->dev);
return 0;
diff --git a/sound/pci/via82xx.c b/sound/pci/via82xx.c
index 3c511d0caf9e..5ae6f042c586 100644
--- a/sound/pci/via82xx.c
+++ b/sound/pci/via82xx.c
@@ -1940,7 +1940,7 @@ static int snd_via686_create_gameport(struct via82xx *chip, unsigned char *legac
r = request_region(JOYSTICK_ADDR, 8, "VIA686 gameport");
if (!r) {
- printk(KERN_WARNING "via82xx: cannot reserve joystick port 0x%#x\n",
+ printk(KERN_WARNING "via82xx: cannot reserve joystick port %#x\n",
JOYSTICK_ADDR);
return -EBUSY;
}