|
@@ -3,10 +3,9 @@
|
3
|
3
|
* Body of routines taken from old pcbios.S
|
4
|
4
|
*/
|
5
|
5
|
|
6
|
|
-#include "stdint.h"
|
7
|
|
-#include "realmode.h"
|
8
|
|
-
|
9
|
|
-#define BIOS_DATA_SEG 0x0040
|
|
6
|
+#include <stdint.h>
|
|
7
|
+#include <realmode.h>
|
|
8
|
+#include <bios.h>
|
10
|
9
|
|
11
|
10
|
#define CF ( 1 << 0 )
|
12
|
11
|
|
|
@@ -39,12 +38,12 @@ unsigned long currticks ( void ) {
|
39
|
38
|
IN_CONSTRAINTS (),
|
40
|
39
|
CLOBBER ( "eax" ) ); /* can't have an empty clobber list */
|
41
|
40
|
|
42
|
|
- get_real ( ticks, BIOS_DATA_SEG, 0x006c );
|
43
|
|
- get_real ( midnight, BIOS_DATA_SEG, 0x0070 );
|
|
41
|
+ get_real ( ticks, BDA_SEG, 0x006c );
|
|
42
|
+ get_real ( midnight, BDA_SEG, 0x0070 );
|
44
|
43
|
|
45
|
44
|
if ( midnight ) {
|
46
|
45
|
midnight = 0;
|
47
|
|
- put_real ( midnight, BIOS_DATA_SEG, 0x0070 );
|
|
46
|
+ put_real ( midnight, BDA_SEG, 0x0070 );
|
48
|
47
|
days += 0x1800b0;
|
49
|
48
|
}
|
50
|
49
|
return ( days + ticks );
|