From: Stephen Warren Date: Wed, 23 Feb 2011 00:23:56 +0000 (-0700) Subject: ASoC: Tegra: Move utilities to separate module X-Git-Tag: v5.15~23284^2~1115^2~118 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=a3cd50deef7ba7df506af5347764a00b4621d7a7;p=mirror_ubuntu-kernels.git ASoC: Tegra: Move utilities to separate module The utilities will be required by every machine driver. Including the utility object directly into every machine driver causes a build failure if the modules are actually built into the kernel, since each will define the symbols exported by the utility file. Solve this by moving the utility object into a separate module. Signed-off-by: Stephen Warren Acked-by: Liam Girdwood Signed-off-by: Mark Brown --- diff --git a/sound/soc/tegra/Makefile b/sound/soc/tegra/Makefile index dfd2ab9d975c..fd183d3ab4f1 100644 --- a/sound/soc/tegra/Makefile +++ b/sound/soc/tegra/Makefile @@ -2,13 +2,14 @@ snd-soc-tegra-das-objs := tegra_das.o snd-soc-tegra-pcm-objs := tegra_pcm.o snd-soc-tegra-i2s-objs := tegra_i2s.o +snd-soc-tegra-utils-objs += tegra_asoc_utils.o +obj-$(CONFIG_SND_TEGRA_SOC) += snd-soc-tegra-utils.o obj-$(CONFIG_SND_TEGRA_SOC) += snd-soc-tegra-das.o obj-$(CONFIG_SND_TEGRA_SOC) += snd-soc-tegra-pcm.o obj-$(CONFIG_SND_TEGRA_SOC_I2S) += snd-soc-tegra-i2s.o # Tegra machine Support snd-soc-tegra-harmony-objs := harmony.o -snd-soc-tegra-harmony-objs += tegra_asoc_utils.o obj-$(CONFIG_SND_TEGRA_SOC_HARMONY) += snd-soc-tegra-harmony.o diff --git a/sound/soc/tegra/tegra_asoc_utils.c b/sound/soc/tegra/tegra_asoc_utils.c index cb4fc13c7d22..52f0a3f9ce40 100644 --- a/sound/soc/tegra/tegra_asoc_utils.c +++ b/sound/soc/tegra/tegra_asoc_utils.c @@ -101,6 +101,7 @@ int tegra_asoc_utils_set_rate(struct tegra_asoc_utils_data *data, int srate, return 0; } +EXPORT_SYMBOL_GPL(tegra_asoc_utils_set_rate); int tegra_asoc_utils_init(struct tegra_asoc_utils_data *data, struct device *dev) @@ -139,6 +140,7 @@ err_put_pll_a: err: return ret; } +EXPORT_SYMBOL_GPL(tegra_asoc_utils_init); void tegra_asoc_utils_fini(struct tegra_asoc_utils_data *data) { @@ -146,4 +148,8 @@ void tegra_asoc_utils_fini(struct tegra_asoc_utils_data *data) clk_put(data->clk_pll_a_out0); clk_put(data->clk_pll_a); } +EXPORT_SYMBOL_GPL(tegra_asoc_utils_fini); +MODULE_AUTHOR("Stephen Warren "); +MODULE_DESCRIPTION("Tegra ASoC utility code"); +MODULE_LICENSE("GPL");