From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chin Liang See Date: Thu, 17 Jul 2014 05:21:10 -0500 Subject: [U-Boot] [PATCH] socfpga: timer actually counts down In-Reply-To: <20140713111045.GA20825@amd.pavel.ucw.cz> References: <20140713111045.GA20825@amd.pavel.ucw.cz> Message-ID: <1405592470.2088.0.camel@clsee-VirtualBox.altera.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Sun, 2014-07-13 at 13:10 +0200, ZY - pavel wrote: > Timer on cyclone5 actually counts down. It took me a while to figure > out, as timer counting in wrong direction actually _can_ be used, it > just appears to tick at extremely high frequency in u-boot. > > The bug was introduced in commit > 23ab7ee0ffa9d5efd0b4ad830befba306d24a327. > > Signed-off-by: Pavel Machek > > diff --git a/include/configs/socfpga_cyclone5.h b/include/configs/socfpga_cyclone5.h > index c9c8e53..cc4f690 100644 > --- a/include/configs/socfpga_cyclone5.h > +++ b/include/configs/socfpga_cyclone5.h > @@ -204,6 +204,7 @@ > #else > #define CONFIG_SYS_TIMER_RATE 25000000 > #endif > +#define CONFIG_SYS_TIMER_COUNTS_DOWN > #define CONFIG_SYS_TIMER_COUNTER (CONFIG_SYS_TIMERBASE + 0x4) > > #define CONFIG_ENV_IS_NOWHERE > Acked-by: Chin Liang See Thanks Chin Liang