Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2be7b486 authored by Banajit Goswami's avatar Banajit Goswami
Browse files

Revert "ASoC: wcd: use component probe/remove on WCD/WSA drivers"



This reverts commit 07476f4c
("ASoC: wcd: use component probe/remove on WCD/WSA drivers").
This change should not come as yet. The series that changes the
codec driver to use component probe/remove functions are not yet
upstreamed.

Change-Id: I468fe74bdc247bbd8b858a3b88294e328bc4a01c
Signed-off-by: default avatarBanajit Goswami <bgoswami@codeaurora.org>
parent e0b20e1c
Loading
Loading
Loading
Loading
+4 −6
Original line number Diff line number Diff line
@@ -8764,9 +8764,8 @@ static int tomtom_cpe_initialize(struct snd_soc_codec *codec)
	return 0;
}

static int tomtom_codec_probe(struct snd_soc_component *component)
static int tomtom_codec_probe(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct wcd9xxx *control;
	struct tomtom_priv *tomtom;
	struct wcd9xxx_pdata *pdata;
@@ -8969,9 +8968,8 @@ static int tomtom_codec_probe(struct snd_soc_component *component)
	devm_kfree(codec->dev, tomtom);
	return ret;
}
static int tomtom_codec_remove(struct snd_soc_component *component)
static int tomtom_codec_remove(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct tomtom_priv *tomtom = snd_soc_codec_get_drvdata(codec);
	struct wcd9xxx *control;

@@ -9008,10 +9006,10 @@ static struct regmap *tomtom_get_regmap(struct device *dev)
}

