From 15f6c5884ee939f17d8e1fec5bda044a7d995f2f Mon Sep 17 00:00:00 2001 From: Matthieu Crapet Date: Mon, 8 Dec 2014 11:58:29 +0100 Subject: ASoC: atmel_ssc_dai/trivial: typo fix Signed-off-by: Matthieu Crapet Signed-off-by: Nicolas Ferre Signed-off-by: Mark Brown --- sound/soc/atmel/atmel_ssc_dai.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/atmel/atmel_ssc_dai.c b/sound/soc/atmel/atmel_ssc_dai.c index b1cc2a4..99ff35e 100644 --- a/sound/soc/atmel/atmel_ssc_dai.c +++ b/sound/soc/atmel/atmel_ssc_dai.c @@ -267,7 +267,7 @@ static void atmel_ssc_shutdown(struct snd_pcm_substream *substream, if (!ssc_p->dir_mask) { if (ssc_p->initialized) { /* Shutdown the SSC clock. */ - pr_debug("atmel_ssc_dau: Stopping clock\n"); + pr_debug("atmel_ssc_dai: Stopping clock\n"); clk_disable(ssc_p->ssc->clk); free_irq(ssc_p->ssc->irq, ssc_p); -- cgit v1.1 From 681a19560378213a193c424881b2180a783b81ae Mon Sep 17 00:00:00 2001 From: Peter Rosin Date: Mon, 8 Dec 2014 16:33:11 +0100 Subject: ASoC: pcm512x: Trigger auto-increment of register addresses on i2c When the codec is connected using i2c, it will only auto-increment register addresses if msb (0x80) of the register address byte is set. [Fixes cache sync if multiple adjacent registers are updated -- broonie] Signed-off-by: Peter Rosin Signed-off-by: Mark Brown Cc: stable@vger.kernel.org --- sound/soc/codecs/pcm512x-i2c.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/sound/soc/codecs/pcm512x-i2c.c b/sound/soc/codecs/pcm512x-i2c.c index 4d62230..d0547fa 100644 --- a/sound/soc/codecs/pcm512x-i2c.c +++ b/sound/soc/codecs/pcm512x-i2c.c @@ -24,8 +24,13 @@ static int pcm512x_i2c_probe(struct i2c_client *i2c, const struct i2c_device_id *id) { struct regmap *regmap; + struct regmap_config config = pcm512x_regmap; - regmap = devm_regmap_init_i2c(i2c, &pcm512x_regmap); + /* msb needs to be set to enable auto-increment of addresses */ + config.read_flag_mask = 0x80; + config.write_flag_mask = 0x80; + + regmap = devm_regmap_init_i2c(i2c, &config); if (IS_ERR(regmap)) return PTR_ERR(regmap); -- cgit v1.1 From 7e5d8706dd3ee19f8626977935ab16e59b3603be Mon Sep 17 00:00:00 2001 From: Sylwester Nawrocki Date: Mon, 8 Dec 2014 18:45:54 +0100 Subject: ASoC: samsung: i2s: Add missing assignment of variant_regs Add assignment of the variant_regs field which is missing in commit a5a56871f804edac93a53b5e871c0e9818fb9033 ("ASoC: samsung: add support for exynos7 I2S controller"). Without this attempting to probe the secondary DAI fails with an error like: [ 1.763026] Unable to handle kernel NULL pointer dereference at virtual address 0000000c [ 1.780895] pgd = c0004000 [ 1.783606] [0000000c] *pgd=00000000 [ 1.838255] Internal error: Oops: 5 [#1] PREEMPT SMP ARM [ 1.843514] Modules linked in: [ 1.846558] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.18.0-rc1-00009-g5dcb01e-dirty #1521 [ 1.854887] task: ee00a800 ti: ee088000 task.ti: ee088000 [ 1.860284] PC is at i2s_txctrl+0x40/0x2d4 [ 1.864350] LR is at i2s_txctrl+0x28/0x2d4 [ 1.868428] pc : [] lr : [] psr: 60000153 [ 1.868428] sp : ee089dc0 ip : 00000000 fp : ee21f000 [ 1.879883] r10: 00000000 r9 : ee21fb00 r8 : c06406c4 [ 1.885091] r7 : ee21fb00 r6 : 00000000 r5 : f00f6000 r4 : ed943410 [ 1.891601] r3 : 0000016c r2 : c0464550 r1 : c055cef8 r0 : ed943610 [ 1.898113] Flags: nZCv IRQs on FIQs off Mode SVC_32 ISA ARM Segment kernel [ 1.905490] Control: 10c5387d Table: 4000404a DAC: 00000015 [ 1.911218] Process swapper/0 (pid: 1, stack limit = 0xee088240) [ 1.917208] Stack: (0xee089dc0 to 0xee08a000) ... [ 2.068431] [] (i2s_txctrl) from [] (samsung_i2s_dai_probe+0xb8/0x450) [ 2.076676] [] (samsung_i2s_dai_probe) from [] (snd_soc_register_card+0xd98/0x1348) [ 2.086044] [] (snd_soc_register_card) from [] (odroidx2_audio_probe+0xa8/0x11c) [ 2.095160] [] (odroidx2_audio_probe) from [] (platform_drv_probe+0x48/0xa4) [ 2.103922] [] (platform_drv_probe) from [] (driver_probe_device+0x10c/0x22c) [ 2.112773] [] (driver_probe_device) from [] (__driver_attach+0x8c/0x90) [ 2.121192] [] (__driver_attach) from [] (bus_for_each_dev+0x54/0x88) [ 2.129352] [] (bus_for_each_dev) from [] (bus_add_driver+0xd4/0x1d0) [ 2.137510] [] (bus_add_driver) from [] (driver_register+0x78/0xf4) [ 2.145499] [] (driver_register) from [] (do_one_initcall+0x80/0x1b8) [ 2.153670] [] (do_one_initcall) from [] (kernel_init_freeable+0xfc/0x1c8) [ 2.162260] [] (kernel_init_freeable) from [] (kernel_init+0x8/0xec) [ 2.170330] [] (kernel_init) from [] (ret_from_fork+0x14/0x3c) [ 2.177873] Code: e5940000 e59f128c e59f228c e2800010 (e59c700c) Signed-off-by: Sylwester Nawrocki Signed-off-by: Mark Brown --- sound/soc/samsung/i2s.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sound/soc/samsung/i2s.c b/sound/soc/samsung/i2s.c index 9d51347..7f98ee6 100644 --- a/sound/soc/samsung/i2s.c +++ b/sound/soc/samsung/i2s.c @@ -1239,6 +1239,8 @@ static int samsung_i2s_probe(struct platform_device *pdev) ret = -ENOMEM; goto err; } + + sec_dai->variant_regs = pri_dai->variant_regs; sec_dai->dma_playback.dma_addr = regs_base + I2STXDS; sec_dai->dma_playback.ch_name = "tx-sec"; -- cgit v1.1 From 75945896a2f4a7ebfc3402443f99ac32f629ee96 Mon Sep 17 00:00:00 2001 From: Bard Liao Date: Tue, 9 Dec 2014 10:14:45 +0800 Subject: ASoC: rt5645: Fix potential crash in jd function If no one defined the rt5645->pdata.hp_det_gpio in coreboot/bios. It will cause kernel to reboot because rt5645->pdata.hp_det_gpio is 0. So it is worth to add a check in rt5645_jack_detect. Signed-off-by: Bard Liao Signed-off-by: Fang, Yang A Signed-off-by: Mark Brown --- sound/soc/codecs/rt5645.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sound/soc/codecs/rt5645.c b/sound/soc/codecs/rt5645.c index d16331e..c901ef6 100644 --- a/sound/soc/codecs/rt5645.c +++ b/sound/soc/codecs/rt5645.c @@ -2113,6 +2113,10 @@ static int rt5645_jack_detect(struct snd_soc_codec *codec, int gpio_state, jack_type = 0; unsigned int val; + if (!gpio_is_valid(rt5645->pdata.hp_det_gpio)) { + dev_err(codec->dev, "invalid gpio\n"); + return -EINVAL; + } gpio_state = gpio_get_value(rt5645->pdata.hp_det_gpio); dev_dbg(codec->dev, "gpio = %d(%d)\n", rt5645->pdata.hp_det_gpio, -- cgit v1.1 From 359ff7ffafa78dd401a1ca0019ba2fe35ff377cc Mon Sep 17 00:00:00 2001 From: Ben Zhang Date: Wed, 10 Dec 2014 20:15:25 -0800 Subject: ASoC: rt5677: add REGMAP_I2C and REGMAP_IRQ dependency The codec driver uses regmap to do i2c read/write. The codec driver started to use REGMAP_IRQ since: 5e3363ad1b7b2e1f197a3f56b01e21cb155ad454 ASoC: rt5677: add GPIO IRQ support Signed-off-by: Ben Zhang Signed-off-by: Mark Brown --- sound/soc/codecs/Kconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sound/soc/codecs/Kconfig b/sound/soc/codecs/Kconfig index 883c577..8349f98 100644 --- a/sound/soc/codecs/Kconfig +++ b/sound/soc/codecs/Kconfig @@ -520,6 +520,8 @@ config SND_SOC_RT5670 config SND_SOC_RT5677 tristate + select REGMAP_I2C + select REGMAP_IRQ config SND_SOC_RT5677_SPI tristate -- cgit v1.1 From 0d3aba30b755fe9ccaf390f0e71f6fb9fd55bd87 Mon Sep 17 00:00:00 2001 From: Dan Carpenter Date: Fri, 12 Dec 2014 22:28:10 +0300 Subject: ALSA: oxfw: fix detect_loud_models() return value This code causes a static checker warning: sound/firewire/oxfw/oxfw.c:46 detect_loud_models() warn: signedness bug returning '(-2)' The detect_loud_models() function should return false on falure, so that we don't try to set up the loud code for hardware that doesn't support it. Signed-off-by: Dan Carpenter Reviewed-by: Takashi Sakamoto Signed-off-by: Takashi Iwai --- sound/firewire/oxfw/oxfw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/firewire/oxfw/oxfw.c b/sound/firewire/oxfw/oxfw.c index cf1d0b5..60e5cad 100644 --- a/sound/firewire/oxfw/oxfw.c +++ b/sound/firewire/oxfw/oxfw.c @@ -43,7 +43,7 @@ static bool detect_loud_models(struct fw_unit *unit) err = fw_csr_string(unit->directory, CSR_MODEL, model, sizeof(model)); if (err < 0) - return err; + return false; for (i = 0; i < ARRAY_SIZE(models); i++) { if (strcmp(models[i], model) == 0) -- cgit v1.1 From 5580ba7bf61a6047a8b95459a9ed893f01947737 Mon Sep 17 00:00:00 2001 From: Dan Carpenter Date: Fri, 12 Dec 2014 22:27:03 +0300 Subject: ALSA: oxfw: some signedness bugs This code tends to use unsigned variables by default and it causes signedness bugs when we use negative variables for error handling. The "i" and "j" variables are used to iterated over small positive values and so they should be type "int". The "len" variable doesn't *need* to be signed but it should be signed to make the code easier to read and audit. Signed-off-by: Dan Carpenter Reviewed-by: Takashi Sakamoto Signed-off-by: Takashi Iwai --- sound/firewire/oxfw/oxfw-pcm.c | 6 +++--- sound/firewire/oxfw/oxfw-proc.c | 2 +- sound/firewire/oxfw/oxfw-stream.c | 3 ++- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/sound/firewire/oxfw/oxfw-pcm.c b/sound/firewire/oxfw/oxfw-pcm.c index 9bc556b..67ade07 100644 --- a/sound/firewire/oxfw/oxfw-pcm.c +++ b/sound/firewire/oxfw/oxfw-pcm.c @@ -19,7 +19,7 @@ static int hw_rule_rate(struct snd_pcm_hw_params *params, .min = UINT_MAX, .max = 0, .integer = 1 }; struct snd_oxfw_stream_formation formation; - unsigned int i, err; + int i, err; for (i = 0; i < SND_OXFW_STREAM_FORMAT_ENTRIES; i++) { if (formats[i] == NULL) @@ -47,7 +47,7 @@ static int hw_rule_channels(struct snd_pcm_hw_params *params, const struct snd_interval *r = hw_param_interval_c(params, SNDRV_PCM_HW_PARAM_RATE); struct snd_oxfw_stream_formation formation; - unsigned int i, j, err; + int i, j, err; unsigned int count, list[SND_OXFW_STREAM_FORMAT_ENTRIES] = {0}; count = 0; @@ -80,7 +80,7 @@ static int hw_rule_channels(struct snd_pcm_hw_params *params, static void limit_channels_and_rates(struct snd_pcm_hardware *hw, u8 **formats) { struct snd_oxfw_stream_formation formation; - unsigned int i, err; + int i, err; hw->channels_min = UINT_MAX; hw->channels_max = 0; diff --git a/sound/firewire/oxfw/oxfw-proc.c b/sound/firewire/oxfw/oxfw-proc.c index 604808e..8ba4f9f 100644 --- a/sound/firewire/oxfw/oxfw-proc.c +++ b/sound/firewire/oxfw/oxfw-proc.c @@ -15,7 +15,7 @@ static void proc_read_formation(struct snd_info_entry *entry, struct snd_oxfw_stream_formation formation, curr; u8 *format; char flag; - unsigned int i, err; + int i, err; /* Show input. */ err = snd_oxfw_stream_get_current_formation(oxfw, diff --git a/sound/firewire/oxfw/oxfw-stream.c b/sound/firewire/oxfw/oxfw-stream.c index b77cf80..bda845a 100644 --- a/sound/firewire/oxfw/oxfw-stream.c +++ b/sound/firewire/oxfw/oxfw-stream.c @@ -61,7 +61,8 @@ static int set_stream_format(struct snd_oxfw *oxfw, struct amdtp_stream *s, u8 **formats; struct snd_oxfw_stream_formation formation; enum avc_general_plug_dir dir; - unsigned int i, err, len; + unsigned int len; + int i, err; if (s == &oxfw->tx_stream) { formats = oxfw->tx_stream_formats; -- cgit v1.1 From 99fcb3778b0ec12a8fa8b58435d75e9203bb430d Mon Sep 17 00:00:00 2001 From: Libin Yang Date: Mon, 15 Dec 2014 12:49:42 +0800 Subject: ALSA: hda - add codec ID for Skylake display audio codec This patch adds codec ID (0x80862809) and module alias for Skylake display codec. Signed-off-by: Libin Yang Signed-off-by: Takashi Iwai --- sound/pci/hda/patch_hdmi.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c index 9dc9cf8..95129c2 100644 --- a/sound/pci/hda/patch_hdmi.c +++ b/sound/pci/hda/patch_hdmi.c @@ -3365,6 +3365,7 @@ static const struct hda_codec_preset snd_hda_preset_hdmi[] = { { .id = 0x80862806, .name = "PantherPoint HDMI", .patch = patch_generic_hdmi }, { .id = 0x80862807, .name = "Haswell HDMI", .patch = patch_generic_hdmi }, { .id = 0x80862808, .name = "Broadwell HDMI", .patch = patch_generic_hdmi }, +{ .id = 0x80862809, .name = "Skylake HDMI", .patch = patch_generic_hdmi }, { .id = 0x80862880, .name = "CedarTrail HDMI", .patch = patch_generic_hdmi }, { .id = 0x80862882, .name = "Valleyview2 HDMI", .patch = patch_generic_hdmi }, { .id = 0x80862883, .name = "Braswell HDMI", .patch = patch_generic_hdmi }, @@ -3425,6 +3426,7 @@ MODULE_ALIAS("snd-hda-codec-id:80862805"); MODULE_ALIAS("snd-hda-codec-id:80862806"); MODULE_ALIAS("snd-hda-codec-id:80862807"); MODULE_ALIAS("snd-hda-codec-id:80862808"); +MODULE_ALIAS("snd-hda-codec-id:80862809"); MODULE_ALIAS("snd-hda-codec-id:80862880"); MODULE_ALIAS("snd-hda-codec-id:80862882"); MODULE_ALIAS("snd-hda-codec-id:80862883"); -- cgit v1.1 From c10b11f6cd1319ba1d8133cf416e61181650f368 Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Mon, 15 Dec 2014 13:39:10 +0100 Subject: ALSA: hda - Fix typos in snd_hda_get_int_hint() kerneldoc comments Signed-off-by: Takashi Iwai --- sound/pci/hda/hda_sysfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/pci/hda/hda_sysfs.c b/sound/pci/hda/hda_sysfs.c index bef7215..ccc962a 100644 --- a/sound/pci/hda/hda_sysfs.c +++ b/sound/pci/hda/hda_sysfs.c @@ -468,7 +468,7 @@ int snd_hda_get_bool_hint(struct hda_codec *codec, const char *key) EXPORT_SYMBOL_GPL(snd_hda_get_bool_hint); /** - * snd_hda_get_bool_hint - Get a boolean hint value + * snd_hda_get_int_hint - Get an integer hint value * @codec: the HDA codec * @key: the hint key string * @valp: pointer to store a value -- cgit v1.1 From 82d04e1088769c769c87ffa1d4df5e4a228f637a Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Mon, 15 Dec 2014 13:40:42 +0100 Subject: ALSA: hda - Create capture source ctls when stereo mix input is added When the stereo mix input is explicitly enabled via a user hint, the driver should create always a capture source enum ctl and disable the auto-mic switch. Otherwise the behavior gets confused. For doing it, this patch just sets spec->suppress_auto_mic flag appropriately. Signed-off-by: Takashi Iwai --- sound/pci/hda/hda_generic.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c index 63b69f7..293af6b 100644 --- a/sound/pci/hda/hda_generic.c +++ b/sound/pci/hda/hda_generic.c @@ -3224,6 +3224,8 @@ static int create_input_ctls(struct hda_codec *codec) "Stereo Mix", 0); if (err < 0) return err; + else + spec->suppress_auto_mic = 1; } return 0; -- cgit v1.1 From 74f14b36838a6f5406ff1a14fcfda935c190476c Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Mon, 15 Dec 2014 13:43:59 +0100 Subject: ALSA: hda - Make add_stereo_mix_input flag tristate ... for distinguishing whether it's explicitly enabled via a user hint or enabled by a driver as a fallback. Now the former case corresponds to HDA_HINT_STEREO_MIX_ENABLE while the latter to HDA_HINT_STEREO_MIX_AUTO. Signed-off-by: Takashi Iwai --- sound/pci/hda/hda_generic.c | 8 +++----- sound/pci/hda/hda_generic.h | 9 ++++++++- sound/pci/hda/patch_analog.c | 3 ++- sound/pci/hda/patch_conexant.c | 4 ++-- sound/pci/hda/patch_via.c | 2 +- 5 files changed, 16 insertions(+), 10 deletions(-) diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c index 293af6b..b680b4e 100644 --- a/sound/pci/hda/hda_generic.c +++ b/sound/pci/hda/hda_generic.c @@ -3218,8 +3218,7 @@ static int create_input_ctls(struct hda_codec *codec) } /* add stereo mix when explicitly enabled via hint */ - if (mixer && spec->add_stereo_mix_input && - snd_hda_get_bool_hint(codec, "add_stereo_mix_input") > 0) { + if (mixer && spec->add_stereo_mix_input == HDA_HINT_STEREO_MIX_ENABLE) { err = parse_capture_source(codec, mixer, CFG_IDX_MIX, num_adcs, "Stereo Mix", 0); if (err < 0) @@ -4544,9 +4543,8 @@ int snd_hda_gen_parse_auto_config(struct hda_codec *codec, /* add stereo mix if available and not enabled yet */ if (!spec->auto_mic && spec->mixer_nid && - spec->add_stereo_mix_input && - spec->input_mux.num_items > 1 && - snd_hda_get_bool_hint(codec, "add_stereo_mix_input") < 0) { + spec->add_stereo_mix_input == HDA_HINT_STEREO_MIX_AUTO && + spec->input_mux.num_items > 1) { err = parse_capture_source(codec, spec->mixer_nid, CFG_IDX_MIX, spec->num_all_adcs, "Stereo Mix", 0); diff --git a/sound/pci/hda/hda_generic.h b/sound/pci/hda/hda_generic.h index 61dd515..3d85266 100644 --- a/sound/pci/hda/hda_generic.h +++ b/sound/pci/hda/hda_generic.h @@ -222,7 +222,7 @@ struct hda_gen_spec { unsigned int vmaster_mute_enum:1; /* add vmaster mute mode enum */ unsigned int indep_hp:1; /* independent HP supported */ unsigned int prefer_hp_amp:1; /* enable HP amp for speaker if any */ - unsigned int add_stereo_mix_input:1; /* add aamix as a capture src */ + unsigned int add_stereo_mix_input:2; /* add aamix as a capture src */ unsigned int add_jack_modes:1; /* add i/o jack mode enum ctls */ unsigned int power_down_unused:1; /* power down unused widgets */ unsigned int dac_min_mute:1; /* minimal = mute for DACs */ @@ -291,6 +291,13 @@ struct hda_gen_spec { struct hda_jack_callback *cb); }; +/* values for add_stereo_mix_input flag */ +enum { + HDA_HINT_STEREO_MIX_DISABLE, /* No stereo mix input */ + HDA_HINT_STEREO_MIX_ENABLE, /* Add stereo mix input */ + HDA_HINT_STEREO_MIX_AUTO, /* Add only if auto-mic is disabled */ +}; + int snd_hda_gen_spec_init(struct hda_gen_spec *spec); int snd_hda_gen_init(struct hda_codec *codec); diff --git a/sound/pci/hda/patch_analog.c b/sound/pci/hda/patch_analog.c index c81b715..eb54da7 100644 --- a/sound/pci/hda/patch_analog.c +++ b/sound/pci/hda/patch_analog.c @@ -195,7 +195,8 @@ static int ad198x_parse_auto_config(struct hda_codec *codec, bool indep_hp) codec->no_sticky_stream = 1; spec->gen.indep_hp = indep_hp; - spec->gen.add_stereo_mix_input = 1; + if (!spec->gen.add_stereo_mix_input) + spec->gen.add_stereo_mix_input = HDA_HINT_STEREO_MIX_AUTO; err = snd_hda_parse_pin_defcfg(codec, cfg, NULL, 0); if (err < 0) diff --git a/sound/pci/hda/patch_conexant.c b/sound/pci/hda/patch_conexant.c index e9ebc7b..fd3ed18 100644 --- a/sound/pci/hda/patch_conexant.c +++ b/sound/pci/hda/patch_conexant.c @@ -855,14 +855,14 @@ static int patch_conexant_auto(struct hda_codec *codec) case 0x14f15045: codec->single_adc_amp = 1; spec->gen.mixer_nid = 0x17; - spec->gen.add_stereo_mix_input = 1; + spec->gen.add_stereo_mix_input = HDA_HINT_STEREO_MIX_AUTO; snd_hda_pick_fixup(codec, cxt5045_fixup_models, cxt5045_fixups, cxt_fixups); break; case 0x14f15047: codec->pin_amp_workaround = 1; spec->gen.mixer_nid = 0x19; - spec->gen.add_stereo_mix_input = 1; + spec->gen.add_stereo_mix_input = HDA_HINT_STEREO_MIX_AUTO; snd_hda_pick_fixup(codec, cxt5047_fixup_models, cxt5047_fixups, cxt_fixups); break; diff --git a/sound/pci/hda/patch_via.c b/sound/pci/hda/patch_via.c index 6c206b6..3de6d3d 100644 --- a/sound/pci/hda/patch_via.c +++ b/sound/pci/hda/patch_via.c @@ -137,7 +137,7 @@ static struct via_spec *via_new_spec(struct hda_codec *codec) spec->gen.indep_hp = 1; spec->gen.keep_eapd_on = 1; spec->gen.pcm_playback_hook = via_playback_pcm_hook; - spec->gen.add_stereo_mix_input = 1; + spec->gen.add_stereo_mix_input = HDA_HINT_STEREO_MIX_AUTO; return spec; } -- cgit v1.1 From f5d40b400fe2de5f9dc3d41681cc59b2b7c28f8c Mon Sep 17 00:00:00 2001 From: Wei Yongjun Date: Tue, 9 Dec 2014 21:14:37 +0800 Subject: ASoC: Intel: fix return value check in sst_acpi_probe() In case of error, the function platform_device_register_data() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Signed-off-by: Wei Yongjun Signed-off-by: Mark Brown --- sound/soc/intel/sst/sst_acpi.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sound/soc/intel/sst/sst_acpi.c b/sound/soc/intel/sst/sst_acpi.c index 31124aa..f59972a 100644 --- a/sound/soc/intel/sst/sst_acpi.c +++ b/sound/soc/intel/sst/sst_acpi.c @@ -277,16 +277,16 @@ int sst_acpi_probe(struct platform_device *pdev) dev_dbg(dev, "ACPI device id: %x\n", dev_id); plat_dev = platform_device_register_data(dev, mach->pdata->platform, -1, NULL, 0); - if (plat_dev == NULL) { + if (IS_ERR(plat_dev)) { dev_err(dev, "Failed to create machine device: %s\n", mach->pdata->platform); - return -ENODEV; + return PTR_ERR(plat_dev); } /* Create platform device for sst machine driver */ mdev = platform_device_register_data(dev, mach->machine, -1, NULL, 0); - if (mdev == NULL) { + if (IS_ERR(mdev)) { dev_err(dev, "Failed to create machine device: %s\n", mach->machine); - return -ENODEV; + return PTR_ERR(mdev); } ret = sst_alloc_drv_context(&ctx, dev, dev_id); -- cgit v1.1 From 432ac1a2c028acb289d90f918e3a7b79e4ac8c07 Mon Sep 17 00:00:00 2001 From: Libin Yang Date: Tue, 16 Dec 2014 13:17:34 +0800 Subject: ALSA: hda/hdmi - apply Haswell fix-ups to Skylake display codec Skylake and Haswell have the same behavior on display audio. So this patch applys Haswell fix-ups to Skylake. Signed-off-by: Libin Yang Signed-off-by: Takashi Iwai --- sound/pci/hda/patch_hdmi.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c index 95129c2..5f13d2d 100644 --- a/sound/pci/hda/patch_hdmi.c +++ b/sound/pci/hda/patch_hdmi.c @@ -47,7 +47,9 @@ MODULE_PARM_DESC(static_hdmi_pcm, "Don't restrict PCM parameters per ELD info"); #define is_haswell(codec) ((codec)->vendor_id == 0x80862807) #define is_broadwell(codec) ((codec)->vendor_id == 0x80862808) -#define is_haswell_plus(codec) (is_haswell(codec) || is_broadwell(codec)) +#define is_skylake(codec) ((codec)->vendor_id == 0x80862809) +#define is_haswell_plus(codec) (is_haswell(codec) || is_broadwell(codec) \ + || is_skylake(codec)) #define is_valleyview(codec) ((codec)->vendor_id == 0x80862882) #define is_cherryview(codec) ((codec)->vendor_id == 0x80862883) -- cgit v1.1 From de5f644e3ca71afc06377d137375c56e250f8cb3 Mon Sep 17 00:00:00 2001 From: Kevin Strasser Date: Mon, 15 Dec 2014 16:15:04 -0800 Subject: ASoC: Intel: fix possible acpi enumeration panic A crash can occur on some platforms where adsp is enumerated but codec is not matched. Define codec_id as a pointer intead of an array so that it gets initialized to NULL for the terminating element of sst_acpi_bytcr[] and sst_acpi_chv[]. Signed-off-by: Kevin Strasser Signed-off-by: Mark Brown --- sound/soc/intel/sst/sst_acpi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/intel/sst/sst_acpi.c b/sound/soc/intel/sst/sst_acpi.c index f59972a..3abc29e 100644 --- a/sound/soc/intel/sst/sst_acpi.c +++ b/sound/soc/intel/sst/sst_acpi.c @@ -43,7 +43,7 @@ #include "sst.h" struct sst_machines { - char codec_id[32]; + char *codec_id; char board[32]; char machine[32]; void (*machine_quirk)(void); -- cgit v1.1 From 8b72415d8aa8bb1904c61926bd0701447ce44bee Mon Sep 17 00:00:00 2001 From: Kailang Yang Date: Wed, 17 Dec 2014 17:08:59 +0800 Subject: ALSA: hda/realtek - Add new Dell desktop for ALC3234 headset mode New Dell desktop needs to support headset mode for ALC3234. Signed-off-by: Kailang Yang Cc: Signed-off-by: Takashi Iwai --- sound/pci/hda/patch_realtek.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index a722067..8e1843e 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -4829,6 +4829,7 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { SND_PCI_QUIRK(0x1028, 0x0638, "Dell Inspiron 5439", ALC290_FIXUP_MONO_SPEAKERS_HSJACK), SND_PCI_QUIRK(0x1028, 0x064a, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), SND_PCI_QUIRK(0x1028, 0x064b, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), + SND_PCI_QUIRK(0x1028, 0x06c7, "Dell", ALC255_FIXUP_DELL1_MIC_NO_PRESENCE), SND_PCI_QUIRK(0x1028, 0x06d9, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), SND_PCI_QUIRK(0x1028, 0x06da, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), SND_PCI_QUIRK(0x1028, 0x164a, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), -- cgit v1.1 From 4344aec84bd84b58a01347f0db7693f73fb6473d Mon Sep 17 00:00:00 2001 From: Kailang Yang Date: Wed, 17 Dec 2014 17:39:05 +0800 Subject: ALSA: hda/realtek - New codec support for ALC256 Add new support for ALC256 codec. Signed-off-by: Kailang Yang Cc: Signed-off-by: Takashi Iwai --- sound/pci/hda/patch_realtek.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index 8e1843e..24db152 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -321,6 +321,7 @@ static void alc_fill_eapd_coef(struct hda_codec *codec) break; case 0x10ec0233: case 0x10ec0255: + case 0x10ec0256: case 0x10ec0282: case 0x10ec0283: case 0x10ec0286: @@ -2660,6 +2661,7 @@ enum { ALC269_TYPE_ALC285, ALC269_TYPE_ALC286, ALC269_TYPE_ALC255, + ALC269_TYPE_ALC256, }; /* @@ -2687,6 +2689,7 @@ static int alc269_parse_auto_config(struct hda_codec *codec) case ALC269_TYPE_ALC283: case ALC269_TYPE_ALC286: case ALC269_TYPE_ALC255: + case ALC269_TYPE_ALC256: ssids = alc269_ssids; break; default: @@ -5421,6 +5424,9 @@ static int patch_alc269(struct hda_codec *codec) case 0x10ec0255: spec->codec_variant = ALC269_TYPE_ALC255; break; + case 0x10ec0256: + spec->codec_variant = ALC269_TYPE_ALC256; + break; } if (snd_hda_codec_read(codec, 0x51, 0, AC_VERB_PARAMETERS, 0) == 0x10ec5505) { @@ -6342,6 +6348,7 @@ static const struct hda_codec_preset snd_hda_preset_realtek[] = { { .id = 0x10ec0233, .name = "ALC233", .patch = patch_alc269 }, { .id = 0x10ec0235, .name = "ALC233", .patch = patch_alc269 }, { .id = 0x10ec0255, .name = "ALC255", .patch = patch_alc269 }, + { .id = 0x10ec0256, .name = "ALC256", .patch = patch_alc269 }, { .id = 0x10ec0260, .name = "ALC260", .patch = patch_alc260 }, { .id = 0x10ec0262, .name = "ALC262", .patch = patch_alc262 }, { .id = 0x10ec0267, .name = "ALC267", .patch = patch_alc268 }, -- cgit v1.1 From 38f74d5b82b329dff5bdf8626e8776a36a1835da Mon Sep 17 00:00:00 2001 From: Jurgen Kramer Date: Wed, 17 Dec 2014 17:45:20 +0100 Subject: ALSA: usb-audio: add native DSD support for Matrix Audio DACs This patch adds native DSD support for two XMOS based DACs from Matrix Audio: - X-Sabre - Mini-i Pro Signed-off-by: Jurgen Kramer Signed-off-by: Takashi Iwai --- sound/usb/quirks.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sound/usb/quirks.c b/sound/usb/quirks.c index 4dbfb3d..a739841 100644 --- a/sound/usb/quirks.c +++ b/sound/usb/quirks.c @@ -1245,8 +1245,9 @@ u64 snd_usb_interface_dsd_format_quirks(struct snd_usb_audio *chip, /* XMOS based USB DACs */ switch (chip->usb_id) { - /* iFi Audio micro/nano iDSD */ - case USB_ID(0x20b1, 0x3008): + case USB_ID(0x20b1, 0x3008): /* iFi Audio micro/nano iDSD */ + case USB_ID(0x20b1, 0x2008): /* Matrix Audio X-Sabre */ + case USB_ID(0x20b1, 0x300a): /* Matrix Audio Mini-i Pro */ if (fp->altsetting == 2) return SNDRV_PCM_FMTBIT_DSD_U32_BE; break; -- cgit v1.1 From 7327643ba1586546a082a0f3ffbd2095ccce089e Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Mon, 15 Dec 2014 13:47:25 +0100 Subject: ALSA: hda - Add quirk for Packard Bell EasyNote MX65 Packard Bell EasyNote MX65 with AD1986A codec needs a few fixups, namely, the pin config overrides to set only the known I/O pins and the EAPD has to be turned on. In addition, add stereo mix input forcibly for avoiding the weird KDE behavior by this update. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=88251 Signed-off-by: Takashi Iwai --- sound/pci/hda/patch_analog.c | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/sound/pci/hda/patch_analog.c b/sound/pci/hda/patch_analog.c index eb54da7..a9d78e2 100644 --- a/sound/pci/hda/patch_analog.c +++ b/sound/pci/hda/patch_analog.c @@ -257,6 +257,18 @@ static void ad1986a_fixup_eapd(struct hda_codec *codec, } } +/* enable stereo-mix input for avoiding regression on KDE (bko#88251) */ +static void ad1986a_fixup_eapd_mix_in(struct hda_codec *codec, + const struct hda_fixup *fix, int action) +{ + struct ad198x_spec *spec = codec->spec; + + if (action == HDA_FIXUP_ACT_PRE_PROBE) { + ad1986a_fixup_eapd(codec, fix, action); + spec->gen.add_stereo_mix_input = HDA_HINT_STEREO_MIX_ENABLE; + } +} + enum { AD1986A_FIXUP_INV_JACK_DETECT, AD1986A_FIXUP_ULTRA, @@ -265,6 +277,8 @@ enum { AD1986A_FIXUP_LAPTOP, AD1986A_FIXUP_LAPTOP_IMIC, AD1986A_FIXUP_EAPD, + AD1986A_FIXUP_EAPD_MIX_IN, + AD1986A_FIXUP_EASYNOTE, }; static const struct hda_fixup ad1986a_fixups[] = { @@ -329,6 +343,30 @@ static const struct hda_fixup ad1986a_fixups[] = { .type = HDA_FIXUP_FUNC, .v.func = ad1986a_fixup_eapd, }, + [AD1986A_FIXUP_EAPD_MIX_IN] = { + .type = HDA_FIXUP_FUNC, + .v.func = ad1986a_fixup_eapd_mix_in, + }, + [AD1986A_FIXUP_EASYNOTE] = { + .type = HDA_FIXUP_PINS, + .v.pins = (const struct hda_pintbl[]) { + { 0x1a, 0x0421402f }, /* headphone */ + { 0x1b, 0x90170110 }, /* speaker */ + { 0x1c, 0x411111f0 }, /* N/A */ + { 0x1d, 0x90a70130 }, /* int mic */ + { 0x1e, 0x411111f0 }, /* N/A */ + { 0x1f, 0x04a19040 }, /* mic */ + { 0x20, 0x411111f0 }, /* N/A */ + { 0x21, 0x411111f0 }, /* N/A */ + { 0x22, 0x411111f0 }, /* N/A */ + { 0x23, 0x411111f0 }, /* N/A */ + { 0x24, 0x411111f0 }, /* N/A */ + { 0x25, 0x411111f0 }, /* N/A */ + {} + }, + .chained = true, + .chain_id = AD1986A_FIXUP_EAPD_MIX_IN, + }, }; static const struct snd_pci_quirk ad1986a_fixup_tbl[] = { @@ -342,6 +380,7 @@ static const struct snd_pci_quirk ad1986a_fixup_tbl[] = { SND_PCI_QUIRK(0x144d, 0xc01e, "FSC V2060", AD1986A_FIXUP_LAPTOP), SND_PCI_QUIRK_MASK(0x144d, 0xff00, 0xc000, "Samsung", AD1986A_FIXUP_SAMSUNG), SND_PCI_QUIRK(0x144d, 0xc027, "Samsung Q1", AD1986A_FIXUP_ULTRA), + SND_PCI_QUIRK(0x1631, 0xc022, "PackardBell EasyNote MX65", AD1986A_FIXUP_EASYNOTE), SND_PCI_QUIRK(0x17aa, 0x2066, "Lenovo N100", AD1986A_FIXUP_INV_JACK_DETECT), SND_PCI_QUIRK(0x17aa, 0x1011, "Lenovo M55", AD1986A_FIXUP_3STACK), SND_PCI_QUIRK(0x17aa, 0x1017, "Lenovo A60", AD1986A_FIXUP_3STACK), -- cgit v1.1 From c99b9e853d3951fe521cc7b2357eec93d5c16246 Mon Sep 17 00:00:00 2001 From: Chris J Arges Date: Wed, 17 Dec 2014 16:09:35 -0600 Subject: ALSA: usb-audio: Fix Scarlett 6i6 initialization typo The num_controls field was incorrectly set to 0 causing 6i6 to not be initialized. Set this to 9. Reported-and-tested-by: Mark Roberts Signed-off-by: Chris J Arges Signed-off-by: Takashi Iwai --- sound/usb/mixer_scarlett.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/usb/mixer_scarlett.c b/sound/usb/mixer_scarlett.c index 9109652..7438e7c 100644 --- a/sound/usb/mixer_scarlett.c +++ b/sound/usb/mixer_scarlett.c @@ -655,7 +655,7 @@ static struct scarlett_device_info s6i6_info = { .names = NULL }, - .num_controls = 0, + .num_controls = 9, .controls = { { .num = 0, .type = SCARLETT_OUTPUTS, .name = "Monitor" }, { .num = 1, .type = SCARLETT_OUTPUTS, .name = "Headphone" }, -- cgit v1.1 From 43986431246fdaa534822b9cbe9dafed94eab004 Mon Sep 17 00:00:00 2001 From: Eliot Blennerhassett Date: Thu, 18 Dec 2014 17:57:13 +1300 Subject: ALSA: asihpi: relax firmware version check Some products firmware is no longer being updated e.g. dsp5000, dsp8700 but it should continue to work with updated HPI versions. Avoid regression by allowing this firmware to be loaded as long as major version is the same. Warn about mismatching versions, as matching versions are preferred. Signed-off-by: Eliot Blennerhassett Signed-off-by: Takashi Iwai --- sound/pci/asihpi/hpidspcd.c | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/sound/pci/asihpi/hpidspcd.c b/sound/pci/asihpi/hpidspcd.c index ac91637..3603c24 100644 --- a/sound/pci/asihpi/hpidspcd.c +++ b/sound/pci/asihpi/hpidspcd.c @@ -1,8 +1,9 @@ -/***********************************************************************/ -/** +/*********************************************************************** AudioScience HPI driver - Copyright (C) 1997-2011 AudioScience Inc. + Functions for reading DSP code using hotplug firmware loader + + Copyright (C) 1997-2014 AudioScience Inc. This program is free software; you can redistribute it and/or modify it under the terms of version 2 of the GNU General Public License as @@ -17,11 +18,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -\file -Functions for reading DSP code using -hotplug firmware loader from individual dsp code files -*/ -/***********************************************************************/ +***********************************************************************/ #define SOURCEFILE_NAME "hpidspcd.c" #include "hpidspcd.h" #include "hpidebug.h" @@ -68,17 +65,18 @@ short hpi_dsp_code_open(u32 adapter, void *os_data, struct dsp_code *dsp_code, goto error2; } - if ((header.version >> 9) != (HPI_VER >> 9)) { - /* Consider even and subsequent odd minor versions to be compatible */ - dev_err(&dev->dev, "Incompatible firmware version DSP image %X != Driver %X\n", + if (HPI_VER_MAJOR(header.version) != HPI_VER_MAJOR(HPI_VER)) { + /* Major version change probably means Host-DSP protocol change */ + dev_err(&dev->dev, + "Incompatible firmware version DSP image %X != Driver %X\n", header.version, HPI_VER); goto error2; } if (header.version != HPI_VER) { - dev_info(&dev->dev, - "Firmware: release version mismatch DSP image %X != Driver %X\n", - header.version, HPI_VER); + dev_warn(&dev->dev, + "Firmware version mismatch: DSP image %X != Driver %X\n", + header.version, HPI_VER); } HPI_DEBUG_LOG(DEBUG, "dsp code %s opened\n", fw_name); -- cgit v1.1 From 17d4de4ca3cdeb2a7c66e39903b730aea6dcc515 Mon Sep 17 00:00:00 2001 From: Eliot Blennerhassett Date: Thu, 18 Dec 2014 17:57:14 +1300 Subject: ALSA: asihpi: increase tuner pad cache size Increase size allocated for PAD (programme associated data) control. This is used by newer tuner products. Signed-off-by: Eliot Blennerhassett Signed-off-by: Takashi Iwai --- sound/pci/asihpi/hpi_internal.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sound/pci/asihpi/hpi_internal.h b/sound/pci/asihpi/hpi_internal.h index 48380ce..aeea679 100644 --- a/sound/pci/asihpi/hpi_internal.h +++ b/sound/pci/asihpi/hpi_internal.h @@ -1367,9 +1367,9 @@ struct hpi_control_cache_single { struct hpi_control_cache_pad { struct hpi_control_cache_info i; u32 field_valid_flags; - u8 c_channel[8]; - u8 c_artist[40]; - u8 c_title[40]; + u8 c_channel[40]; + u8 c_artist[100]; + u8 c_title[100]; u8 c_comment[200]; u32 pTY; u32 pI; -- cgit v1.1 From fd112f1cf6e10da96ccef9b22c1877114f4e4aad Mon Sep 17 00:00:00 2001 From: Eliot Blennerhassett Date: Thu, 18 Dec 2014 17:57:15 +1300 Subject: ALSA: asihpi: update to HPI version 4.14 This corresponds with updated asihpi firmware in alsa-firmware repo Signed-off-by: Eliot Blennerhassett Signed-off-by: Takashi Iwai --- sound/pci/asihpi/hpi_version.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sound/pci/asihpi/hpi_version.h b/sound/pci/asihpi/hpi_version.h index e9146e5..6623ab1 100644 --- a/sound/pci/asihpi/hpi_version.h +++ b/sound/pci/asihpi/hpi_version.h @@ -11,13 +11,13 @@ Production releases have even minor version. /* Use single digits for versions less that 10 to avoid octal. */ /* *** HPI_VER is the only edit required to update version *** */ /** HPI version */ -#define HPI_VER HPI_VERSION_CONSTRUCTOR(4, 10, 1) +#define HPI_VER HPI_VERSION_CONSTRUCTOR(4, 14, 3) /** HPI version string in dotted decimal format */ -#define HPI_VER_STRING "4.10.01" +#define HPI_VER_STRING "4.14.03" /** Library version as documented in hpi-api-versions.txt */ -#define HPI_LIB_VER HPI_VERSION_CONSTRUCTOR(10, 2, 0) +#define HPI_LIB_VER HPI_VERSION_CONSTRUCTOR(10, 4, 0) /** Construct hpi version number from major, minor, release numbers */ #define HPI_VERSION_CONSTRUCTOR(maj, min, r) ((maj << 16) + (min << 8) + r) -- cgit v1.1 From 506b62c33a7444b91a93bf2da772f4c7e6656410 Mon Sep 17 00:00:00 2001 From: Kailang Yang Date: Thu, 18 Dec 2014 17:07:44 +0800 Subject: ALSA: hda/realtek - New codec support for ALC298 Add new support for ALC298 codec. Signed-off-by: Kailang Yang Cc: Signed-off-by: Takashi Iwai --- sound/pci/hda/patch_realtek.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index 24db152..65f1f4e 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -326,6 +326,7 @@ static void alc_fill_eapd_coef(struct hda_codec *codec) case 0x10ec0283: case 0x10ec0286: case 0x10ec0288: + case 0x10ec0298: alc_update_coef_idx(codec, 0x10, 1<<9, 0); break; case 0x10ec0285: @@ -2660,6 +2661,7 @@ enum { ALC269_TYPE_ALC284, ALC269_TYPE_ALC285, ALC269_TYPE_ALC286, + ALC269_TYPE_ALC298, ALC269_TYPE_ALC255, ALC269_TYPE_ALC256, }; @@ -2688,6 +2690,7 @@ static int alc269_parse_auto_config(struct hda_codec *codec) case ALC269_TYPE_ALC282: case ALC269_TYPE_ALC283: case ALC269_TYPE_ALC286: + case ALC269_TYPE_ALC298: case ALC269_TYPE_ALC255: case ALC269_TYPE_ALC256: ssids = alc269_ssids; @@ -5421,6 +5424,9 @@ static int patch_alc269(struct hda_codec *codec) spec->codec_variant = ALC269_TYPE_ALC286; spec->shutup = alc286_shutup; break; + case 0x10ec0298: + spec->codec_variant = ALC269_TYPE_ALC298; + break; case 0x10ec0255: spec->codec_variant = ALC269_TYPE_ALC255; break; @@ -6368,6 +6374,7 @@ static const struct hda_codec_preset snd_hda_preset_realtek[] = { { .id = 0x10ec0290, .name = "ALC290", .patch = patch_alc269 }, { .id = 0x10ec0292, .name = "ALC292", .patch = patch_alc269 }, { .id = 0x10ec0293, .name = "ALC293", .patch = patch_alc269 }, + { .id = 0x10ec0298, .name = "ALC298", .patch = patch_alc269 }, { .id = 0x10ec0861, .rev = 0x100340, .name = "ALC660", .patch = patch_alc861 }, { .id = 0x10ec0660, .name = "ALC660-VD", .patch = patch_alc861vd }, -- cgit v1.1 From d70a1b9893f820fdbcdffac408c909c50f2e6b43 Mon Sep 17 00:00:00 2001 From: Jiri Jaburek Date: Thu, 18 Dec 2014 02:03:19 +0100 Subject: ALSA: usb-audio: extend KEF X300A FU 10 tweak to Arcam rPAC The Arcam rPAC seems to have the same problem - whenever anything (alsamixer, udevd, 3.9+ kernel from 60af3d037eb8c, ..) attempts to access mixer / control interface of the card, the firmware "locks up" the entire device, resulting in SNDRV_PCM_IOCTL_HW_PARAMS failed (-5): Input/output error from alsa-lib. Other operating systems can somehow read the mixer (there seems to be playback volume/mute), but any manipulation is ignored by the device (which has hardware volume controls). Cc: Signed-off-by: Jiri Jaburek Signed-off-by: Takashi Iwai --- sound/usb/mixer_maps.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/sound/usb/mixer_maps.c b/sound/usb/mixer_maps.c index 1994d41..b703cb3 100644 --- a/sound/usb/mixer_maps.c +++ b/sound/usb/mixer_maps.c @@ -333,8 +333,11 @@ static struct usbmix_name_map gamecom780_map[] = { {} }; -static const struct usbmix_name_map kef_x300a_map[] = { - { 10, NULL }, /* firmware locks up (?) when we try to access this FU */ +/* some (all?) SCMS USB3318 devices are affected by a firmware lock up + * when anything attempts to access FU 10 (control) + */ +static const struct usbmix_name_map scms_usb3318_map[] = { + { 10, NULL }, { 0 } }; @@ -434,8 +437,14 @@ static struct usbmix_ctl_map usbmix_ctl_maps[] = { .map = ebox44_map, }, { + /* KEF X300A */ .id = USB_ID(0x27ac, 0x1000), - .map = kef_x300a_map, + .map = scms_usb3318_map, + }, + { + /* Arcam rPAC */ + .id = USB_ID(0x25c4, 0x0003), + .map = scms_usb3318_map, }, { 0 } /* terminator */ }; -- cgit v1.1