From c60b613a7097cff20fdd05e2891ce69542f0d5a3 Mon Sep 17 00:00:00 2001 From: Liam Girdwood Date: Thu, 14 Jun 2018 20:50:37 +0100 Subject: ASoC: topology: Give more data to clients via callbacks Give topology clients more access to the topology data by passing index, pcm, link_config and dai_driver to clients. This allows clients to fully instantiate and track topology objects. The SOF driver is the first user of these new APIs and needs them to build component topology driver and FW objects. Signed-off-by: Liam Girdwood Signed-off-by: Mark Brown --- include/sound/soc-topology.h | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) (limited to 'include/sound') diff --git a/include/sound/soc-topology.h b/include/sound/soc-topology.h index f552c3f56368..e1f265e21ee1 100644 --- a/include/sound/soc-topology.h +++ b/include/sound/soc-topology.h @@ -30,6 +30,8 @@ struct snd_soc_dapm_context; struct snd_soc_card; struct snd_kcontrol_new; struct snd_soc_dai_link; +struct snd_soc_dai_driver; +struct snd_soc_dai; /* object scan be loaded and unloaded in groups with identfying indexes */ #define SND_SOC_TPLG_INDEX_ALL 0 /* ID that matches all FW objects */ @@ -109,35 +111,38 @@ struct snd_soc_tplg_widget_events { struct snd_soc_tplg_ops { /* external kcontrol init - used for any driver specific init */ - int (*control_load)(struct snd_soc_component *, + int (*control_load)(struct snd_soc_component *, int index, struct snd_kcontrol_new *, struct snd_soc_tplg_ctl_hdr *); int (*control_unload)(struct snd_soc_component *, struct snd_soc_dobj *); /* external widget init - used for any driver specific init */ - int (*widget_load)(struct snd_soc_component *, + int (*widget_load)(struct snd_soc_component *, int index, struct snd_soc_dapm_widget *, struct snd_soc_tplg_dapm_widget *); - int (*widget_ready)(struct snd_soc_component *, + int (*widget_ready)(struct snd_soc_component *, int index, struct snd_soc_dapm_widget *, struct snd_soc_tplg_dapm_widget *); int (*widget_unload)(struct snd_soc_component *, struct snd_soc_dobj *); /* FE DAI - used for any driver specific init */ - int (*dai_load)(struct snd_soc_component *, - struct snd_soc_dai_driver *dai_drv); + int (*dai_load)(struct snd_soc_component *, int index, + struct snd_soc_dai_driver *dai_drv, + struct snd_soc_tplg_pcm *pcm, struct snd_soc_dai *dai); + int (*dai_unload)(struct snd_soc_component *, struct snd_soc_dobj *); /* DAI link - used for any driver specific init */ - int (*link_load)(struct snd_soc_component *, - struct snd_soc_dai_link *link); + int (*link_load)(struct snd_soc_component *, int index, + struct snd_soc_dai_link *link, + struct snd_soc_tplg_link_config *cfg); int (*link_unload)(struct snd_soc_component *, struct snd_soc_dobj *); /* callback to handle vendor bespoke data */ - int (*vendor_load)(struct snd_soc_component *, + int (*vendor_load)(struct snd_soc_component *, int index, struct snd_soc_tplg_hdr *); int (*vendor_unload)(struct snd_soc_component *, struct snd_soc_tplg_hdr *); @@ -146,7 +151,7 @@ struct snd_soc_tplg_ops { void (*complete)(struct snd_soc_component *); /* manifest - optional to inform component of manifest */ - int (*manifest)(struct snd_soc_component *, + int (*manifest)(struct snd_soc_component *, int index, struct snd_soc_tplg_manifest *); /* vendor specific kcontrol handlers available for binding */ -- cgit v1.2.3 From 503e79b793fea5de626db73accf8e8994bc4289d Mon Sep 17 00:00:00 2001 From: Liam Girdwood Date: Thu, 14 Jun 2018 20:53:59 +0100 Subject: ASoC: topology: Add callback for DAPM route load/unload Add a callback fro clients for notification about DAPM route loading and unloading. Signed-off-by: Liam Girdwood Signed-off-by: Mark Brown --- include/sound/soc-topology.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/sound') diff --git a/include/sound/soc-topology.h b/include/sound/soc-topology.h index e1f265e21ee1..401ef2c45d6c 100644 --- a/include/sound/soc-topology.h +++ b/include/sound/soc-topology.h @@ -32,6 +32,7 @@ struct snd_kcontrol_new; struct snd_soc_dai_link; struct snd_soc_dai_driver; struct snd_soc_dai; +struct snd_soc_dapm_route; /* object scan be loaded and unloaded in groups with identfying indexes */ #define SND_SOC_TPLG_INDEX_ALL 0 /* ID that matches all FW objects */ @@ -116,6 +117,12 @@ struct snd_soc_tplg_ops { int (*control_unload)(struct snd_soc_component *, struct snd_soc_dobj *); + /* DAPM graph route element loading and unloading */ + int (*dapm_route_load)(struct snd_soc_component *, int index, + struct snd_soc_dapm_route *route); + int (*dapm_route_unload)(struct snd_soc_component *, + struct snd_soc_dobj *); + /* external widget init - used for any driver specific init */ int (*widget_load)(struct snd_soc_component *, int index, struct snd_soc_dapm_widget *, -- cgit v1.2.3 From 62c2c9fcac4341d306dda4cf400b77e7e124480a Mon Sep 17 00:00:00 2001 From: Katsuhiro Suzuki Date: Mon, 11 Jun 2018 17:32:12 +0900 Subject: ASoC: simple-card-utils: move hp and mic detect gpios from simple-card This patch moves headphone and microphone jack detection gpios from simple-card driver. It is preparing for using this feature from other drivers. Signed-off-by: Katsuhiro Suzuki Acked-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/simple_card_utils.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'include/sound') diff --git a/include/sound/simple_card_utils.h b/include/sound/simple_card_utils.h index 7e25afce6566..f82acef3b992 100644 --- a/include/sound/simple_card_utils.h +++ b/include/sound/simple_card_utils.h @@ -12,6 +12,11 @@ #include +#define asoc_simple_card_init_hp(card, sjack, prefix) \ + asoc_simple_card_init_jack(card, sjack, 1, prefix) +#define asoc_simple_card_init_mic(card, sjack, prefix) \ + asoc_simple_card_init_jack(card, sjack, 0, prefix) + struct asoc_simple_dai { const char *name; unsigned int sysclk; @@ -28,6 +33,12 @@ struct asoc_simple_card_data { u32 convert_channels; }; +struct asoc_simple_jack { + struct snd_soc_jack jack; + struct snd_soc_jack_pin pin; + struct snd_soc_jack_gpio gpio; +}; + int asoc_simple_card_parse_daifmt(struct device *dev, struct device_node *node, struct device_node *codec, @@ -107,4 +118,8 @@ int asoc_simple_card_of_parse_routing(struct snd_soc_card *card, int asoc_simple_card_of_parse_widgets(struct snd_soc_card *card, char *prefix); +int asoc_simple_card_init_jack(struct snd_soc_card *card, + struct asoc_simple_jack *sjack, + int is_hp, char *prefix); + #endif /* __SIMPLE_CARD_UTILS_H */ -- cgit v1.2.3 From 0ddce71c21f03fd19867c4939d3ca710f37cdf1a Mon Sep 17 00:00:00 2001 From: Bard Liao Date: Thu, 7 Jun 2018 16:37:38 +0800 Subject: ASoC: rt5682: add rt5682 codec driver This is the initial codec driver for rt5682. Signed-off-by: Bard Liao Signed-off-by: Mark Brown --- include/sound/rt5682.h | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 include/sound/rt5682.h (limited to 'include/sound') diff --git a/include/sound/rt5682.h b/include/sound/rt5682.h new file mode 100644 index 000000000000..0251797ab438 --- /dev/null +++ b/include/sound/rt5682.h @@ -0,0 +1,40 @@ +/* + * linux/sound/rt5682.h -- Platform data for RT5682 + * + * Copyright 2018 Realtek Microelectronics + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#ifndef __LINUX_SND_RT5682_H +#define __LINUX_SND_RT5682_H + +enum rt5682_dmic1_data_pin { + RT5682_DMIC1_NULL, + RT5682_DMIC1_DATA_GPIO2, + RT5682_DMIC1_DATA_GPIO5, +}; + +enum rt5682_dmic1_clk_pin { + RT5682_DMIC1_CLK_GPIO1, + RT5682_DMIC1_CLK_GPIO3, +}; + +enum rt5682_jd_src { + RT5682_JD_NULL, + RT5682_JD1, +}; + +struct rt5682_platform_data { + + int ldo1_en; /* GPIO for LDO1_EN */ + + enum rt5682_dmic1_data_pin dmic1_data_pin; + enum rt5682_dmic1_clk_pin dmic1_clk_pin; + enum rt5682_jd_src jd_src; +}; + +#endif + -- cgit v1.2.3 From cbaa7f0bdbee1969bb311c641abbd0d2af6ba861 Mon Sep 17 00:00:00 2001 From: Pierre-Louis Bossart Date: Mon, 18 Jun 2018 13:29:37 -0500 Subject: ASoC: Intel: move SKL+ codec ACPI tables to common directory No functionality change, just move to common tables to make it easier to deal with SOF and share the same machine drivers - as done previously for BYT/CHT/HSW/BDW. Signed-off-by: Pierre-Louis Bossart Signed-off-by: Mark Brown --- include/sound/soc-acpi-intel-match.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include/sound') diff --git a/include/sound/soc-acpi-intel-match.h b/include/sound/soc-acpi-intel-match.h index 9da6388c20a1..917ddd0f2762 100644 --- a/include/sound/soc-acpi-intel-match.h +++ b/include/sound/soc-acpi-intel-match.h @@ -29,5 +29,10 @@ extern struct snd_soc_acpi_mach snd_soc_acpi_intel_broadwell_machines[]; extern struct snd_soc_acpi_mach snd_soc_acpi_intel_baytrail_legacy_machines[]; extern struct snd_soc_acpi_mach snd_soc_acpi_intel_baytrail_machines[]; extern struct snd_soc_acpi_mach snd_soc_acpi_intel_cherrytrail_machines[]; +extern struct snd_soc_acpi_mach snd_soc_acpi_intel_skl_machines[]; +extern struct snd_soc_acpi_mach snd_soc_acpi_intel_kbl_machines[]; +extern struct snd_soc_acpi_mach snd_soc_acpi_intel_bxt_machines[]; +extern struct snd_soc_acpi_mach snd_soc_acpi_intel_glk_machines[]; +extern struct snd_soc_acpi_mach snd_soc_acpi_intel_cnl_machines[]; #endif -- cgit v1.2.3 From f4c277b817cc9489fffabffb4e15d2f3b686056c Mon Sep 17 00:00:00 2001 From: Jiada Wang Date: Wed, 20 Jun 2018 18:25:20 +0900 Subject: ASoC: soc-pcm: DPCM cares BE channel constraint Current DPCM is caring only FE channel configuration. Sometimes it will be trouble if user selects channel which isn't supported by BE. This patch adds new .dpcm_merged_chan on struct snd_soc_dai_link. DPCM will use FE / BE merged channel if struct snd_soc_dai_link has it. Signed-off-by: Jiada Wang Signed-off-by: Mark Brown --- include/sound/soc.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/sound') diff --git a/include/sound/soc.h b/include/sound/soc.h index 1378dcd2128a..f7579f82cc00 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -957,6 +957,8 @@ struct snd_soc_dai_link { /* DPCM used FE & BE merged format */ unsigned int dpcm_merged_format:1; + /* DPCM used FE & BE merged channel */ + unsigned int dpcm_merged_chan:1; /* pmdown_time is ignored at stop */ unsigned int ignore_pmdown_time:1; -- cgit v1.2.3 From a7160670b5e2d6b59e0f7a5b7e5bcef3b532c24c Mon Sep 17 00:00:00 2001 From: Daniel Mack Date: Wed, 27 Jun 2018 21:33:54 +0200 Subject: ASoC: pxa: clean up function names in pxa2xx-lib Clean up the namespace a bit and drop the __ prefix of all functions exported by pxa2xx-lib. This improves the readability of the code. Signed-off-by: Daniel Mack Signed-off-by: Mark Brown --- include/sound/pxa2xx-lib.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'include/sound') diff --git a/include/sound/pxa2xx-lib.h b/include/sound/pxa2xx-lib.h index 63f75450d3db..b43de38de8b2 100644 --- a/include/sound/pxa2xx-lib.h +++ b/include/sound/pxa2xx-lib.h @@ -10,14 +10,14 @@ struct snd_pcm_substream; struct snd_pcm_hw_params; struct snd_pcm; -extern int __pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, +extern int pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *params); -extern int __pxa2xx_pcm_hw_free(struct snd_pcm_substream *substream); +extern int pxa2xx_pcm_hw_free(struct snd_pcm_substream *substream); extern int pxa2xx_pcm_trigger(struct snd_pcm_substream *substream, int cmd); extern snd_pcm_uframes_t pxa2xx_pcm_pointer(struct snd_pcm_substream *substream); -extern int __pxa2xx_pcm_prepare(struct snd_pcm_substream *substream); -extern int __pxa2xx_pcm_open(struct snd_pcm_substream *substream); -extern int __pxa2xx_pcm_close(struct snd_pcm_substream *substream); +extern int pxa2xx_pcm_prepare(struct snd_pcm_substream *substream); +extern int pxa2xx_pcm_open(struct snd_pcm_substream *substream); +extern int pxa2xx_pcm_close(struct snd_pcm_substream *substream); extern int pxa2xx_pcm_mmap(struct snd_pcm_substream *substream, struct vm_area_struct *vma); extern int pxa2xx_pcm_preallocate_dma_buffer(struct snd_pcm *pcm, int stream); -- cgit v1.2.3 From 7afd1b0b2ef9a8120951188a955010ef92bdf885 Mon Sep 17 00:00:00 2001 From: Daniel Mack Date: Wed, 27 Jun 2018 21:33:55 +0200 Subject: ASoC: pxa: move some functions to pxa2xx-lib To get rid of some intermediate platform layers, move pxa2xx_soc_pcm_new() and pxa2xx_pcm_ops in pxa2xx-lib. Signed-off-by: Daniel Mack Signed-off-by: Mark Brown --- include/sound/pxa2xx-lib.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/sound') diff --git a/include/sound/pxa2xx-lib.h b/include/sound/pxa2xx-lib.h index b43de38de8b2..6758fc12fa84 100644 --- a/include/sound/pxa2xx-lib.h +++ b/include/sound/pxa2xx-lib.h @@ -8,6 +8,7 @@ /* PCM */ struct snd_pcm_substream; struct snd_pcm_hw_params; +struct snd_soc_pcm_runtime; struct snd_pcm; extern int pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream, @@ -22,6 +23,8 @@ extern int pxa2xx_pcm_mmap(struct snd_pcm_substream *substream, struct vm_area_struct *vma); extern int pxa2xx_pcm_preallocate_dma_buffer(struct snd_pcm *pcm, int stream); extern void pxa2xx_pcm_free_dma_buffers(struct snd_pcm *pcm); +extern int pxa2xx_soc_pcm_new(struct snd_soc_pcm_runtime *rtd); +extern const struct snd_pcm_ops pxa2xx_pcm_ops; /* AC97 */ -- cgit v1.2.3 From d573454d9b4f00061da314460908e19476d2ff6d Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:30:28 +0000 Subject: ASoC: simple-card: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/simple_card.h | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'include/sound') diff --git a/include/sound/simple_card.h b/include/sound/simple_card.h index a6a2e1547092..d264e5463f22 100644 --- a/include/sound/simple_card.h +++ b/include/sound/simple_card.h @@ -1,12 +1,9 @@ -/* +/* SPDX-License-Identifier: GPL-2.0 + * * ASoC simple sound card support * * Copyright (C) 2012 Renesas Solutions Corp. * Kuninori Morimoto - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. */ #ifndef __SIMPLE_CARD_H -- cgit v1.2.3 From d613a7f45ebb2f113444630fcbbb8a074c741998 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:30:44 +0000 Subject: ASoC: simple-card-utils: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/simple_card_utils.h | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'include/sound') diff --git a/include/sound/simple_card_utils.h b/include/sound/simple_card_utils.h index f82acef3b992..8bc5e2d8b13c 100644 --- a/include/sound/simple_card_utils.h +++ b/include/sound/simple_card_utils.h @@ -1,12 +1,10 @@ -/* +/* SPDX-License-Identifier: GPL-2.0 + * * simple_card_utils.h * * Copyright (c) 2016 Kuninori Morimoto - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. */ + #ifndef __SIMPLE_CARD_UTILS_H #define __SIMPLE_CARD_UTILS_H -- cgit v1.2.3 From e2cfd2c9673f4e9d08971fed53fe1f41d8270ef0 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:22:15 +0000 Subject: ASoC: soc-dai.h: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/soc-dai.h | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'include/sound') diff --git a/include/sound/soc-dai.h b/include/sound/soc-dai.h index e6f8c40ed43c..a14bc0608ae9 100644 --- a/include/sound/soc-dai.h +++ b/include/sound/soc-dai.h @@ -1,12 +1,9 @@ -/* +/* SPDX-License-Identifier: GPL-2.0 + * * linux/sound/soc-dai.h -- ALSA SoC Layer * * Copyright: 2005-2008 Wolfson Microelectronics. PLC. * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. - * * Digital Audio Interface (DAI) API. */ -- cgit v1.2.3 From b53c34b4b73eb65e6480ada6ec8ddbcc2d4e9817 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:22:58 +0000 Subject: ASoC: soc-dpcm.h: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/soc-dpcm.h | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'include/sound') diff --git a/include/sound/soc-dpcm.h b/include/sound/soc-dpcm.h index 806059052bfc..9bb92f187af8 100644 --- a/include/sound/soc-dpcm.h +++ b/include/sound/soc-dpcm.h @@ -1,11 +1,8 @@ -/* +/* SPDX-License-Identifier: GPL-2.0 + * * linux/sound/soc-dpcm.h -- ALSA SoC Dynamic PCM Support * * Author: Liam Girdwood - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. */ #ifndef __LINUX_SND_SOC_DPCM_H -- cgit v1.2.3 From 7730bb13c7472620b585783f248b2dccd09d1819 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:24:04 +0000 Subject: ASoC: soc-acpi: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/soc-acpi-intel-match.h | 14 ++------------ include/sound/soc-acpi.h | 13 ++----------- 2 files changed, 4 insertions(+), 23 deletions(-) (limited to 'include/sound') diff --git a/include/sound/soc-acpi-intel-match.h b/include/sound/soc-acpi-intel-match.h index 917ddd0f2762..bb1d24b703fb 100644 --- a/include/sound/soc-acpi-intel-match.h +++ b/include/sound/soc-acpi-intel-match.h @@ -1,16 +1,6 @@ - -/* - * Copyright (C) 2017, Intel Corporation. All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License version - * 2 as published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. +/* SPDX-License-Identifier: GPL-2.0 * + * Copyright (C) 2017, Intel Corporation. All rights reserved. */ #ifndef __LINUX_SND_SOC_ACPI_INTEL_MATCH_H diff --git a/include/sound/soc-acpi.h b/include/sound/soc-acpi.h index 082224275f52..e45b2330d16a 100644 --- a/include/sound/soc-acpi.h +++ b/include/sound/soc-acpi.h @@ -1,15 +1,6 @@ -/* - * Copyright (C) 2013-15, Intel Corporation. All rights reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License version - * 2 as published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. +/* SPDX-License-Identifier: GPL-2.0 * + * Copyright (C) 2013-15, Intel Corporation. All rights reserved. */ #ifndef __LINUX_SND_SOC_ACPI_H -- cgit v1.2.3 From 873486ed4af3e11bfc20832dff7b124ba652bf77 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:24:18 +0000 Subject: ASoC: soc-core: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/soc.h | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'include/sound') diff --git a/include/sound/soc.h b/include/sound/soc.h index f7579f82cc00..16f0bf10cc42 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -1,13 +1,10 @@ -/* +/* SPDX-License-Identifier: GPL-2.0 + * * linux/sound/soc.h -- ALSA SoC Layer * - * Author: Liam Girdwood - * Created: Aug 11th 2005 + * Author: Liam Girdwood + * Created: Aug 11th 2005 * Copyright: Wolfson Microelectronics. PLC. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. */ #ifndef __LINUX_SND_SOC_H -- cgit v1.2.3 From c01f3af4d32071915119ffcb933e75d7c165378e Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:24:31 +0000 Subject: ASoC: soc-dapm: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/soc-dapm.h | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'include/sound') diff --git a/include/sound/soc-dapm.h b/include/sound/soc-dapm.h index a6ce2de4e20a..af9ef16cc34d 100644 --- a/include/sound/soc-dapm.h +++ b/include/sound/soc-dapm.h @@ -1,13 +1,10 @@ -/* +/* SPDX-License-Identifier: GPL-2.0 + * * linux/sound/soc-dapm.h -- ALSA SoC Dynamic Audio Power Management * - * Author: Liam Girdwood - * Created: Aug 11th 2005 + * Author: Liam Girdwood + * Created: Aug 11th 2005 * Copyright: Wolfson Microelectronics. PLC. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. */ #ifndef __LINUX_SND_SOC_DAPM_H -- cgit v1.2.3 From f2b6a1b25fecc48a46c8a41636101af8a41c88a8 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:24:45 +0000 Subject: ASoC: soc-topology: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/soc-topology.h | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'include/sound') diff --git a/include/sound/soc-topology.h b/include/sound/soc-topology.h index 401ef2c45d6c..fa4b8413d2e2 100644 --- a/include/sound/soc-topology.h +++ b/include/sound/soc-topology.h @@ -1,13 +1,10 @@ -/* +/* SPDX-License-Identifier: GPL-2.0 + * * linux/sound/soc-topology.h -- ALSA SoC Firmware Controls and DAPM * * Copyright (C) 2012 Texas Instruments Inc. * Copyright (C) 2015 Intel Corporation. * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. - * * Simple file API to load FW that includes mixers, coefficients, DAPM graphs, * algorithms, equalisers, DAIs, widgets, FE caps, BE caps, codec link caps etc. */ -- cgit v1.2.3 From b3ed4c86a700b494fc5058a52531eeb14d6fe00f Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:24:57 +0000 Subject: ASoC: soc-compress: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/compress_driver.h | 21 +++------------------ 1 file changed, 3 insertions(+), 18 deletions(-) (limited to 'include/sound') diff --git a/include/sound/compress_driver.h b/include/sound/compress_driver.h index 9924bc9cbc7c..ea8c93bbb0e0 100644 --- a/include/sound/compress_driver.h +++ b/include/sound/compress_driver.h @@ -1,27 +1,12 @@ -/* +/* SPDX-License-Identifier: GPL-2.0 + * * compress_driver.h - compress offload driver definations * * Copyright (C) 2011 Intel Corporation * Authors: Vinod Koul * Pierre-Louis Bossart - * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; version 2 of the License. - * - * This program is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License along - * with this program; if not, write to the Free Software Foundation, Inc., - * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. - * - * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - * */ + #ifndef __COMPRESS_DRIVER_H #define __COMPRESS_DRIVER_H -- cgit v1.2.3 From 1356a6071cf4d7187652cd2b18dfab4763e0dba6 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:25:11 +0000 Subject: ASoC: soc-generic-dmaengine-pcm: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/dmaengine_pcm.h | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) (limited to 'include/sound') diff --git a/include/sound/dmaengine_pcm.h b/include/sound/dmaengine_pcm.h index e3481eebdd98..2c4cfaa135a6 100644 --- a/include/sound/dmaengine_pcm.h +++ b/include/sound/dmaengine_pcm.h @@ -1,17 +1,9 @@ -/* +/* SPDX-License-Identifier: GPL-2.0+ + * * Copyright (C) 2012, Analog Devices Inc. * Author: Lars-Peter Clausen - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation; either version 2 of the License, or (at your - * option) any later version. - * - * You should have received a copy of the GNU General Public License along - * with this program; if not, write to the Free Software Foundation, Inc., - * 675 Mass Ave, Cambridge, MA 02139, USA. - * */ + #ifndef __SOUND_DMAENGINE_PCM_H__ #define __SOUND_DMAENGINE_PCM_H__ -- cgit v1.2.3 From 1a8f0a3c13c136951de7ea24ccb148e745db98a2 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Mon, 2 Jul 2018 06:26:27 +0000 Subject: ASoC: ac97: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/ac97/codec.h | 8 +++----- include/sound/ac97/compat.h | 9 +++------ include/sound/ac97/controller.h | 8 +++----- include/sound/ac97/regs.h | 20 ++------------------ include/sound/ac97_codec.h | 25 +++++-------------------- 5 files changed, 16 insertions(+), 54 deletions(-) (limited to 'include/sound') diff --git a/include/sound/ac97/codec.h b/include/sound/ac97/codec.h index ec04be9ab119..9792d25fa369 100644 --- a/include/sound/ac97/codec.h +++ b/include/sound/ac97/codec.h @@ -1,10 +1,8 @@ -/* - * Copyright (C) 2016 Robert Jarzmik +/* SPDX-License-Identifier: GPL-2.0 * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. + * Copyright (C) 2016 Robert Jarzmik */ + #ifndef __SOUND_AC97_CODEC2_H #define __SOUND_AC97_CODEC2_H diff --git a/include/sound/ac97/compat.h b/include/sound/ac97/compat.h index 1351cba40048..57e19afa31ab 100644 --- a/include/sound/ac97/compat.h +++ b/include/sound/ac97/compat.h @@ -1,14 +1,11 @@ -/* - * Copyright (C) 2016 Robert Jarzmik +/* SPDX-License-Identifier: GPL-2.0 * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. + * Copyright (C) 2016 Robert Jarzmik * * This file is for backward compatibility with snd_ac97 structure and its * multiple usages, such as the snd_ac97_bus and snd_ac97_build_ops. - * */ + #ifndef AC97_COMPAT_H #define AC97_COMPAT_H diff --git a/include/sound/ac97/controller.h b/include/sound/ac97/controller.h index b36ecdd64f14..06b5afb7fa6b 100644 --- a/include/sound/ac97/controller.h +++ b/include/sound/ac97/controller.h @@ -1,10 +1,8 @@ -/* - * Copyright (C) 2016 Robert Jarzmik +/* SPDX-License-Identifier: GPL-2.0 * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. + * Copyright (C) 2016 Robert Jarzmik */ + #ifndef AC97_CONTROLLER_H #define AC97_CONTROLLER_H diff --git a/include/sound/ac97/regs.h b/include/sound/ac97/regs.h index 9a4fa0c3264a..843f73f3705a 100644 --- a/include/sound/ac97/regs.h +++ b/include/sound/ac97/regs.h @@ -1,27 +1,11 @@ -/* +/* SPDX-License-Identifier: GPL-2.0+ + * * Copyright (c) by Jaroslav Kysela * Universal interface for Audio Codec '97 * * For more details look to AC '97 component specification revision 2.1 * by Intel Corporation (http://developer.intel.com). - * - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * */ - /* * AC'97 codec registers */ diff --git a/include/sound/ac97_codec.h b/include/sound/ac97_codec.h index 89d311a503d3..cc383991c0fe 100644 --- a/include/sound/ac97_codec.h +++ b/include/sound/ac97_codec.h @@ -1,30 +1,15 @@ -#ifndef __SOUND_AC97_CODEC_H -#define __SOUND_AC97_CODEC_H - -/* +/* SPDX-License-Identifier: GPL-2.0+ + * * Copyright (c) by Jaroslav Kysela * Universal interface for Audio Codec '97 * * For more details look to AC '97 component specification revision 2.1 * by Intel Corporation (http://developer.intel.com). - * - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * */ +#ifndef __SOUND_AC97_CODEC_H +#define __SOUND_AC97_CODEC_H + #include #include #include -- cgit v1.2.3 From a655de808cbde6c58b3298e704d786b53f59fb5d Mon Sep 17 00:00:00 2001 From: Liam Girdwood Date: Mon, 2 Jul 2018 16:59:54 +0100 Subject: ASoC: core: Allow topology to override machine driver FE DAI link config. Machine drivers statically define a number of DAI links that currently cannot be changed or removed by topology. This means PCMs and platform components cannot be changed by topology at runtime AND machine drivers are tightly coupled to topology. This patch allows topology to override the machine driver DAI link config in order to reuse machine drivers with different topologies and platform components. The patch supports :- 1) create new FE PCMs with a topology defined PCM ID. 2) destroy existing static FE PCMs 3) change the platform component driver. 4) assign any new HW params fixups. 5) assign a new card name prefix to differentiate this topology to userspace. The patch requires no changes to the machine drivers, but does add some platform component flags that the platform component driver can assign before loading topologies. Signed-off-by: Liam Girdwood Signed-off-by: Mark Brown --- include/sound/soc.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'include/sound') diff --git a/include/sound/soc.h b/include/sound/soc.h index 16f0bf10cc42..870ba6b64817 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -803,6 +803,14 @@ struct snd_soc_component_driver { unsigned int use_pmdown_time:1; /* care pmdown_time at stop */ unsigned int endianness:1; unsigned int non_legacy_dai_naming:1; + + /* this component uses topology and ignore machine driver FEs */ + const char *ignore_machine; + const char *topology_name_prefix; + int (*be_hw_params_fixup)(struct snd_soc_pcm_runtime *rtd, + struct snd_pcm_hw_params *params); + bool use_dai_pcm_id; /* use the DAI link PCM ID as PCM device number */ + int be_pcm_base; /* base device ID for all BE PCMs */ }; struct snd_soc_component { @@ -960,6 +968,9 @@ struct snd_soc_dai_link { /* pmdown_time is ignored at stop */ unsigned int ignore_pmdown_time:1; + /* Do not create a PCM for this DAI link (Backend link) */ + unsigned int ignore:1; + struct list_head list; /* DAI link list of the soc card */ struct snd_soc_dobj dobj; /* For topology */ }; @@ -999,6 +1010,7 @@ struct snd_soc_card { const char *long_name; const char *driver_name; char dmi_longname[80]; + char topology_shortname[32]; struct device *dev; struct snd_card *snd_card; @@ -1008,6 +1020,7 @@ struct snd_soc_card { struct mutex dapm_mutex; bool instantiated; + bool topology_shortname_created; int (*probe)(struct snd_soc_card *card); int (*late_probe)(struct snd_soc_card *card); -- cgit v1.2.3 From baacd8d100d571aa713c3c60b1471b9962e6ec8a Mon Sep 17 00:00:00 2001 From: Jerome Brunet Date: Thu, 5 Jul 2018 12:13:49 +0200 Subject: ASoC: dpcm: add rate merge to the BE stream merge As done for format and channels, add the possibility to merge the backend rates on the frontend rates. This useful if the backend does not support all rates supported by the frontend, or if several backends (cpu and codecs) with different capabilities are connected to the same frontend. Signed-off-by: Jerome Brunet Signed-off-by: Mark Brown --- include/sound/soc.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/sound') diff --git a/include/sound/soc.h b/include/sound/soc.h index 870ba6b64817..a4915148f739 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -964,6 +964,8 @@ struct snd_soc_dai_link { unsigned int dpcm_merged_format:1; /* DPCM used FE & BE merged channel */ unsigned int dpcm_merged_chan:1; + /* DPCM used FE & BE merged rate */ + unsigned int dpcm_merged_rate:1; /* pmdown_time is ignored at stop */ unsigned int ignore_pmdown_time:1; -- cgit v1.2.3 From bb4b894addb09a069c072a0a032f644cc470d17f Mon Sep 17 00:00:00 2001 From: Srinivas Kandagatla Date: Fri, 13 Jul 2018 16:36:28 +0100 Subject: ASoC: core: add support to card re-bind using component framework This patch aims at achieving dynamic behaviour of audio card when the dependent components disappear and reappear. With this patch the card is removed if any of the dependent component is removed and card is added back if the dependent component comes back. All this is done using component framework and matching based on component name. Signed-off-by: Srinivas Kandagatla Reviewed-by: Vinod Koul Signed-off-by: Mark Brown --- include/sound/soc.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/sound') diff --git a/include/sound/soc.h b/include/sound/soc.h index a4915148f739..a23ecdf3eff1 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include @@ -1090,6 +1091,12 @@ struct snd_soc_card { struct work_struct deferred_resume_work; + /* component framework related */ + bool components_added; + /* set in machine driver to enable/disable auto re-binding */ + bool auto_bind; + struct component_match *match; + /* lists of probed devices belonging to this card */ struct list_head component_dev_list; -- cgit v1.2.3 From cbdfab3b675f4c34258b0ec9e4707de44e1f6989 Mon Sep 17 00:00:00 2001 From: Jerome Brunet Date: Tue, 17 Jul 2018 17:43:02 +0200 Subject: ASoC: export snd_soc_of_get_slot_mask Amlogic's axg card driver can't use snd_soc_of_parse_tdm_slot() directly because it needs to handle 4 mask for each direction. Yet the parsing of each mask is the same, so export snd_soc_of_get_slot_mask() to reuse the the existing code. Signed-off-by: Jerome Brunet Signed-off-by: Mark Brown --- include/sound/soc.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/sound') diff --git a/include/sound/soc.h b/include/sound/soc.h index a23ecdf3eff1..ace474e8649e 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -1433,6 +1433,9 @@ int snd_soc_of_parse_card_name(struct snd_soc_card *card, const char *propname); int snd_soc_of_parse_audio_simple_widgets(struct snd_soc_card *card, const char *propname); +int snd_soc_of_get_slot_mask(struct device_node *np, + const char *prop_name, + unsigned int *mask); int snd_soc_of_parse_tdm_slot(struct device_node *np, unsigned int *tx_mask, unsigned int *rx_mask, -- cgit v1.2.3 From 467b061f1ac80f323bedb56d20a24f7bc0d2cec5 Mon Sep 17 00:00:00 2001 From: Srinivas Kandagatla Date: Mon, 23 Jul 2018 16:54:03 +0100 Subject: ASoC: core: add support to snd_soc_dai_get_channel_map() On Qualcomm platforms, specifically with SLIMbus interfaced codecs, the codec slim channel numbers are passed to DSP while configuring the slim audio path. Having get_channel_map() would allow dais to share such information across multiple dais. Signed-off-by: Srinivas Kandagatla Signed-off-by: Mark Brown --- include/sound/soc-dai.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'include/sound') diff --git a/include/sound/soc-dai.h b/include/sound/soc-dai.h index a14bc0608ae9..f5d70041108f 100644 --- a/include/sound/soc-dai.h +++ b/include/sound/soc-dai.h @@ -138,6 +138,11 @@ int snd_soc_dai_set_tristate(struct snd_soc_dai *dai, int tristate); int snd_soc_dai_digital_mute(struct snd_soc_dai *dai, int mute, int direction); + +int snd_soc_dai_get_channel_map(struct snd_soc_dai *dai, + unsigned int *tx_num, unsigned int *tx_slot, + unsigned int *rx_num, unsigned int *rx_slot); + int snd_soc_dai_is_dummy(struct snd_soc_dai *dai); struct snd_soc_dai_ops { @@ -165,6 +170,9 @@ struct snd_soc_dai_ops { int (*set_channel_map)(struct snd_soc_dai *dai, unsigned int tx_num, unsigned int *tx_slot, unsigned int rx_num, unsigned int *rx_slot); + int (*get_channel_map)(struct snd_soc_dai *dai, + unsigned int *tx_num, unsigned int *tx_slot, + unsigned int *rx_num, unsigned int *rx_slot); int (*set_tristate)(struct snd_soc_dai *dai, int tristate); int (*set_sdw_stream)(struct snd_soc_dai *dai, -- cgit v1.2.3 From 4cae99d9b5305ab8cccc839fccceb81ec9e5abda Mon Sep 17 00:00:00 2001 From: Pierre-Louis Bossart Date: Wed, 25 Jul 2018 15:15:56 -0500 Subject: ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally Make this helper inline function available for all platforms. This helps solve 0-day compilation issues when CONFIG_SND_DMA_SGBUF is not defined. Reported-by: kbuild test robot Signed-off-by: Pierre-Louis Bossart Reviewed-by: Takashi Iwai Signed-off-by: Mark Brown --- include/sound/memalloc.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'include/sound') diff --git a/include/sound/memalloc.h b/include/sound/memalloc.h index 9c3db3dce32b..c669900e6cbe 100644 --- a/include/sound/memalloc.h +++ b/include/sound/memalloc.h @@ -67,6 +67,14 @@ struct snd_dma_buffer { void *private_data; /* private for allocator; don't touch */ }; +/* + * return the pages matching with the given byte size + */ +static inline unsigned int snd_sgbuf_aligned_pages(size_t size) +{ + return (size + PAGE_SIZE - 1) >> PAGE_SHIFT; +} + #ifdef CONFIG_SND_DMA_SGBUF /* * Scatter-Gather generic device pages @@ -90,14 +98,6 @@ struct snd_sg_buf { struct device *dev; }; -/* - * return the pages matching with the given byte size - */ -static inline unsigned int snd_sgbuf_aligned_pages(size_t size) -{ - return (size + PAGE_SIZE - 1) >> PAGE_SHIFT; -} - /* * return the physical address at the corresponding offset */ -- cgit v1.2.3 From 0b62834e73e332fea76a340d62aaf50c732b17e0 Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Wed, 25 Jul 2018 23:17:17 +0200 Subject: ALSA: pcm: Add snd_mask_set_format() helper for standard usages Many drivers calling snd_mask_set() need to do ugly cast with __force for shutting up the sparse warnings. Actually almost all of them are about setting the format, so it's far better to provide a common helper snd_mask_set_format() to pass SNDRV_PCM_FORMAT_* directly without the cast. There are a few other calls of snd_mask_set(), but they are in the PCM core code, so we leave them for now. Signed-off-by: Takashi Iwai Signed-off-by: Mark Brown --- include/sound/pcm_params.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'include/sound') diff --git a/include/sound/pcm_params.h b/include/sound/pcm_params.h index c704357775fc..2dd37cada7c0 100644 --- a/include/sound/pcm_params.h +++ b/include/sound/pcm_params.h @@ -87,6 +87,13 @@ static inline void snd_mask_set(struct snd_mask *mask, unsigned int val) mask->bits[MASK_OFS(val)] |= MASK_BIT(val); } +/* Most of drivers need only this one */ +static inline void snd_mask_set_format(struct snd_mask *mask, + snd_pcm_format_t format) +{ + snd_mask_set(mask, (__force unsigned int)format); +} + static inline void snd_mask_reset(struct snd_mask *mask, unsigned int val) { mask->bits[MASK_OFS(val)] &= ~MASK_BIT(val); @@ -369,8 +376,7 @@ static inline int params_physical_width(const struct snd_pcm_hw_params *p) static inline void params_set_format(struct snd_pcm_hw_params *p, snd_pcm_format_t fmt) { - snd_mask_set(hw_param_mask(p, SNDRV_PCM_HW_PARAM_FORMAT), - (__force int)fmt); + snd_mask_set_format(hw_param_mask(p, SNDRV_PCM_HW_PARAM_FORMAT), fmt); } #endif /* __SOUND_PCM_PARAMS_H */ -- cgit v1.2.3 From 345a9ca37aa69bb3133c1a8390a71f993abcef0c Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Mon, 30 Jul 2018 08:46:40 +0200 Subject: ALSA: memalloc: Fix missing PAGE_SIZE definition The recent fix moved the inline snd_sgbuf_aligned_pages() outside the ifdef, and this triggered a build error on some architectures due to the undefined PAGE_SIZE, as spotted by 0day bot. Fix it by adding the missing header inclusion. Fixes: 4cae99d9b530 ("ALSA: memalloc: declare snd_sgbuf_aligned_pages() unconditionally") Reported-by: kbuild test robot Cc: Pierre-Louis Bossart Signed-off-by: Takashi Iwai Signed-off-by: Mark Brown --- include/sound/memalloc.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/sound') diff --git a/include/sound/memalloc.h b/include/sound/memalloc.h index c669900e6cbe..67561b997915 100644 --- a/include/sound/memalloc.h +++ b/include/sound/memalloc.h @@ -24,6 +24,8 @@ #ifndef __SOUND_MEMALLOC_H #define __SOUND_MEMALLOC_H +#include + struct device; /* -- cgit v1.2.3 From fdec79c18b08c68cfa079f2d3ee23c5a120a2eda Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Thu, 2 Aug 2018 01:47:30 +0000 Subject: ASoC: fsi: convert to SPDX identifiers Signed-off-by: Kuninori Morimoto Signed-off-by: Mark Brown --- include/sound/sh_fsi.h | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'include/sound') diff --git a/include/sound/sh_fsi.h b/include/sound/sh_fsi.h index 7a9710b4b799..89eafe23ef88 100644 --- a/include/sound/sh_fsi.h +++ b/include/sound/sh_fsi.h @@ -1,16 +1,13 @@ -#ifndef __SOUND_FSI_H -#define __SOUND_FSI_H - -/* +/* SPDX-License-Identifier: GPL-2.0 + * * Fifo-attached Serial Interface (FSI) support for SH7724 * * Copyright (C) 2009 Renesas Solutions Corp. * Kuninori Morimoto - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. */ +#ifndef __SOUND_FSI_H +#define __SOUND_FSI_H + #include #include -- cgit v1.2.3 From 611cbc8799b672f41b6ba7afed758ad9efb959a7 Mon Sep 17 00:00:00 2001 From: Srinivas Kandagatla Date: Thu, 2 Aug 2018 16:03:38 +0100 Subject: ASoC: core: remove support for card rebind using component framework DRM based audio components get registered inside the component framework bind callback. However component framework has a big mutex lock taken for every call to component_add, component_del and bind, unbind callbacks. This can lead to deadlock situation if we are trying to add new/remove component within a bind/unbind callbacks. Which is what was happening with bcm2837 rpi 3. Revert this change till we sort out the mutex issue. Reported-by: Guillaume Tucker Reported-by: Stefan Wahren Signed-off-by: Srinivas Kandagatla Signed-off-by: Mark Brown --- include/sound/soc.h | 7 ------- 1 file changed, 7 deletions(-) (limited to 'include/sound') diff --git a/include/sound/soc.h b/include/sound/soc.h index ace474e8649e..41cec42fb456 100644 --- a/include/sound/soc.h +++ b/include/sound/soc.h @@ -17,7 +17,6 @@ #include #include #include -#include #include #include #include @@ -1091,12 +1090,6 @@ struct snd_soc_card { struct work_struct deferred_resume_work; - /* component framework related */ - bool components_added; - /* set in machine driver to enable/disable auto re-binding */ - bool auto_bind; - struct component_match *match; - /* lists of probed devices belonging to this card */ struct list_head component_dev_list; -- cgit v1.2.3