Linux kernel staging patches
 help / color / mirror / Atom feed
* [PATCH] staging: greybus: fix some formatting issues
@ 2021-05-18 11:48 Wang Qing
  2021-05-18 12:05 ` Dan Carpenter
  0 siblings, 1 reply; 2+ messages in thread
From: Wang Qing @ 2021-05-18 11:48 UTC (permalink / raw)
  To: Vaibhav Agarwal, Mark Greer, Johan Hovold, Alex Elder,
	Greg Kroah-Hartman, greybus-dev, linux-staging, linux-kernel
  Cc: Wang Qing

fixing WARNING: void function return statements are not generally useful

Signed-off-by: Wang Qing <wangqing@vivo.com>
---
 drivers/staging/greybus/audio_codec.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/staging/greybus/audio_codec.c b/drivers/staging/greybus/audio_codec.c
index b589cf6..ffd8997
--- a/drivers/staging/greybus/audio_codec.c
+++ b/drivers/staging/greybus/audio_codec.c
@@ -1028,7 +1028,6 @@ static int gbcodec_probe(struct snd_soc_component *comp)
 static void gbcodec_remove(struct snd_soc_component *comp)
 {
 	/* Empty function for now */
-	return;
 }
 
 static int gbcodec_write(struct snd_soc_component *comp, unsigned int reg,
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] staging: greybus: fix some formatting issues
  2021-05-18 11:48 [PATCH] staging: greybus: fix some formatting issues Wang Qing
@ 2021-05-18 12:05 ` Dan Carpenter
  0 siblings, 0 replies; 2+ messages in thread
From: Dan Carpenter @ 2021-05-18 12:05 UTC (permalink / raw)
  To: Wang Qing
  Cc: Vaibhav Agarwal, Mark Greer, Johan Hovold, Alex Elder,
	Greg Kroah-Hartman, greybus-dev, linux-staging, linux-kernel

On Tue, May 18, 2021 at 07:48:34PM +0800, Wang Qing wrote:
> fixing WARNING: void function return statements are not generally useful
> 
> Signed-off-by: Wang Qing <wangqing@vivo.com>
> ---
>  drivers/staging/greybus/audio_codec.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/staging/greybus/audio_codec.c b/drivers/staging/greybus/audio_codec.c
> index b589cf6..ffd8997
> --- a/drivers/staging/greybus/audio_codec.c
> +++ b/drivers/staging/greybus/audio_codec.c
> @@ -1028,7 +1028,6 @@ static int gbcodec_probe(struct snd_soc_component *comp)
>  static void gbcodec_remove(struct snd_soc_component *comp)
>  {
>  	/* Empty function for now */
> -	return;
>  }

This is called from snd_soc_component_remove().  Just delete the whole
function.  It's unclear why there are so many dummy functions in this
driver...

regards,
dan carpenter


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-05-18 12:05 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-18 11:48 [PATCH] staging: greybus: fix some formatting issues Wang Qing
2021-05-18 12:05 ` Dan Carpenter

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 read-only IMAP folder(s) and NNTP newsgroup(s).