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>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.64N.0610231542130.5012@attu3.cs.washington.edu>
Date:	Mon, 23 Oct 2006 15:43:46 -0700 (PDT)
From:	David Rientjes <rientjes@...washington.edu>
To:	thomas@...ischhofer.net
cc:	jesper.juhl@...il.com, linux-kernel@...r.kernel.org
Subject: [PATCH] video SiS: remove unnecessary variables in SiS_DDC2Delay

Remove unnecesary iteration and accumulator variables from SiS_DDC2Delay.

Originally spotted by Jesper Juhl <jesper.juhl@...il.com>.

Cc: Jesper Juhl <jesper.juhl@...il.com>
Cc: Thomas Winischhofer <thomas@...ischhofer.net>
Signed-off-by: David Rientjes <rientjes@...washington.edu>
---
 drivers/video/sis/init301.c |    7 ++-----
 1 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/drivers/video/sis/init301.c b/drivers/video/sis/init301.c
index f13fadd..47e1896 100644
--- a/drivers/video/sis/init301.c
+++ b/drivers/video/sis/init301.c
@@ -445,11 +445,8 @@ #endif
 void
 SiS_DDC2Delay(struct SiS_Private *SiS_Pr, unsigned int delaytime)
 {
-   unsigned int i, j;
-
-   for(i = 0; i < delaytime; i++) {
-      j += SiS_GetReg(SiS_Pr->SiS_P3c4,0x05);
-   }
+   while (delaytime-- > 0)
+      SiS_GetReg(SiS_Pr->SiS_P3c4, 0x05);
 }
 
 #if defined(SIS300) || defined(SIS315H)
-
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