Commit graph

230 commits

Author SHA1 Message Date
Ivan Velickovic
973cbf4e08 Add support for ARM Cortex-A76
This micro-arch is used by the RPi5.

Signed-off-by: Ivan Velickovic <i.velickovic@unsw.edu.au>
2026-07-07 13:30:25 +10:00
Julia Vassiliki
90b5159800 debug: add get thread affinity syscall
This is useful for sel4test et al for testing that a certain
PD has been succesfully migrated between cores, or that it
is running on a particular core.

Signed-off-by: Julia Vassiliki <julia.vassiliki@unsw.edu.au>
2026-06-22 18:06:26 +10:00
Gerwin Klein
b62417a292 libsel4/riscv: avoid gcc 14.2 miscompilation
a7 is not changed by seL4_Yield, so the original declaration is correct.

However, in some loops GCC 14.2 may drop the load to a7 if a7 or
memory are not declared as clobbered in the assembly block. This is a
problem if *other* code does write to a7. For some reason GCC 14.2 does
not recognise those other loads. GCC 14.3 and GCC 15 both work as
expected.

The problem manifests in SCHED0011 in sel4test.

This change works around the GCC 14.2 problem because GCC 14.2 is the
standard Debian trixie compiler and it is likely that people will hit
the problem even if we say that GCC 14.2 should not be used.

The workaround uses the same implementation of seL4_Yield as the Arm and
x86/x64 versions do: inline call to sys_null with an empty asm volatile
declaring memory as clobbered. The memory clobber declaration eliminates
the miscompilation, and overall the implementations are now consistent.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2026-05-08 08:45:52 +02:00
Bill Nguyen
daa0dfb147 manual: updated EPT invocations to make it clearer
...that these syscalls are only used to manage VCPU page tables.

Signed-off-by: Bill Nguyen <bill.nguyen@unsw.edu.au>
2026-04-28 08:22:34 +02:00
Bill Nguyen
79b104a3a1 manual: fix incorrect args desc for X86PageMapEPT
Fixed incorrect arguments descriptions for X86PageMapEPT, to make it
consistent with other invocations that take an EPT and guest physical
address such as X86EPTPTMap.

Signed-off-by: Bill Nguyen <bill.nguyen@unsw.edu.au>
2026-04-28 08:22:34 +02:00
Bill Nguyen
2bdafbf7c3 libsel4: fix attribute type for x86 EPT invocation
Signed-off-by: Bill Nguyen <bill.nguyen@student.unsw.edu.au>
2026-01-09 16:52:09 +11:00
Bill Nguyen
704f80b9be libsel4: fix incorrect seL4_VMEnter() description
SEL4_VMENTER_CALL_CONTROL_ENTRY_MR refers to the
VM Entry Interruption-Information Field of the VMCS [1].
Not the VM-Entry Controls, which are two different things.

[1]: src/arch/x86/object/vcpu.c: vcpu_update_state_sysvmenter()

Signed-off-by: Bill Nguyen <bill.nguyen@student.unsw.edu.au>
2025-12-08 23:09:51 +00:00
Gerwin Klein
19b78543f9 arm: complete SGI error conditions documentation
- add missing error codes and explanations
- add not on target check limitations

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2025-11-24 16:56:46 +11:00
Indan Zupancic
3cbd3b2e95 SGI, GICv3: Fix plat_SGITargetValid
Otherwise it is not possible to send SGIs to all cores on platforms
with non-contiguous Affinity values or more than 16 cores.

16 is the limit of the target list, which is only relevant when
sending an SGI to multiple targets at once.

Update the API documentation to reflect what's actually happening.

Signed-off-by: Indan Zupancic <indan@nul.nu>
2025-11-18 16:00:12 +11:00
Kent McLeod
34725d060b arm: Add new APIs for generating SGIs
Allow SGIs to be generated from non-SMP kernels.

Signed-off-by: Kent McLeod <kent@kry10.com>
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2025-07-07 08:50:47 +10:00
julia
eca86cff19 treewide: typo fixes
Signed-off-by: julia <git.ts@trainwit.ch>
2025-04-14 12:05:16 +10:00
julia
7f91e0c5f6 libsel4: fix riscv ASIDcontrol param descriptions
Nowhere else in the documentation uses the phrase

    "Must be a depth of 32"

which seems incorrect for 64-bit riscv.

Also, the index parameter had the same description as root, which
is incorrect.

Signed-off-by: julia <git.ts@trainwit.ch>
2025-02-12 11:00:03 +00:00
Indan Zupancic
cae4662a45 manual: params don't have errors
Signed-off-by: Indan Zupancic <indan@nul.nu>
2024-06-30 21:14:32 +10:00
Nick Spinale
a3f6be3c7c libsel4: add links in place of renamed XML files
This commit's parent renames the interface XML files.

The symlinks added in this commit serve to ease the transition to the
new names for downstream projects.

These links are added:

- include/interfaces/{sel4.xml -> object-api.xml}
- arch_include/*/interfaces/{sel4arch.xml -> object-api-arch.xml}
- sel4_arch_include/*/interfaces/{
    sel4arch.xml -> object-api-sel4-arch.xml
  }

Signed-off-by: Nick Spinale <nick@nickspinale.com>
2024-06-30 18:28:12 +10:00
Nick Spinale
dbd6efc507 libsel4: rename interface XML files
Before, some object API XML files conflicted when the include,
arch_include, and sel4_arch_include directories were combined:

- include/interfaces/sel4.xml
- arch_include/*/interfaces/sel4arch.xml
- sel4_arch_include/*/interfaces/sel4arch.xml

This commit renames them to:

- include/interfaces/object-api.xml
- arch_include/*/interfaces/object-api-arch.xml
- sel4_arch_include/*/interfaces/object-api-sel4-arch.xml

Now, when the include, arch_include, and sel4_arch_include directories
are combined, we are left with:

- interfaces/object-api.xml
- interfaces/object-api-arch.xml
- interfaces/object-api-sel4-arch.xml

Signed-off-by: Nick Spinale <nick@nickspinale.com>
2024-06-30 18:28:12 +10:00
hexcoder
15fa2cf9c2 manual: typos and style/grammar corrections
Co-authored-by: Gerwin Klein <gerwin.klein@proofcraft.systems>

Signed-off-by: hexcoder <heiko@hexco.de>
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2024-06-17 19:24:20 +10:00
Indan Zupancic
8cbc13d5b8 Manual: Document ARM Virtualisation
This resolves issue #1083.

Signed-off-by: Indan Zupancic <indan@nul.nu>
2024-06-17 00:37:00 +01:00
Birgit Brecknell
0d799c3706 fix autoref whitespace errors
Signed-off-by: Birgit Brecknell <bbrcknl@gmail.com>
2024-03-22 09:02:23 +00:00
Birgit Brecknell
31e82e81da wrap docref references in <docref> tag
Signed-off-by: Birgit Brecknell <bbrcknl@gmail.com>
2024-03-22 09:02:23 +00:00
bbrcknl
cbf25791b7
make method names consistent (#1144)
* make method names consistent; delete duplicates

Signed-off-by: Birg <bbrcknl@github.com>
2024-01-19 14:25:02 +11:00
Birg
9a532efc15 change CPTR to CPtr
Signed-off-by: Birg <bbrcknl@github.com>
2023-12-06 10:41:28 +00:00
Birg
391bfb15f8 update some manual todos
Signed-off-by: Birg <bbrcknl@github.com>
2023-11-29 10:21:32 +00:00
Alex Pavey
e62bc9bba3 smc_cap: Add SMC Capability with Call method
See PR at https://github.com/seL4/seL4/pull/701

Signed-off-by: Robbie VanVossen <robert.vanvossen@dornerworks.com>
2023-08-27 11:44:51 +10:00
Kent McLeod
b3cc852425 aarch64,vspace: Remove page_directory captype
The page_table cap is used in it's place.

Signed-off-by: Kent McLeod <kent@kry10.com>
2023-08-10 08:20:22 +10:00
Kent McLeod
7fec9bc9e9 Add CONFIG_X86_64_VTX_64BIT_GUESTS guards
Guard the new implementation of 64-bit x86 guests behind a config
option. This is done so that existing projects that use x86_64 hosts
with ia32-bit guests can continue to be supported until either the old
feature is preferred to be deprecated, or support can be added to
support both simmultaneously.

Signed-off-by: Kent McLeod <kent@kry10.com>
2023-06-06 13:29:34 +10:00
Chris Guikema
2dbd1b818a 64-bit-vms: Add kernel support for 64-bit VMs
This commit combines a number of smaller commits which do the following:

    * Enter IA-32e mode when running a 64-bit host
    * Handle additional general purpose registers in 64-bit mode
    * Handle 64-bit specific MSR events
    * Properly save and restore FS, GS, and Shadow GS registers

CCDC-GVSC DISTRIBUTION A.  Approved for public release; distribution
unlimited. OPSEC#4481.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-06-06 13:29:34 +10:00
Axel Heider
4d1da1002b libsel4: use sel4/config.h instead of autoconf.h
Make sel4/config.h the only file to eventually include autoconf.h

Signed-off-by: Axel Heider <axelheider@gmx.de>
2023-04-24 23:02:12 +10:00
Axel Heider
6e1bb9d2a8 cleanup deprecated.h header files
Add a comment that they are empty on purpose. They are not removed to
keep the infrastructure in case there will be deprecated items in the
future.

Signed-off-by: Axel Heider <axelheider@gmx.de>
2022-10-04 10:48:50 +11:00
Axel Heider
481ce9d5ed remove deprecated header files
Signed-off-by: Axel Heider <axelheider@gmx.de>
2022-10-04 10:48:50 +11:00
matt rice
97610e1249 xml: remove condition attribute
Signed-off-by: matt rice <ratmice@gmail.com>
2022-03-22 18:33:38 +11:00
matt rice
accccf3dbb add condition elem, test it against condition attr
Signed-off-by: matt rice <ratmice@gmail.com>
2022-03-22 18:33:38 +11:00
Axel Heider
d9196f27d9 trivial: remove trailing whitespaces
Signed-off-by: Axel Heider <axelheider@gmx.de>
2022-01-19 09:32:01 +11:00
Axel Heider
dae3d25ae3 risc-v: remove unused file bootinfo.h
Signed-off-by: Axel Heider <axelheider@gmx.de>
2022-01-04 19:07:06 +11:00
Axel Heider
d278b68ee2 align include guards for seL4_DebugSendIPI()
Align the API wrapper guards with the kernel syscall implementation,
the function is available if CONFIG_ENABLE_SMP_SUPPORT is set instead
of depending on CONFIG_MAX_NUM_NODES.

Signed-off-by: Axel Heider <axelheider@gmx.de>
2021-11-30 10:02:54 +11:00
Axel Heider
edbc81eba4 consolidate arm core specific constants
Signed-off-by: Axel Heider <axelheider@gmx.de>
2021-11-30 09:10:16 +11:00
Jimmy Brush
85bf4bb280 libsel4: idl: Document additional error codes
- seL4_FailedLookup in X86IOPageTableMap
- seL4_FailedLookup in ARM page invalidation operations
- seL4_FailedLookup in ARMASIDPoolAssign

Signed-off-by: Jimmy Brush <code@jimmah.com>
2021-10-17 15:02:45 +11:00
Jimmy Brush
45344a9503 libsel4: idl: Fix more punctuation in errors
Signed-off-by: Jimmy Brush <code@jimmah.com>
2021-10-17 15:02:45 +11:00
Jimmy Brush
062eb3cb45 libsel4: idl: Fix punctuation in errors
Signed-off-by: Jimmy Brush <code@jimmah.com>
2021-10-17 15:02:45 +11:00
Jimmy Brush
1740abff65 libsel4: idl: Add ASID errors
Signed-off-by: Jimmy Brush <code@jimmah.com>
2021-10-17 15:02:45 +11:00
Jimmy Brush
73180e0e8d libsel4: Document errors in IDL
Also, remove any detailed discussion of error codes from method
descriptions.

Fixes #499

Signed-off-by: Jimmy Brush <code@jimmah.com>
2021-10-17 15:02:45 +11:00
Chris Guikema
805a031d55 libsel4: add EPT attributes
In x86, EPT and normal mappings have different cache attributes. This
commit adds an enum for the EPT attributes.

Signed-off-by: Chris Guikema <chris.guikema@dornerworks.com>
2021-09-06 16:18:23 +10:00
Axel Heider
e4256d48fa libsel4: unify seL4 type definitions
Signed-off-by: Axel Heider <axelheider@gmx.de>
2021-04-06 16:15:01 +10:00
Axel Heider
11c435b803 libsel4: unify definitions in simple_types.h
Signed-off-by: Axel Heider <axelheider@gmx.de>
2021-04-01 10:33:41 +10:00
Axel Heider
e86364c975 libsel4: add missing macros.h include
Signed-off-by: Axel Heider <axelheider@gmx.de>
2021-04-01 10:33:41 +10:00
Axel Heider
ffa5c74666 libsel4: remove HAVE_AUTOCONF
Today the file autoconf.h is created by the CMake build system and thus
HAVE_AUTOCONF is always defined. Time to get rid of some legacy by
removing the check if HAVE_AUTOCONF is set.

Signed-off-by: Axel Heider <axelheider@gmx.de>
2021-04-01 10:33:41 +10:00
Axel Heider
73bde900b1 trivial: remove empty lines
Signed-off-by: Axel Heider <axelheider@gmx.de>
2021-04-01 10:33:41 +10:00
Axel Heider
800b2444a1 trivial: style and formatting
Signed-off-by: Axel Heider <axelheider@gmx.de>
2021-03-03 11:47:23 +01:00
Curtis Millar
0d35551966
riscv: Implement benchmark log buffer
Can now perform benchmarks on the kernel using the log buffer to trace
kernel behavior.

Signed-off-by: Curtis Millar <curtis.millar@data61.csiro.au>
2020-12-03 10:31:16 +11:00
Oliver Scott
6ad15c0f45 trivial: clean up code for C parser
Remove unused cases and add break in switch statements.
Add conditions to sel4arch.xml.
Change guard in capdl printing to correct TK1_SMMU.
Set KernelArmSMMU default to off.
Add types to aarch32 syscall_stub_gen.py.

Signed-off-by: Oliver Scott <Oliver.Scott@data61.csiro.au>
2020-10-28 17:30:42 +11:00
Kent McLeod
5a7d96a46c SMMU: Add initial write up of design documentation
- Add a chapter in the Hardware I/O Section
- Link API documentation back to chapter.

Co-authored-by: Qian Ge <Qian.Ge@data61.csiro.au>
Signed-off-by: Kent McLeod <kent@kry10.com>
2020-10-28 17:30:42 +11:00