[alsa-devel] [PATCH 3/5][RFC] ASoC: remove .get_regmap

Kuninori Morimoto kuninori.morimoto.gx at renesas.com
Mon Apr 9 04:15:17 CEST 2018


To setup regmap, ALSA SoC has snd_soc_component_init_regmap() and
.get_regmap. But these are duplicated feature.
Now, no one is using .get_regmap, let's remove it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx at renesas.com>
---
 include/sound/soc.h  | 2 --
 sound/soc/soc-core.c | 3 ---
 2 files changed, 5 deletions(-)

diff --git a/include/sound/soc.h b/include/sound/soc.h
index 8e50a39..9cb8ca2 100644
--- a/include/sound/soc.h
+++ b/include/sound/soc.h
@@ -964,8 +964,6 @@ struct snd_soc_codec_driver {
 	int (*set_jack)(struct snd_soc_codec *codec,
 			struct snd_soc_jack *jack,  void *data);
 
-	/* codec IO */
-	struct regmap *(*get_regmap)(struct device *);
 	unsigned int (*read)(struct snd_soc_codec *, unsigned int);
 	int (*write)(struct snd_soc_codec *, unsigned int, unsigned int);
 
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c
index 5f6e009..2f5958f 100644
--- a/sound/soc/soc-core.c
+++ b/sound/soc/soc-core.c
@@ -3601,9 +3601,6 @@ int snd_soc_register_codec(struct device *dev,
 	codec->component.debugfs_prefix = "codec";
 #endif
 
-	if (codec_drv->get_regmap)
-		codec->component.regmap = codec_drv->get_regmap(dev);
-
 	for (i = 0; i < num_dai; i++) {
 		convert_endianness_formats(&dai_drv[i].playback);
 		convert_endianness_formats(&dai_drv[i].capture);
-- 
1.9.1



More information about the Alsa-devel mailing list