[OpenBIOS] r331 - cpu/x86/pc/olpc
svn at openbios.org
svn at openbios.org
Sat Apr 28 00:18:48 CEST 2007
Author: wmb
Date: 2007-04-28 00:18:48 +0200 (Sat, 28 Apr 2007)
New Revision: 331
Modified:
cpu/x86/pc/olpc/devices.fth
cpu/x86/pc/olpc/fw.bth
Log:
OLPC - the clock frequency for the LX version is higher, so us-factor,
ms-factor, and the CPU node clock-frequency property must be version-specific.
Modified: cpu/x86/pc/olpc/devices.fth
===================================================================
--- cpu/x86/pc/olpc/devices.fth 2007-04-27 22:17:00 UTC (rev 330)
+++ cpu/x86/pc/olpc/devices.fth 2007-04-27 22:18:48 UTC (rev 331)
@@ -40,9 +40,18 @@
\ Use the CPU chip's Time Stamp Counter for timing; it does just what we want
fload ${BP}/cpu/x86/tsc.fth
-d# 366,666 to ms-factor
-d# 367 to us-factor
+stand-init:
+ gx? if d# 366,666,667 else d# 433,333,333 then ( cpu-clock-hz )
+
+ " /cpu" find-device ( cpu-clock-hz )
+ dup " clock-frequency" integer-property ( cpu-clock-hz )
+ device-end ( cpu-clock-hz )
+
+ d# 1000 rounded-/ dup to ms-factor ( cpu-clock-khz )
+ d# 1000 rounded-/ to us-factor ( )
+;
+
[ifdef] use-root-isa
0 0 " " " /" begin-package
fload ${BP}/cpu/x86/pc/isabus.fth \ ISA Bus Bridge under root node
Modified: cpu/x86/pc/olpc/fw.bth
===================================================================
--- cpu/x86/pc/olpc/fw.bth 2007-04-27 22:17:00 UTC (rev 330)
+++ cpu/x86/pc/olpc/fw.bth 2007-04-27 22:18:48 UTC (rev 331)
@@ -213,10 +213,6 @@
fload ${BP}/cpu/x86/pc/olpc/chipinit.fth
[then]
-dev /cpu
- d# 366,666,666 " clock-frequency" integer-property
-dend
-
warning @ warning off
: stand-init
stand-init
More information about the OpenBIOS
mailing list