[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200602122940.GF30374@kadam>
Date: Tue, 2 Jun 2020 15:29:40 +0300
From: Dan Carpenter <dan.carpenter@...cle.com>
To: Vaibhav Agarwal <vaibhav.sr@...il.com>
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Alex Elder <elder@...nel.org>, Johan Hovold <johan@...nel.org>,
Mark Greer <mgreer@...malcreek.com>,
Takashi Iwai <tiwai@...e.com>,
Jaroslav Kysela <perex@...ex.cz>,
Mark Brown <broonie@...nel.org>,
Liam Girdwood <lgirdwood@...il.com>,
devel@...verdev.osuosl.org, alsa-devel@...a-project.org,
Alexandre Belloni <alexandre.belloni@...tlin.com>,
linux-kernel@...r.kernel.org, greybus-dev@...ts.linaro.org
Subject: Re: [RESEND PATCH v1 3/6] staging: greybus: audio: Resolve
compilation errors for GB codec module
On Tue, Jun 02, 2020 at 10:51:12AM +0530, Vaibhav Agarwal wrote:
> Due to dependencies on ASoC framework changes, GB dummy codec module
> compilation is currently disabled. This patch updates codec driver as
> per the latest ASoC APIs.
>
> Signed-off-by: Vaibhav Agarwal <vaibhav.sr@...il.com>
> ---
> drivers/staging/greybus/audio_codec.c | 87 +++++++++++++--------------
> drivers/staging/greybus/audio_codec.h | 2 +-
> 2 files changed, 44 insertions(+), 45 deletions(-)
>
> diff --git a/drivers/staging/greybus/audio_codec.c b/drivers/staging/greybus/audio_codec.c
> index a2ee587e5a79..bbd072acda5c 100644
> --- a/drivers/staging/greybus/audio_codec.c
> +++ b/drivers/staging/greybus/audio_codec.c
> @@ -832,7 +832,7 @@ static int gbaudio_init_jack(struct gbaudio_module_info *module,
> int gbaudio_register_module(struct gbaudio_module_info *module)
> {
> int ret;
> - struct snd_soc_codec *codec;
> + struct snd_soc_component *component;
I quite like the "component" pointer because it's assigned once at the
start of the function and used consistently throughout. The other
pointers I complained about were just temporary pointers which meant
different things depending on which line you were on. They made the
code harder to read.
My only quible is that in the next patch it's called "comp" and here
it's called "component". Let's just use "comp" for all the local
variables.
regards,
dan carpenter
Powered by blists - more mailing lists