ASoC: rt5670: Add quirk for Thinkpad 8 tablet
Subsystems (4)
PATCH v2 1/3 ASoC: rt5670: Add quirk for Thinkpad 8 tablet
The Thinkpad 8 needs a quirk for jack-detect and the internal mic to work correctly.
--- sound/soc/codecs/rt5670.c | 12 ++++++++++++ 1 file changed, 12 insertions(+)
sound/soc/codecs/rt5670.c +12 -0
@@ -2875,6 +2875,18 @@ static const struct dmi_system_id dmi_platform_intel_quirks[] = {RT5670_DEV_GPIO | RT5670_JD_MODE1), }, + { + .callback = rt5670_quirk_cb, + .ident = "Lenovo Thinkpad Tablet 8", + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"LENOVO" ), + DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad 8"), + }, + .driver_data = (unsigned long *)(RT5670_DMIC_EN | +RT5670_DMIC2_INR | +RT5670_DEV_GPIO | + RT5670_JD_MODE1), + }, { .callback = rt5670_quirk_cb, .ident = "Lenovo Thinkpad Tablet 10",
Signature · 1 line
2.18.0
PATCH v2 2/3 ASoC: Intel: common: Add quirk for Thinkpad 8 tablet
The Thinkpad 8 tablet uses 10EC5640 as ACPI HID, but it has a rt5670 codec add a quirk for this.
--- sound/soc/intel/common/soc-acpi-intel-byt-match.c | 7 +++++++ 1 file changed, 7 insertions(+)
sound/soc/intel/common/soc-acpi-intel-byt-match.c +7 -0
@@ -30,6 +30,13 @@ static int byt_thinkpad10_quirk_cb(const struct dmi_system_id *id)static const struct dmi_system_id byt_table[] = { + { + .callback = byt_thinkpad10_quirk_cb, + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"LENOVO" ), +DMI_MATCH (DMI_PRODUCT_VERSION ,"ThinkPad 8" ), + }, + }, { .callback = byt_thinkpad10_quirk_cb, .matches = {
Signature · 1 line
2.18.0
Mark Brown
maintainerApplied "ASoC: Intel: common: Add quirk for Thinkpad 8 tablet" to the asoc tree
The patch
ASoC: Intel: common: Add quirk for Thinkpad 8 tablet
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
Quoted 1 line
From
2ca426a24dd75e775ece1466ae45e019f0035b8dMon Sep 17 00:00:00 2001
From: Hans de Goede <[email protected]>
Date: Tue, 21 Aug 2018 13:43:36 +0200
Subject: [PATCH] ASoC: Intel: common: Add quirk for Thinkpad 8 tablet
The Thinkpad 8 tablet uses 10EC5640 as ACPI HID, but it has a rt5670 codec add a quirk for this.
--- sound/soc/intel/common/soc-acpi-intel-byt-match.c | 7 +++++++ 1 file changed, 7 insertions(+)
sound/soc/intel/common/soc-acpi-intel-byt-match.c +7 -0
@@ -30,6 +30,13 @@ static int byt_thinkpad10_quirk_cb(const struct dmi_system_id *id)static const struct dmi_system_id byt_table[] = { + { + .callback = byt_thinkpad10_quirk_cb, + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"LENOVO" ), +DMI_MATCH (DMI_PRODUCT_VERSION ,"ThinkPad 8" ), + }, + }, { .callback = byt_thinkpad10_quirk_cb, .matches = {
Signature · 1 line
2.18.0
PATCH v2 3/3 ASoC: Intel: cht-bsw-rt5672: Add key-mappings for the headset buttons
In reply to Hans de GoedeHaving the headset buttons send BTN_0, BTN_1 and BTN_2 events is not really useful. Add mappings to PLAYPAUSE VOLUME_UP and VOLUME_DOWN like we do in other Intel machine drivers.
--- sound/soc/intel/boards/cht_bsw_rt5672.c | 5 +++++ 1 file changed, 5 insertions(+)
sound/soc/intel/boards/cht_bsw_rt5672.c +5 -0
@@ -16,6 +16,7 @@* General Public License for more details. */ +#include <linux/input.h> #include <linux/module.h> #include <linux/platform_device.h> #include <linux/slab.h>
@@ -212,6 +213,10 @@ static int cht_codec_init(struct snd_soc_pcm_runtime *runtime)if (ret)return ret; +snd_jack_set_key (ctx->headset.jack,SND_JACK_BTN_0 ,KEY_PLAYPAUSE ); +snd_jack_set_key (ctx->headset.jack,SND_JACK_BTN_1 ,KEY_VOLUMEUP ); +snd_jack_set_key (ctx->headset.jack,SND_JACK_BTN_2 ,KEY_VOLUMEDOWN ); +rt5670_set_jack_detect (component, &ctx->headset);if (ctx->mclk) {/*
Signature · 1 line
2.18.0
Mark Brown
maintainerApplied "ASoC: Intel: cht-bsw-rt5672: Add key-mappings for the headset buttons" to the asoc tree
The patch
ASoC: Intel: cht-bsw-rt5672: Add key-mappings for the headset buttons
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
Quoted 1 line
From
f8fc397e13107f925186ee742e9e8dfbfe9a3d03Mon Sep 17 00:00:00 2001
From: Hans de Goede <[email protected]>
Date: Tue, 21 Aug 2018 13:43:37 +0200
Subject: [PATCH] ASoC: Intel: cht-bsw-rt5672: Add key-mappings for the headset
buttons
Having the headset buttons send BTN_0, BTN_1 and BTN_2 events is not really useful. Add mappings to PLAYPAUSE VOLUME_UP and VOLUME_DOWN like we do in other Intel machine drivers.
--- sound/soc/intel/boards/cht_bsw_rt5672.c | 5 +++++ 1 file changed, 5 insertions(+)
sound/soc/intel/boards/cht_bsw_rt5672.c +5 -0
@@ -16,6 +16,7 @@* General Public License for more details. */ +#include <linux/input.h> #include <linux/module.h> #include <linux/platform_device.h> #include <linux/slab.h>
@@ -212,6 +213,10 @@ static int cht_codec_init(struct snd_soc_pcm_runtime *runtime)if (ret)return ret; +snd_jack_set_key (ctx->headset.jack,SND_JACK_BTN_0 ,KEY_PLAYPAUSE ); +snd_jack_set_key (ctx->headset.jack,SND_JACK_BTN_1 ,KEY_VOLUMEUP ); +snd_jack_set_key (ctx->headset.jack,SND_JACK_BTN_2 ,KEY_VOLUMEDOWN ); +rt5670_set_jack_detect (component, &ctx->headset);if (ctx->mclk) {/*
Signature · 1 line
2.18.0
Mark Brown
maintainerApplied "ASoC: rt5670: Add quirk for Thinkpad 8 tablet" to the asoc tree
In reply to Hans de GoedeThe patch
ASoC: rt5670: Add quirk for Thinkpad 8 tablet
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
Quoted 1 line
From
818838e6bfa4ddc6c76703237028dcffb80d6496Mon Sep 17 00:00:00 2001
From: Hans de Goede <[email protected]>
Date: Tue, 21 Aug 2018 13:43:35 +0200
Subject: [PATCH] ASoC: rt5670: Add quirk for Thinkpad 8 tablet
The Thinkpad 8 needs a quirk for jack-detect and the internal mic to work correctly.
--- sound/soc/codecs/rt5670.c | 12 ++++++++++++ 1 file changed, 12 insertions(+)
sound/soc/codecs/rt5670.c +12 -0
@@ -2875,6 +2875,18 @@ static const struct dmi_system_id dmi_platform_intel_quirks[] = {RT5670_DEV_GPIO | RT5670_JD_MODE1), }, + { + .callback = rt5670_quirk_cb, + .ident = "Lenovo Thinkpad Tablet 8", + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"LENOVO" ), + DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad 8"), + }, + .driver_data = (unsigned long *)(RT5670_DMIC_EN | +RT5670_DMIC2_INR | +RT5670_DEV_GPIO | + RT5670_JD_MODE1), + }, { .callback = rt5670_quirk_cb, .ident = "Lenovo Thinkpad Tablet 10",
Signature · 1 line
2.18.0