85xx: Round up frequency calculations to get reasonable output
authorKumar Gala <galak@kernel.crashing.org>
Mon, 21 Apr 2008 14:28:36 +0000 (09:28 -0500)
committerWolfgang Denk <wd@denx.de>
Thu, 24 Apr 2008 13:42:35 +0000 (15:42 +0200)
commit022f12163595b9a55380c6d77c3119b93d6a9a4b
tree12e45edf11ffbfc0028a6dbf436bae23c2229827
parent0aa88c82667b9241107d7a0248c341db877e7e76
85xx: Round up frequency calculations to get reasonable output

eg. because of rounding error we can get 799Mhz instead of 800Mhz.

Introduced DIV_ROUND_UP and roundup taken from linux kernel.

Signed-off-by: Dejan Minic <minic@freescale.com>
Signed-off-by: Srikanth Srinivasan <srikanth.srinivasan@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Acked-by: Andy Fleming <afleming@freescale.com>
cpu/mpc85xx/cpu.c
include/common.h