linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ASoC: cygnus: remove redundant assignment to pointer 'res'
@ 2018-03-08 13:32 Colin King
  2018-03-08 17:22 ` Applied "ASoC: cygnus: remove redundant assignment to pointer 'res'" to the asoc tree Mark Brown
  2018-03-08 20:15 ` [PATCH] ASoC: cygnus: remove redundant assignment to pointer 'res' Scott Branden
  0 siblings, 2 replies; 3+ messages in thread
From: Colin King @ 2018-03-08 13:32 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
	Ray Jui, Scott Branden, Jon Mason, bcm-kernel-feedback-list,
	Lori Hikichi, alsa-devel, linux-arm-kernel
  Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

The pointer res is being initialized with a value that is never read
and re-assigned immediately after, hence the initialization is redundant
and can be removed.

Cleans up clang warning:
sound/soc/bcm/cygnus-ssp.c:1284:19: warning: Value stored to 'res'
during its initialization is never read

Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 sound/soc/bcm/cygnus-ssp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/bcm/cygnus-ssp.c b/sound/soc/bcm/cygnus-ssp.c
index abafadc0b534..b733f1446353 100644
--- a/sound/soc/bcm/cygnus-ssp.c
+++ b/sound/soc/bcm/cygnus-ssp.c
@@ -1281,7 +1281,7 @@ static int cygnus_ssp_probe(struct platform_device *pdev)
 {
 	struct device *dev = &pdev->dev;
 	struct device_node *child_node;
-	struct resource *res = pdev->resource;
+	struct resource *res;
 	struct cygnus_audio *cygaud;
 	int err = -EINVAL;
 	int node_count;
-- 
2.15.1

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

* Applied "ASoC: cygnus: remove redundant assignment to pointer 'res'" to the asoc tree
  2018-03-08 13:32 [PATCH] ASoC: cygnus: remove redundant assignment to pointer 'res' Colin King
@ 2018-03-08 17:22 ` Mark Brown
  2018-03-08 20:15 ` [PATCH] ASoC: cygnus: remove redundant assignment to pointer 'res' Scott Branden
  1 sibling, 0 replies; 3+ messages in thread
From: Mark Brown @ 2018-03-08 17:22 UTC (permalink / raw)
  To: Colin Ian King
  Cc: Mark Brown, Liam Girdwood, Mark Brown, Jaroslav Kysela,
	Takashi Iwai, Ray Jui, Scott Branden, Jon Mason,
	bcm-kernel-feedback-list, Lori Hikichi, alsa-devel,
	linux-arm-kernel, kernel-janitors, linux-kernel, alsa-devel

The patch

   ASoC: cygnus: remove redundant assignment to pointer 'res'

has been applied to the asoc tree at

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git 

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.  

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

>From 0338753a57aaf331cb7016bbfdba6086bf93149c Mon Sep 17 00:00:00 2001
From: Colin Ian King <colin.king@canonical.com>
Date: Thu, 8 Mar 2018 14:32:49 +0100
Subject: [PATCH] ASoC: cygnus: remove redundant assignment to pointer 'res'

The pointer res is being initialized with a value that is never read
and re-assigned immediately after, hence the initialization is redundant
and can be removed.

Cleans up clang warning:
sound/soc/bcm/cygnus-ssp.c:1284:19: warning: Value stored to 'res'
during its initialization is never read

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
---
 sound/soc/bcm/cygnus-ssp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/bcm/cygnus-ssp.c b/sound/soc/bcm/cygnus-ssp.c
index abafadc0b534..b733f1446353 100644
--- a/sound/soc/bcm/cygnus-ssp.c
+++ b/sound/soc/bcm/cygnus-ssp.c
@@ -1281,7 +1281,7 @@ static int cygnus_ssp_probe(struct platform_device *pdev)
 {
 	struct device *dev = &pdev->dev;
 	struct device_node *child_node;
-	struct resource *res = pdev->resource;
+	struct resource *res;
 	struct cygnus_audio *cygaud;
 	int err = -EINVAL;
 	int node_count;
-- 
2.16.2

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

* Re: [PATCH] ASoC: cygnus: remove redundant assignment to pointer 'res'
  2018-03-08 13:32 [PATCH] ASoC: cygnus: remove redundant assignment to pointer 'res' Colin King
  2018-03-08 17:22 ` Applied "ASoC: cygnus: remove redundant assignment to pointer 'res'" to the asoc tree Mark Brown
@ 2018-03-08 20:15 ` Scott Branden
  1 sibling, 0 replies; 3+ messages in thread
From: Scott Branden @ 2018-03-08 20:15 UTC (permalink / raw)
  To: Colin King, Liam Girdwood, Mark Brown, Jaroslav Kysela,
	Takashi Iwai, Ray Jui, Scott Branden, Jon Mason,
	bcm-kernel-feedback-list, Lori Hikichi, alsa-devel,
	linux-arm-kernel
  Cc: kernel-janitors, linux-kernel

Looks good.


On 18-03-08 05:32 AM, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> The pointer res is being initialized with a value that is never read
> and re-assigned immediately after, hence the initialization is redundant
> and can be removed.
>
> Cleans up clang warning:
> sound/soc/bcm/cygnus-ssp.c:1284:19: warning: Value stored to 'res'
> during its initialization is never read
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Scott Branden <scott.branden@broadcom.com>
> ---
>   sound/soc/bcm/cygnus-ssp.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/sound/soc/bcm/cygnus-ssp.c b/sound/soc/bcm/cygnus-ssp.c
> index abafadc0b534..b733f1446353 100644
> --- a/sound/soc/bcm/cygnus-ssp.c
> +++ b/sound/soc/bcm/cygnus-ssp.c
> @@ -1281,7 +1281,7 @@ static int cygnus_ssp_probe(struct platform_device *pdev)
>   {
>   	struct device *dev = &pdev->dev;
>   	struct device_node *child_node;
> -	struct resource *res = pdev->resource;
> +	struct resource *res;
>   	struct cygnus_audio *cygaud;
>   	int err = -EINVAL;
>   	int node_count;

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

end of thread, other threads:[~2018-03-08 20:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-08 13:32 [PATCH] ASoC: cygnus: remove redundant assignment to pointer 'res' Colin King
2018-03-08 17:22 ` Applied "ASoC: cygnus: remove redundant assignment to pointer 'res'" to the asoc tree Mark Brown
2018-03-08 20:15 ` [PATCH] ASoC: cygnus: remove redundant assignment to pointer 'res' Scott Branden

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).