Disallow changing CS which contains CPL
This commit is contained in:
+14
-14
@@ -26,20 +26,6 @@ use core::{
|
||||
};
|
||||
use spin::{Mutex, RwLock};
|
||||
|
||||
#[derive(Clone, Copy)]
|
||||
enum RegsKind {
|
||||
Float,
|
||||
Int
|
||||
}
|
||||
#[derive(Clone)]
|
||||
enum Operation {
|
||||
Memory(VirtualAddress),
|
||||
Regs(RegsKind),
|
||||
Trace {
|
||||
clones: Vec<ContextId>
|
||||
}
|
||||
}
|
||||
|
||||
fn with_context<F, T>(pid: ContextId, callback: F) -> Result<T>
|
||||
where F: FnOnce(&Context) -> Result<T>
|
||||
{
|
||||
@@ -101,6 +87,20 @@ fn try_stop_context<F, T>(pid: ContextId, restart_after: bool, mut callback: F)
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy)]
|
||||
enum RegsKind {
|
||||
Float,
|
||||
Int
|
||||
}
|
||||
#[derive(Clone)]
|
||||
enum Operation {
|
||||
Memory(VirtualAddress),
|
||||
Regs(RegsKind),
|
||||
Trace {
|
||||
clones: Vec<ContextId>
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy)]
|
||||
struct Info {
|
||||
pid: ContextId,
|
||||
|
||||
Reference in New Issue
Block a user