static struct snd_soc_codec_driver soc_codec_dev_tomtom = {
	.get_regmap = tomtom_get_regmap,
	.component_driver = {
	.probe = tomtom_codec_probe,
	.remove = tomtom_codec_remove,
	.get_regmap = tomtom_get_regmap,
	.component_driver = {
		.controls = tomtom_snd_controls,
		.num_controls = ARRAY_SIZE(tomtom_snd_controls),
		.dapm_widgets = tomtom_dapm_widgets,
+4 −6
Original line number Diff line number Diff line
@@ -13520,9 +13520,8 @@ static struct regulator *tasha_codec_find_ondemand_regulator(
	return NULL;
}

static int tasha_codec_probe(struct snd_soc_component *component)
static int tasha_codec_probe(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct wcd9xxx *control;
	struct tasha_priv *tasha;
	struct wcd9xxx_pdata *pdata;
@@ -13740,9 +13739,8 @@ static int tasha_codec_probe(struct snd_soc_component *component)
	return ret;
}

static int tasha_codec_remove(struct snd_soc_component *component)
static int tasha_codec_remove(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct tasha_priv *tasha = snd_soc_codec_get_drvdata(codec);
	struct wcd9xxx *control;

@@ -13765,10 +13763,10 @@ static struct regmap *tasha_get_regmap(struct device *dev)
}

static struct snd_soc_codec_driver soc_codec_dev_tasha = {
	.get_regmap = tasha_get_regmap,
	.component_driver = {
	.probe = tasha_codec_probe,
	.remove = tasha_codec_remove,
	.get_regmap = tasha_get_regmap,
	.component_driver = {
		.controls = tasha_snd_controls,
		.num_controls = ARRAY_SIZE(tasha_snd_controls),
		.dapm_widgets = tasha_dapm_widgets,
+4 −6
Original line number Diff line number Diff line
@@ -8861,9 +8861,8 @@ static int tavil_post_reset_cb(struct wcd9xxx *wcd9xxx)
	return ret;
}

static int tavil_soc_codec_probe(struct snd_soc_component *component)
static int tavil_soc_codec_probe(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct wcd9xxx *control;
	struct tavil_priv *tavil;
	struct wcd9xxx_pdata *pdata;
@@ -9026,9 +9025,8 @@ static int tavil_soc_codec_probe(struct snd_soc_component *component)
	return ret;
}

static int tavil_soc_codec_remove(struct snd_soc_component *component)
static int tavil_soc_codec_remove(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct wcd9xxx *control;
	struct tavil_priv *tavil = snd_soc_codec_get_drvdata(codec);

@@ -9056,10 +9054,10 @@ static struct regmap *tavil_get_regmap(struct device *dev)
}

static struct snd_soc_codec_driver soc_codec_dev_tavil = {
	.get_regmap = tavil_get_regmap,
	.component_driver = {
	.probe = tavil_soc_codec_probe,
	.remove = tavil_soc_codec_remove,
	.get_regmap = tavil_get_regmap,
	.component_driver = {
		.controls = tavil_snd_controls,
		.num_controls = ARRAY_SIZE(tavil_snd_controls),
		.dapm_widgets = tavil_dapm_widgets,
+5 −7
Original line number Diff line number Diff line
@@ -1019,9 +1019,8 @@ static int32_t wsa881x_temp_reg_read(struct snd_soc_codec *codec,
	return ret;
}

static int wsa881x_probe(struct snd_soc_component *component)
static int wsa881x_probe(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct i2c_client *client;
	int ret = 0;
	int wsa881x_index = 0;
@@ -1074,9 +1073,8 @@ static int wsa881x_probe(struct snd_soc_component *component)
	return 0;
}

static int wsa881x_remove(struct snd_soc_component *component)
static int wsa881x_remove(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct wsa881x_pdata *wsa881x = snd_soc_codec_get_drvdata(codec);

	if (wsa881x->tz_pdata.tz_dev)
@@ -1088,6 +1086,9 @@ static int wsa881x_remove(struct snd_soc_component *component)
}

static struct snd_soc_codec_driver soc_codec_dev_wsa881x = {
	.probe	= wsa881x_probe,
	.remove	= wsa881x_remove,

	.read = wsa881x_i2c_read,
	.write = wsa881x_i2c_write,

@@ -1096,9 +1097,6 @@ static struct snd_soc_codec_driver soc_codec_dev_wsa881x = {
	.reg_word_size = 1,

	.component_driver = {
		.probe	= wsa881x_probe,
		.remove	= wsa881x_remove,

		.controls = wsa881x_snd_controls,
		.num_controls = ARRAY_SIZE(wsa881x_snd_controls),
		.dapm_widgets = wsa881x_dapm_widgets,
+4 −6
Original line number Diff line number Diff line
@@ -1026,9 +1026,8 @@ static int32_t wsa881x_temp_reg_read(struct snd_soc_codec *codec,
	return 0;
}

static int wsa881x_probe(struct snd_soc_component *component)
static int wsa881x_probe(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct wsa881x_priv *wsa881x = snd_soc_codec_get_drvdata(codec);
	struct swr_device *dev;

@@ -1053,9 +1052,8 @@ static int wsa881x_probe(struct snd_soc_component *component)
	return 0;
}

static int wsa881x_remove(struct snd_soc_component *component)
static int wsa881x_remove(struct snd_soc_codec *codec)
{
	struct snd_soc_codec *codec = snd_soc_component_to_codec(component);
	struct wsa881x_priv *wsa881x = snd_soc_codec_get_drvdata(codec);

	if (wsa881x->tz_pdata.tz_dev)
@@ -1077,10 +1075,10 @@ static struct regmap *wsa881x_get_regmap(struct device *dev)
}

static struct snd_soc_codec_driver soc_codec_dev_wsa881x = {
	.get_regmap = wsa881x_get_regmap,
	.component_driver = {
	.probe = wsa881x_probe,
	.remove = wsa881x_remove,
	.get_regmap = wsa881x_get_regmap,
	.component_driver = {
		.controls = wsa881x_snd_controls,
		.num_controls = ARRAY_SIZE(wsa881x_snd_controls),
		.dapm_widgets = wsa881x_dapm_widgets,