From: Mike Frysinger Date: Wed, 15 Feb 2012 10:26:39 -0500 Subject: [U-Boot] sh: build warnings in clock code Message-ID: <201202151026.40313.vapier@gentoo.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de all superh boards hit this warning for me: Configuring for sh7763rdp board... time.c: In function 'get_ticks': time.c:111:16: warning: variable 'ticks' set but not used [-Wunused-but-set- variable] and indeed, looking at the code, ticks is set but not used. not sure if bug (ticks should be used), or just delete the variable ... unsigned long long get_ticks (void) { unsigned long tcnt = 0 - readl(TCNT0); unsigned long ticks; if (last_tcnt > tcnt) { /* overflow */ overflow_ticks++; ticks = (0xffffffff - last_tcnt) + tcnt; } else { ticks = tcnt; } last_tcnt = tcnt; return (overflow_ticks << 32) | tcnt; } -mike -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. URL: