Rewrite init app in C, introduce MSL (MOP3 System Library)
All checks were successful
Build documentation / build-and-deploy (push) Successful in 35s
All checks were successful
Build documentation / build-and-deploy (push) Successful in 35s
This commit is contained in:
@@ -175,8 +175,6 @@ static void amd64_intr_exception (struct saved_regs* regs) {
|
||||
void amd64_intr_handler (void* stack_ptr) {
|
||||
struct saved_regs* regs = stack_ptr;
|
||||
|
||||
amd64_load_kernel_cr3 ();
|
||||
|
||||
if (regs->trap <= 31) {
|
||||
amd64_intr_exception (regs);
|
||||
} else {
|
||||
@@ -219,10 +217,6 @@ static void amd64_irq_restore_flags (uint64_t rflags) {
|
||||
|
||||
/// Save current interrupt state
|
||||
void irq_save (void) {
|
||||
/* before smp init. */
|
||||
if (thiscpu == NULL)
|
||||
return;
|
||||
|
||||
int prev = atomic_fetch_add_explicit (&thiscpu->irq_ctx.nesting, 1, memory_order_acq_rel);
|
||||
if (prev == 0)
|
||||
thiscpu->irq_ctx.rflags = amd64_irq_save_flags ();
|
||||
@@ -230,10 +224,6 @@ void irq_save (void) {
|
||||
|
||||
/// Restore interrupt state
|
||||
void irq_restore (void) {
|
||||
/* before smp init. */
|
||||
if (thiscpu == NULL)
|
||||
return;
|
||||
|
||||
int prev = atomic_fetch_sub_explicit (&thiscpu->irq_ctx.nesting, 1, memory_order_acq_rel);
|
||||
if (prev == 1)
|
||||
amd64_irq_restore_flags (thiscpu->irq_ctx.rflags);
|
||||
|
||||
Reference in New Issue
Block a user