Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'sound-4.13-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound

Pull sound fixes from Takashi Iwai:
"Three regression fixes that should be addressed before the final
release: a missing mutex call in OSS PCM emulation ioctl, ASoC rt5670
headset detection breakage, and a regression in simple-card parser
code"

* tag 'sound-4.13-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
ASoC: simple_card_utils: fix fallback when "label" property isn't present
ALSA: pcm: Fix power lock unbalance via OSS emulation
ASoC: rt5670: Fix GPIO headset detection regression

+17 -3
+5 -1
sound/core/pcm_native.c
··· 3064 3064 { 3065 3065 snd_pcm_uframes_t *frames = arg; 3066 3066 snd_pcm_sframes_t result; 3067 + int err; 3067 3068 3068 3069 switch (cmd) { 3069 3070 case SNDRV_PCM_IOCTL_FORWARD: ··· 3084 3083 case SNDRV_PCM_IOCTL_START: 3085 3084 return snd_pcm_start_lock_irq(substream); 3086 3085 case SNDRV_PCM_IOCTL_DRAIN: 3087 - return snd_pcm_drain(substream, NULL); 3086 + snd_power_lock(substream->pcm->card); 3087 + err = snd_pcm_drain(substream, NULL); 3088 + snd_power_unlock(substream->pcm->card); 3089 + return err; 3088 3090 case SNDRV_PCM_IOCTL_DROP: 3089 3091 return snd_pcm_drop(substream); 3090 3092 case SNDRV_PCM_IOCTL_DELAY:
+1 -1
sound/soc/codecs/rt5670.c
··· 567 567 568 568 rt5670->jack = jack; 569 569 rt5670->hp_gpio.gpiod_dev = codec->dev; 570 - rt5670->hp_gpio.name = "headphone detect"; 570 + rt5670->hp_gpio.name = "headset"; 571 571 rt5670->hp_gpio.report = SND_JACK_HEADSET | 572 572 SND_JACK_BTN_0 | SND_JACK_BTN_1 | SND_JACK_BTN_2; 573 573 rt5670->hp_gpio.debounce_time = 150;
+1 -1
sound/soc/generic/simple-card-utils.c
··· 132 132 133 133 /* Parse the card name from DT */ 134 134 ret = snd_soc_of_parse_card_name(card, "label"); 135 - if (ret < 0) { 135 + if (ret < 0 || !card->name) { 136 136 char prop[128]; 137 137 138 138 snprintf(prop, sizeof(prop), "%sname", prefix);
+10
sound/soc/intel/boards/cht_bsw_rt5672.c
··· 184 184 return 0; 185 185 } 186 186 187 + static const struct acpi_gpio_params headset_gpios = { 0, 0, false }; 188 + 189 + static const struct acpi_gpio_mapping cht_rt5672_gpios[] = { 190 + { "headset-gpios", &headset_gpios, 1 }, 191 + {}, 192 + }; 193 + 187 194 static int cht_codec_init(struct snd_soc_pcm_runtime *runtime) 188 195 { 189 196 int ret; 190 197 struct snd_soc_dai *codec_dai = runtime->codec_dai; 191 198 struct snd_soc_codec *codec = codec_dai->codec; 192 199 struct cht_mc_private *ctx = snd_soc_card_get_drvdata(runtime->card); 200 + 201 + if (devm_acpi_dev_add_driver_gpios(codec->dev, cht_rt5672_gpios)) 202 + dev_warn(runtime->dev, "Unable to add GPIO mapping table\n"); 193 203 194 204 /* TDM 4 slots 24 bit, set Rx & Tx bitmask to 4 active slots */ 195 205 ret = snd_soc_dai_set_tdm_slot(codec_dai, 0xF, 0xF, 4, 24);