Implement more test arch features

This commit is contained in:
Jeremy Soller 2016-11-14 11:04:31 -07:00
parent 7e71c85c80
commit 3c0abadfd0
7 changed files with 75 additions and 23 deletions

View file

@ -23,6 +23,12 @@ pub unsafe fn halt() {
::std::thread::yield_now();
}
/// Pause instruction
#[inline(always)]
pub unsafe fn pause() {
}
/// Set interrupts and nop
#[inline(always)]
pub unsafe fn enable_and_nop() {

View file

@ -38,3 +38,6 @@ pub mod interrupt;
/// Initialization and main function
pub mod main;
/// Time functions
pub mod time;

7
arch/test/src/time.rs Normal file
View file

@ -0,0 +1,7 @@
pub fn monotonic() -> (u64, u64) {
(0, 0)
}
pub fn realtime() -> (u64, u64) {
(0, 0)
}