Commit e8d7bd34 authored by Takashi Iwai's avatar Takashi Iwai

Merge branch 'topic/hda' into for-linus

parents eff317d0 1b0652eb
......@@ -275,7 +275,8 @@ STAC9200
dell-m25 Dell Inspiron E1505n
dell-m26 Dell Inspiron 1501
dell-m27 Dell Inspiron E1705/9400
gateway Gateway laptops with EAPD control
gateway-m4 Gateway laptops with EAPD control
gateway-m4-2 Gateway laptops with EAPD control
panasonic Panasonic CF-74
STAC9205/9254
......@@ -302,6 +303,7 @@ STAC9220/9221
macbook-pro Intel Mac Book Pro 2nd generation (eq. type 3)
imac-intel Intel iMac (eq. type 2)
imac-intel-20 Intel iMac (newer version) (eq. type 3)
ecs202 ECS/PC chips
dell-d81 Dell (unknown)
dell-d82 Dell (unknown)
dell-m81 Dell (unknown)
......@@ -310,9 +312,13 @@ STAC9220/9221
STAC9202/9250/9251
==================
ref Reference board, base config
m1 Some Gateway MX series laptops (NX560XL)
m1-2 Some Gateway MX series laptops (MX6453)
m2 Some Gateway MX series laptops (M255)
m2-2 Some Gateway MX series laptops
m3 Some Gateway MX series laptops
m5 Some Gateway MX series laptops (MP6954)
m6 Some Gateway NX series laptops
pa6 Gateway NX860 series
STAC9227/9228/9229/927x
=======================
......@@ -329,6 +335,7 @@ STAC92HD71B*
dell-m4-1 Dell desktops
dell-m4-2 Dell desktops
dell-m4-3 Dell desktops
hp-m4 HP dv laptops
STAC92HD73*
===========
......@@ -337,6 +344,7 @@ STAC92HD73*
dell-m6-amic Dell desktops/laptops with analog mics
dell-m6-dmic Dell desktops/laptops with digital mics
dell-m6 Dell desktops/laptops with both type of mics
dell-eq Dell desktops/laptops
STAC92HD83*
===========
......
......@@ -2723,6 +2723,67 @@ int snd_hda_check_board_config(struct hda_codec *codec,
}
EXPORT_SYMBOL_HDA(snd_hda_check_board_config);
/**
* snd_hda_check_board_codec_sid_config - compare the current codec
subsystem ID with the
config table
This is important for Gateway notebooks with SB450 HDA Audio
where the vendor ID of the PCI device is:
ATI Technologies Inc SB450 HDA Audio [1002:437b]
and the vendor/subvendor are found only at the codec.
* @codec: the HDA codec
* @num_configs: number of config enums
* @models: array of model name strings
* @tbl: configuration table, terminated by null entries
*
* Compares the modelname or PCI subsystem id of the current codec with the
* given configuration table. If a matching entry is found, returns its
* config value (supposed to be 0 or positive).
*
* If no entries are matching, the function returns a negative value.
*/
int snd_hda_check_board_codec_sid_config(struct hda_codec *codec,
int num_configs, const char **models,
const struct snd_pci_quirk *tbl)
{
const struct snd_pci_quirk *q;
/* Search for codec ID */
for (q = tbl; q->subvendor; q++) {
unsigned long vendorid = (q->subdevice) | (q->subvendor << 16);
if (vendorid == codec->subsystem_id)
break;
}
if (!q->subvendor)
return -1;
tbl = q;
if (tbl->value >= 0 && tbl->value < num_configs) {
#ifdef CONFIG_SND_DEBUG_DETECT
char tmp[10];
const char *model = NULL;
if (models)
model = models[tbl->value];
if (!model) {
sprintf(tmp, "#%d", tbl->value);
model = tmp;
}
snd_printdd(KERN_INFO "hda_codec: model '%s' is selected "
"for config %x:%x (%s)\n",
model, tbl->subvendor, tbl->subdevice,
(tbl->name ? tbl->name : "Unknown device"));
#endif
return tbl->value;
}
return -1;
}
EXPORT_SYMBOL_HDA(snd_hda_check_board_codec_sid_config);
/**
* snd_hda_add_new_ctls - create controls from the array
* @codec: the HDA codec
......@@ -2815,7 +2876,7 @@ void snd_hda_power_down(struct hda_codec *codec)
return;
if (power_save(codec)) {
codec->power_transition = 1; /* avoid reentrance */
schedule_delayed_work(&codec->power_work,
queue_delayed_work(codec->bus->workq, &codec->power_work,
msecs_to_jiffies(power_save(codec) * 1000));
}
}
......
......@@ -296,6 +296,9 @@ void snd_print_pcm_bits(int pcm, char *buf, int buflen);
int snd_hda_check_board_config(struct hda_codec *codec, int num_configs,
const char **modelnames,
const struct snd_pci_quirk *pci_list);
int snd_hda_check_board_codec_sid_config(struct hda_codec *codec,
int num_configs, const char **models,
const struct snd_pci_quirk *tbl);
int snd_hda_add_new_ctls(struct hda_codec *codec,
struct snd_kcontrol_new *knew);
......
......@@ -160,6 +160,7 @@ static int patch_nvhdmi(struct hda_codec *codec)
*/
static struct hda_codec_preset snd_hda_preset_nvhdmi[] = {
{ .id = 0x10de0002, .name = "MCP78 HDMI", .patch = patch_nvhdmi },
{ .id = 0x10de0006, .name = "MCP78 HDMI", .patch = patch_nvhdmi },
{ .id = 0x10de0007, .name = "MCP7A HDMI", .patch = patch_nvhdmi },
{ .id = 0x10de0067, .name = "MCP67 HDMI", .patch = patch_nvhdmi },
{ .id = 0x10de8001, .name = "MCP73 HDMI", .patch = patch_nvhdmi },
......@@ -167,6 +168,7 @@ static struct hda_codec_preset snd_hda_preset_nvhdmi[] = {
};
MODULE_ALIAS("snd-hda-codec-id:10de0002");
MODULE_ALIAS("snd-hda-codec-id:10de0006");
MODULE_ALIAS("snd-hda-codec-id:10de0007");
MODULE_ALIAS("snd-hda-codec-id:10de0067");
MODULE_ALIAS("snd-hda-codec-id:10de8001");
......
......@@ -10573,6 +10573,7 @@ static struct snd_pci_quirk alc262_cfg_tbl[] = {
SND_PCI_QUIRK(0x10cf, 0x142d, "Fujitsu Lifebook E8410", ALC262_FUJITSU),
SND_PCI_QUIRK(0x144d, 0xc032, "Samsung Q1 Ultra", ALC262_ULTRA),
SND_PCI_QUIRK(0x144d, 0xc039, "Samsung Q1U EL", ALC262_ULTRA),
SND_PCI_QUIRK(0x144d, 0xc510, "Samsung Q45", ALC262_HIPPO),
SND_PCI_QUIRK(0x17aa, 0x384e, "Lenovo 3000 y410", ALC262_LENOVO_3000),
SND_PCI_QUIRK(0x17ff, 0x0560, "Benq ED8", ALC262_BENQ_ED8),
SND_PCI_QUIRK(0x17ff, 0x058d, "Benq T31-16", ALC262_BENQ_T31),
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment