From mboxrd@z Thu Jan 1 00:00:00 1970 From: Shinya Kuribayashi Date: Tue, 29 Jul 2008 12:31:51 +0900 Subject: [U-Boot-Users] [PATCH] mips: Fix baudrate divisor computation on alchemy cpus In-Reply-To: <1217257011.3293.20.camel@galileo.recco.de> References: <1217257011.3293.20.camel@galileo.recco.de> Message-ID: <488E8F27.6050403@necel.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Wolfgang Ocker wrote: > Use CFG_MIPS_TIMER_FREQ when computing the baudrate divisor > on alchemy cpus. > > Signed-off-by: Wolfgang Ocker Thanks, I'll apply and push this out tonight. This patch should go in the upcoming v1.3.4 final. Shinya > --- > diff --git a/cpu/mips/au1x00_serial.c b/cpu/mips/au1x00_serial.c > index 6309794..e8baab5 100644 > --- a/cpu/mips/au1x00_serial.c > +++ b/cpu/mips/au1x00_serial.c > @@ -76,7 +76,7 @@ void serial_setbrg (void) > sd = (*sys_powerctrl & 0x03) + 2; > > /* calulate 2x baudrate and round */ > - divisorx2 = ((CFG_HZ/(sd * 16 * CONFIG_BAUDRATE))); > + divisorx2 = ((CFG_MIPS_TIMER_FREQ/(sd * 16 * CONFIG_BAUDRATE))); > > if (divisorx2 & 0x01) > divisorx2 = divisorx2 + 1;