Mercurial > ecos
diff packages/io/wallclock/current/src/wallclock.cxx @ 138:289bf90c6a9b
Merge from eCos master repository on 2000-11-24-06:43:05-GMT
| author | jlarmour |
|---|---|
| date | Fri, 24 Nov 2000 07:49:02 +0000 |
| parents | 4642a6d35749 |
| children | e0c0827131d1 |
line wrap: on
line diff
--- a/packages/io/wallclock/current/src/wallclock.cxx +++ b/packages/io/wallclock/current/src/wallclock.cxx @@ -59,12 +59,11 @@ // //========================================================================== -#include <pkgconf/kernel.h> // Kernel config #include <pkgconf/wallclock.h> // Wallclock device config #include <cyg/infra/cyg_type.h> // Common type definitions and support -#include <cyg/kernel/sched.inl> // For lock/unlock +#include <cyg/hal/drv_api.h> // Driver API #include <cyg/io/wallclock.hxx> // The WallClock API @@ -103,7 +102,7 @@ cyg_uint32 Cyg_WallClock::get_current_ti { cyg_uint32 res; - Cyg_Scheduler::lock(); + cyg_drv_dsr_lock(); #ifdef CYGSEM_WALLCLOCK_SET_GET_MODE res = get_hw_seconds(); @@ -111,7 +110,7 @@ cyg_uint32 Cyg_WallClock::get_current_ti res = epoch_time_stamp + get_hw_seconds() - epoch_ticks; #endif - Cyg_Scheduler::unlock(); + cyg_drv_dsr_unlock(); return res; } @@ -122,7 +121,7 @@ cyg_uint32 Cyg_WallClock::get_current_ti // anything up to a second to complete. void Cyg_WallClock::set_current_time( cyg_uint32 time_stamp ) { - Cyg_Scheduler::lock(); + cyg_drv_dsr_lock(); #ifdef CYGSEM_WALLCLOCK_SET_GET_MODE set_hw_seconds(time_stamp); @@ -131,7 +130,7 @@ void Cyg_WallClock::set_current_time( cy epoch_ticks = get_hw_seconds(); #endif - Cyg_Scheduler::unlock(); + cyg_drv_dsr_unlock(); } //-----------------------------------------------------------------------------
