lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1393578983-20533-1-git-send-email-chase.southwood@yahoo.com>
Date:	Fri, 28 Feb 2014 03:16:23 -0600
From:	Chase Southwood <chase.southwood@...oo.com>
To:	gregkh@...uxfoundation.org
Cc:	abbotti@....co.uk, hsweeten@...ionengravers.com,
	devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org,
	Chase Southwood <chase.southwood@...oo.com>
Subject: [PATCH 2/2 v2] Staging: comedi: addi-data: remove unnecessary variable initializations in hwdrv_apci1564.c

A handful of variables here were being initialized to 0 upon declaration,
however they are always then set to another value before their first use,
so initialization here is useless and we can remove it.

Signed-off-by: Chase Southwood <chase.southwood@...oo.com>
---
2: no content change; redone and resent after PATCH 1/2 changed to ensure
clean applying.

 drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c
index d958d3c..c6e2d7e 100644
--- a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c
+++ b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c
@@ -307,7 +307,7 @@ static int i_APCI1564_ConfigTimerCounterWatchdog(struct comedi_device *dev,
 						 unsigned int *data)
 {
 	struct addi_private *devpriv = dev->private;
-	unsigned int ul_Command1 = 0;
+	unsigned int ul_Command1;
 
 	devpriv->tsk_Current = current;
 	if (data[0] == ADDIDATA_WATCHDOG) {
@@ -457,7 +457,7 @@ static int i_APCI1564_StartStopWriteTimerCounterWatchdog(struct comedi_device *d
 							 unsigned int *data)
 {
 	struct addi_private *devpriv = dev->private;
-	unsigned int ul_Command1 = 0;
+	unsigned int ul_Command1;
 
 	if (devpriv->b_TimerSelectMode == ADDIDATA_WATCHDOG) {
 		switch (data[1]) {
@@ -551,7 +551,7 @@ static int i_APCI1564_ReadTimerCounterWatchdog(struct comedi_device *dev,
 					       unsigned int *data)
 {
 	struct addi_private *devpriv = dev->private;
-	unsigned int ul_Command1 = 0;
+	unsigned int ul_Command1;
 
 	if (devpriv->b_TimerSelectMode == ADDIDATA_WATCHDOG) {
 		/*  Stores the status of the Watchdog */
@@ -649,7 +649,7 @@ static void v_APCI1564_Interrupt(int irq, void *d)
 	unsigned int ui_DO, ui_DI;
 	unsigned int ui_Timer;
 	unsigned int ui_C1, ui_C2, ui_C3, ui_C4;
-	unsigned int ul_Command2 = 0;
+	unsigned int ul_Command2;
 
 	ui_DI = inl(devpriv->i_IobaseAmcc + APCI1564_DIGITAL_IP +
 		APCI1564_DIGITAL_IP_IRQ) & 0x01;
-- 
1.8.5.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