Skip to content

Commit f7d7828

Browse files
Geoffroy Van Cutsemdbkinder
authored andcommitted
Documentation: add pictures to Trusty documentation
A couple of diagram were written using text characters. This commit changes that to use pictures instead. Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
1 parent d241795 commit f7d7828

File tree

4 files changed

+12
-58
lines changed

4 files changed

+12
-58
lines changed
45.1 KB
Loading
17.6 KB
Loading

doc/developer-guides/trusty.rst

Lines changed: 6 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -25,26 +25,9 @@ there's a desire to keep things small and lightweight. LK has been chosen as the
2525
Trusty Architecture
2626
*******************
2727

28-
Trusty Architectural diagram::
29-
30-
+---------------------------+
31-
|VMn |
32-
| ...... |
33-
+------------+ +---------------------------+ |
34-
|VM0 | |VM1 | |
35-
| | | +--------+ +--------+ | |
36-
| | | | | | | | |
37-
| SOS | | | Normal | | Secure | | |
38-
| | | | World | | World | |-+
39-
| | | | | | | |
40-
| | | +--------+ +--------+ |
41-
+------------+ +---------------------------+
42-
+-------------------------------------------+
43-
| ACRN Hypervisor |
44-
+-------------------------------------------+
45-
+-------------------------------------------+
46-
| HW |
47-
+-------------------------------------------+
28+
.. figure:: images/trusty-arch.png
29+
:align: center
30+
:name: Trusty Architectural diagram
4831

4932
.. note::
5033
Trusty OS is running in Secure World in the architecture drawing above.
@@ -118,39 +101,9 @@ modify Normal World's EPT during runtime such as increasing memory, changing att
118101
etc. If such behavior happened, only PD and PT for Normal World need to
119102
be updated.
120103

121-
::
122-
123-
ABSTRACT EPT hierarchy for 2 Worlds:
124-
==================================================================== ==================================================
125-
: Normal World : : Secure World :
126-
: PML4 : : PML4 :
127-
: +--------+ : : +--------+ :
128-
: | | : : | | :
129-
: | | : : PD | | :
130-
: | | : : +-------+ | | :
131-
: | | : : | | | | :
132-
: | 0-512G |--+ : : | | +--| 0-512G | :
133-
:EPTP -->+--------+ | : : | | | +--------+<-- EPTP :
134-
: | PDPT : : | | PDPT | :
135-
: | +--------+ : : | | +--------+ | :
136-
: | | >=511G |---> Not present : : +-------+<--| >=511G | | :
137-
: | |________| : : |________| | :
138-
: | | | : : | | | :
139-
: | | <511G |->+<----------------------------:--------:--------------| <511G | | :
140-
: | | | | : : | | | :
141-
: +-->+--------+ | PD PT : : +--------+<-+ :
142-
: | ... ... : ==================================================
143-
: | +-------+ +-------+ :
144-
: | +-------+| +-------+| :
145-
: | | || | || :
146-
: | | || | || :
147-
: | | PDE |--+ | || :
148-
: | | || | | || :
149-
: | | |+ | | |+ :
150-
: +-->+-------+ +-->+-------+ :
151-
: :
152-
====================================================================
153-
104+
.. figure:: images/ept-hierarchy.png
105+
:align: center
106+
:name: EPT hierarchy
154107

155108
API
156109
===

hypervisor/include/common/hypercall.h

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -334,11 +334,12 @@ int64_t hcall_get_cpu_pm_state(struct vm *vm, uint64_t cmd, uint64_t param);
334334
/**
335335
* @brief Switch vCPU state between Normal/Secure World.
336336
*
337-
* * Hypervisor uses the Secure Monitor Code (SMC) instruction to do
338-
* the world switch
339-
* * The hypervisor needs to save current world vCPU contexts, and load
340-
* the next world vCPU contexts
341-
* * Updates ``rdi``, ``rsi``, ``rdx``, ``rbx`` to next world vCPU contexts
337+
* * The hypervisor uses this hypercall to do the world switch
338+
* * The hypervisor needs to:
339+
* * save current world vCPU contexts, and load the next world
340+
* vCPU contexts
341+
* * update ``rdi``, ``rsi``, ``rdx``, ``rbx`` to next world
342+
* vCPU contexts
342343
*
343344
* @param vcpu Pointer to VCPU data structure
344345
*

0 commit comments

Comments
 (0)