Palacios Public Git Repository

To checkout Palacios execute

  git clone http://v3vee.org/palacios/palacios.web/palacios.git
This will give you the master branch. You probably want the devel branch or one of the release branches. To switch to the devel branch, simply execute
  cd palacios
  git checkout --track -b devel origin/devel
The other branches are similar.


Compilable version with both lwip and uip
[palacios.git] / palacios / src / geekos / timer.c
index 9a54ff2..ec47b0b 100644 (file)
@@ -131,11 +131,6 @@ timerEvent pendingTimerEvents[MAX_TIMER_EVENTS];
  */
 volatile ulong_t g_numTicks;
 
-ulong_t clock_time(void){
-       return g_numTicks;
-}
-
-
 /*
  * Number of times the spin loop can execute during one timer tick
  */
@@ -171,6 +166,10 @@ int g_Quantum = DEFAULT_MAX_TICKS;
 #  define Debug(args...)
 #endif
 
+ulong_t clock_time(void){//in millisec
+      return g_numTicks * (1000/HZ);
+}
+
 /* ----------------------------------------------------------------------
  * Private functions
  * ---------------------------------------------------------------------- */