linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] atm: solos-pci: remove useless variable assignments
@ 2017-06-15 19:56 Gustavo A. R. Silva
  2017-06-15 21:33 ` David Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Gustavo A. R. Silva @ 2017-06-15 19:56 UTC (permalink / raw)
  To: Chas Williams
  Cc: linux-atm-general, netdev, linux-kernel, Gustavo A. R. Silva

Value assigned to variable _data32_ at lines 1254 and 1257 is
overwritten at line 1260 before it can be used. This makes
such variable assignments useless.

Addresses-Coverity-ID: 1227049
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
---
 drivers/atm/solos-pci.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/atm/solos-pci.c b/drivers/atm/solos-pci.c
index 5ad037c..9115b29 100644
--- a/drivers/atm/solos-pci.c
+++ b/drivers/atm/solos-pci.c
@@ -1251,10 +1251,10 @@ static int fpga_probe(struct pci_dev *dev, const struct pci_device_id *id)
 
 	if (reset) {
 		iowrite32(1, card->config_regs + FPGA_MODE);
-		data32 = ioread32(card->config_regs + FPGA_MODE); 
+		ioread32(card->config_regs + FPGA_MODE);
 
 		iowrite32(0, card->config_regs + FPGA_MODE);
-		data32 = ioread32(card->config_regs + FPGA_MODE); 
+		ioread32(card->config_regs + FPGA_MODE);
 	}
 
 	data32 = ioread32(card->config_regs + FPGA_VER);
-- 
2.5.0

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

* Re: [PATCH] atm: solos-pci: remove useless variable assignments
  2017-06-15 19:56 [PATCH] atm: solos-pci: remove useless variable assignments Gustavo A. R. Silva
@ 2017-06-15 21:33 ` David Miller
  2017-06-15 21:43   ` Gustavo A. R. Silva
  0 siblings, 1 reply; 3+ messages in thread
From: David Miller @ 2017-06-15 21:33 UTC (permalink / raw)
  To: garsilva; +Cc: 3chas3, linux-atm-general, netdev, linux-kernel

From: "Gustavo A. R. Silva" <garsilva@embeddedor.com>
Date: Thu, 15 Jun 2017 14:56:21 -0500

> Value assigned to variable _data32_ at lines 1254 and 1257 is
> overwritten at line 1260 before it can be used. This makes
> such variable assignments useless.
> 
> Addresses-Coverity-ID: 1227049
> Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>

Applied, thanks.

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

* Re: [PATCH] atm: solos-pci: remove useless variable assignments
  2017-06-15 21:33 ` David Miller
@ 2017-06-15 21:43   ` Gustavo A. R. Silva
  0 siblings, 0 replies; 3+ messages in thread
From: Gustavo A. R. Silva @ 2017-06-15 21:43 UTC (permalink / raw)
  To: David Miller; +Cc: 3chas3, linux-atm-general, netdev, linux-kernel

Hi David,

Quoting David Miller <davem@davemloft.net>:

> From: "Gustavo A. R. Silva" <garsilva@embeddedor.com>
> Date: Thu, 15 Jun 2017 14:56:21 -0500
>
>> Value assigned to variable _data32_ at lines 1254 and 1257 is
>> overwritten at line 1260 before it can be used. This makes
>> such variable assignments useless.
>>
>> Addresses-Coverity-ID: 1227049
>> Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
>
> Applied, thanks.

Absolutely, glad to help.

Regards
--
Gustavo A. R. Silva

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

end of thread, other threads:[~2017-06-15 21:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-15 19:56 [PATCH] atm: solos-pci: remove useless variable assignments Gustavo A. R. Silva
2017-06-15 21:33 ` David Miller
2017-06-15 21:43   ` Gustavo A. R. Silva

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