Michael Yoo 96a5894cf3 x86: Fix IF reset upon nested interrupt
Fixes interrupt flag reset upon nested interrupt resume.

There were intermittent test failures on x86/32 characterised by
assertion failures at `c_nested_interrupt()`. The kernel only allows
one pending interrupt at a time, yet the kernel was entering
`c_nested_interrupt()` multiple times during a single entry-exit.

This should have been disallowed by `getActiveIRQ()` checking against
any pending interrupts.

`c_nested_interrupt()` is "entered" by the pc99-specific
`receivePendingIRQ()` helper (i.e. `sti; nop; cli`). If the nested
interrupt handler fails to clear the interrupt flag before running
`iret`, there's a small window between `nop; cli` that could trigger
a second nested interrupt.

This fixes the nested interrupt trap to correctly clear the interrupt
flag in the EFLAGS register that is restored upon `iret`.

Signed-off-by: Michael Yoo <Michael.Yoo@data61.csiro.au>
2020-07-22 11:18:46 +10:00
2020-06-18 12:39:46 +10:00
2020-06-17 17:27:20 +08:00
2020-04-01 17:23:36 +08:00
2020-04-07 19:35:33 +10:00
2019-11-20 18:17:11 +11:00

The seL4 microkernel

This project contains the source code of seL4 microkernel.

For details about the seL4 microkernel, including details about its formal correctness proof, please see the sel4.systems website and associated FAQ.

DOIs for citing recent releases of this repository:

  • DOI

We welcome contributions to seL4. Please see the website for information on how to contribute.

This repository is usually not used in isolation, but as part of the build system in a larger project.

seL4 Basics

Community

Manual

A hosted version of the manual for the most recent release can be found here.

A web version of the API can be found here

Repository Overview

  • include and src: C and ASM source code of seL4
  • tools: build tools
  • libsel4: C bindings for the seL4 ABI
  • manual: LaTeX sources of the seL4 reference manual

Build Instructions

See the seL4 website for build instructions.

Status

A list of releases and current project status can be found under seL4 releases.

Description
The seL4 microkernel
Readme 22 MiB
Languages
C 72.6%
Python 9.5%
CMake 6.3%
TeX 5.8%
Assembly 2.7%
Other 3.1%