alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
From: Lars-Peter Clausen <lars@metafoo.de>
To: Mark Brown <broonie@opensource.wolfsonmicro.com>,
	Liam Girdwood <lrg@ti.com>
Cc: alsa-devel@alsa-project.org, Lars-Peter Clausen <lars@metafoo.de>,
	linux-kernel@vger.kernel.org,
	device-drivers-devel@blackfin.uclinux.org
Subject: [PATCH 5/6] ASoC: AD1836: Remove unused fields from private struct
Date: Mon,  6 Jun 2011 13:38:39 +0200	[thread overview]
Message-ID: <1307360320-4727-5-git-send-email-lars@metafoo.de> (raw)
In-Reply-To: <1307360320-4727-1-git-send-email-lars@metafoo.de>

The control_type field is never used, so it can be removed.
The control_data field is used to initialize the codec's control_data field, but
since this is also done by the snd-soc-cache core, the redundant assignment can
be removed and the field can be dropped.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
---
 sound/soc/codecs/ad1836.c |    5 -----
 1 files changed, 0 insertions(+), 5 deletions(-)

diff --git a/sound/soc/codecs/ad1836.c b/sound/soc/codecs/ad1836.c
index a443cfe..75ff5a5 100644
--- a/sound/soc/codecs/ad1836.c
+++ b/sound/soc/codecs/ad1836.c
@@ -38,8 +38,6 @@ enum ad1836_type {
 
 /* codec private data */
 struct ad1836_priv {
-	enum snd_soc_control_type control_type;
-	void *control_data;
 	enum ad1836_type type;
 };
 
@@ -257,7 +255,6 @@ static int ad1836_probe(struct snd_soc_codec *codec)
 	num_dacs = ad183x_dais[ad1836->type].playback.channels_max / 2;
 	num_adcs = ad183x_dais[ad1836->type].capture.channels_max / 2;
 
-	codec->control_data = ad1836->control_data;
 	ret = snd_soc_codec_set_cache_io(codec, 4, 12, SND_SOC_SPI);
 	if (ret < 0) {
 		dev_err(codec->dev, "failed to set cache I/O: %d\n",
@@ -350,8 +347,6 @@ static int __devinit ad1836_spi_probe(struct spi_device *spi)
 	ad1836->type = spi_get_device_id(spi)->driver_data;
 
 	spi_set_drvdata(spi, ad1836);
-	ad1836->control_data = spi;
-	ad1836->control_type = SND_SOC_SPI;
 
 	ret = snd_soc_register_codec(&spi->dev,
 			&soc_codec_dev_ad1836, &ad183x_dais[ad1836->type], 1);
-- 
1.7.2.5

  parent reply	other threads:[~2011-06-06 11:39 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-06 11:38 [PATCH 1/6] ASoC: AD1836: Fix setting the PCM format Lars-Peter Clausen
2011-06-06 11:38 ` [PATCH 2/6] ASoC: AD1836: Add ADC/DAC controls helper macros Lars-Peter Clausen
2011-06-06 11:38 ` [PATCH 3/6] ASoC: AD1836: Use snd_soc_update_bits for read-modify-write Lars-Peter Clausen
2011-06-06 11:38 ` [PATCH 4/6] ASoC: AD1836: Add AD1835/AD1837/AD1838/AD1839 support Lars-Peter Clausen
2011-06-06 20:53   ` Mark Brown
2011-06-06 11:38 ` Lars-Peter Clausen [this message]
2011-06-06 11:38 ` [PATCH 6/6] ASoC: AD1836: Add input gain control for ADC2 Lars-Peter Clausen
2011-06-06 19:39 ` [PATCH 1/6] ASoC: AD1836: Fix setting the PCM format Liam Girdwood
2011-06-06 20:55 ` Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1307360320-4727-5-git-send-email-lars@metafoo.de \
    --to=lars@metafoo.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=device-drivers-devel@blackfin.uclinux.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lrg@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).