Interrupts / Drop references to msdos/int1a.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This patch removes the last user of msdos/int1a.c.


Changelog:
  Remove last user of msdos/int1a.c.


Index: msdos/dosmem.c
===================================================================
RCS file: /home/wine/wine/msdos/dosmem.c,v
retrieving revision 1.44
diff -u -r1.44 dosmem.c
--- msdos/dosmem.c      4 Nov 2002 22:35:15 -0000       1.44
+++ msdos/dosmem.c      16 Nov 2002 19:09:13 -0000
@@ -234,6 +234,27 @@
     return (BIOSDATA *)(DOSMEM_sysmem + 0x400);
 }
 
+/**********************************************************************
+ *          DOSMEM_GetTicksSinceMidnight
+ *
+ * Return number of clock ticks since midnight.
+ */
+static DWORD DOSMEM_GetTicksSinceMidnight(void)
+{
+    struct tm *bdtime;
+    struct timeval tvs;
+    time_t seconds;
+
+    /* This should give us the (approximately) correct
+     * 18.206 clock ticks per second since midnight.
+     */
+    gettimeofday( &tvs, NULL );
+    seconds = tvs.tv_sec;
+    bdtime = localtime( &seconds );
+    return (((bdtime->tm_hour * 3600 + bdtime->tm_min * 60 +
+              bdtime->tm_sec) * 18206) / 1000) +
+                  (tvs.tv_usec / 54927);
+}
 
 /***********************************************************************
  *           DOSMEM_FillBiosSegments
@@ -281,7 +302,7 @@
     pBiosData->VideoPageSize        = 80 * 25 * 2;
     pBiosData->VideoPageStartAddr   = 0xb800;
     pBiosData->VideoCtrlAddr        = 0x3d4;
-    pBiosData->Ticks                = INT1A_GetTicksSinceMidnight();
+    pBiosData->Ticks                = DOSMEM_GetTicksSinceMidnight();
     pBiosData->NbHardDisks          = 2;
     pBiosData->KbdBufferStart       = 0x1e;
     pBiosData->KbdBufferEnd         = 0x3e;




-- 
Jukka Heinonen <http://www.iki.fi/jhei/>


[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux