Cosmetics, coding style fixes (trivial).

Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de>
Acked-by: Uwe Hermann <uwe@hermann-uwe.de>



git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3180 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
This commit is contained in:
Uwe Hermann
2008-03-20 19:54:59 +00:00
parent 5f4c8abb65
commit 6a441bfb46
22 changed files with 348 additions and 401 deletions

View File

@ -30,41 +30,29 @@
#include <libpayload.h>
#include <sysinfo.h>
/* This is a global structure that is used through the
library - we set it up initially with some dummy
values - hopefully they will be overridden
*/
/**
* This is a global structure that is used through the library - we set it
* up initially with some dummy values - hopefully they will be overridden.
*/
struct sysinfo_t lib_sysinfo = {
. cpu_khz = 200,
. ser_ioport = CONFIG_SERIAL_IOBASE,
.cpu_khz = 200,
.ser_ioport = CONFIG_SERIAL_IOBASE,
};
void lib_get_sysinfo(void)
{
/* Get the CPU speed (for delays) */
/* Get the CPU speed (for delays). */
lib_sysinfo.cpu_khz = get_cpu_speed();
/* Get the memory information */
/* Get the memory information. */
get_coreboot_info(&lib_sysinfo);
if (!lib_sysinfo.n_memranges) {
/* If we couldn't get a good memory range,
then use a hard coded default */
/* If we can't get a good memory range, use the default. */
lib_sysinfo.n_memranges = 2;
lib_sysinfo.memrange[0].base = 0;
lib_sysinfo.memrange[0].size = 640 * 1024;
lib_sysinfo.memrange[1].base = 1024 * 1024;
lib_sysinfo.memrange[1].size = 31 * 1024 * 1024;
}
}