Skip to content

Commit 256108f

Browse files
junjiemao1lijinxia
authored andcommitted
kconfig: add more help messages to config symbols
Add help messages to all visible symbols except those heap-related ones which will be dropped eventually. v2 -> v3 * Fix typos and misleading descriptions. v1 -> v2 * Per kconfig language, help messages shall have a larger indent level than the attributes. * Rephrase for clarify. Tracked-On: #1588 Signed-off-by: Junjie Mao <junjie.mao@intel.com> Reviewed-by: Anthony Xu <anthony.xu@intel.com>
1 parent 05bb7aa commit 256108f

File tree

1 file changed

+100
-29
lines changed

1 file changed

+100
-29
lines changed

hypervisor/arch/x86/Kconfig

Lines changed: 100 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,43 @@
11
choice
22
prompt "Platform"
33
default PLATFORM_SBL
4+
help
5+
The BIOS used on the target board.
46

57
config PLATFORM_UEFI
68
bool "UEFI"
79
select EFI_STUB
10+
help
11+
Select this if the target board uses UEFI.
812

913
config PLATFORM_SBL
1014
bool "SBL"
15+
help
16+
Select this if the target board uses Slim Bootloader.
1117

1218
endchoice
1319

1420
choice
1521
prompt "Hypervisor mode"
1622
default SHARING_MODE
23+
help
24+
Select the usage mode of the hypervisor.
1725

1826
config SHARING_MODE
1927
bool "Sharing mode"
28+
help
29+
In sharing mode, the first VM (called Service OS or SOS) is capable of
30+
managing the other VMs (called User OS or UOS) and trap/mediate their
31+
I/O accesses to physical devices.
2032

2133
config PARTITION_MODE
2234
bool "Partition mode"
2335
depends on PLATFORM_SBL
36+
help
37+
In partition mode, every VM owns part of the physical resources
38+
exclusively and runs with minimal interference from the others. The VM
39+
configurations are statically defined in the source.
40+
2441
endchoice
2542

2643
config PLATFORM
@@ -31,62 +48,84 @@ config PLATFORM
3148
config RELEASE
3249
bool "Release build"
3350
default n
51+
help
52+
Whether to build a release version of the hypervisor. Logs, serial
53+
console and hypervisor shell are available only in non-release
54+
(i.e. debug) builds. Assertions are not effective in release builds.
3455

3556
config MAX_VM_NUM
3657
int "Maximum number of VM"
3758
range 1 8
3859
default 4
60+
help
61+
The maximum number of virtual machines (VMs) the hypervisor can
62+
support. This is customizable per the use cases of the build. For
63+
general-purpose builds the maximum of physical cores can be used.
3964

4065
config MAX_VCPUS_PER_VM
4166
int "Maximum number of VCPUS per VM"
4267
range 1 8
4368
default 4
69+
help
70+
The maximum number of virtual CPUs the hypervisor can support in a
71+
single VM.
4472

4573
config MAX_PCPU_NUM
4674
int "Maximum number of PCPU"
4775
range 1 8
4876
default 8
4977

5078
config MAX_IOMMU_NUM
51-
int "Maximum number of iommu dev"
79+
int "Maximum number of IOMMU devices"
5280
range 1 2
5381
default 2
82+
help
83+
The maximum number of physical IOMMUs the hypervisor can support.
5484

5585
config STACK_SIZE
56-
hex "Capacity of each stack used in the hypervisor"
86+
hex "Capacity of one stack, in byte"
5787
default 0x2000
58-
59-
config LOG_BUF_SIZE
60-
hex "Capacity of logbuf"
61-
default 0x100000
88+
help
89+
The size of stacks used by physical cores. Each core uses one stack
90+
for normal operations and another three for specific exceptions.
6291

6392
config LOG_DESTINATION
6493
int "Bitmap of consoles where logs are printed"
6594
range 0 7
6695
default 7
6796
help
68-
A bitmap indicating the destinations of log messages. Currently there
69-
are 3 destinations available. Bit 0 represents the serial console, bit
70-
1 the SOS ACRN log and bit 2 NPK log.
97+
A bitmap indicating the destinations of log messages. Currently there
98+
are 3 destinations available. Bit 0 represents the serial console, bit
99+
1 the SOS ACRN log and bit 2 NPK log. Effective only in debug builds.
71100

72101
config CPU_UP_TIMEOUT
73102
int "Timeout in ms when bringing up secondary CPUs"
74103
range 100 200
75104
default 100
76105
help
77-
A 32-bit integer specifying the timeout in microsecond when waiting for
78-
secondary CPUs to start up.
106+
A 32-bit integer specifying the timeout in millisecond when waiting
107+
for secondary CPUs to start up.
79108

80109
choice
81110
prompt "serial IO type"
111+
depends on !RELEASE
82112
default SERIAL_MMIO if PLATFORM_SBL
83113
default SERIAL_PIO if PLATFORM_UEFI
114+
help
115+
Whether the physical serial port shall be accessed via memory-mapped
116+
registers or I/O ports.
84117

85118
config SERIAL_MMIO
86119
bool "MMIO"
120+
help
121+
Select this if the serial port shall be accessed via memory-mapped
122+
registers.
87123

88124
config SERIAL_PIO
89125
bool "PIO"
126+
help
127+
Select this if the serial port shall be accessed via in/out
128+
instructions.
90129

91130
endchoice
92131

@@ -95,16 +134,16 @@ config SERIAL_MMIO_BASE
95134
depends on SERIAL_MMIO
96135
default 0xfc000000
97136
help
98-
A 64-bit integer indicating the base physical address of the
99-
memory-mapped UART registers.
137+
A 64-bit integer indicating the base physical address of the
138+
memory-mapped UART registers.
100139

101140
config SERIAL_PIO_BASE
102141
hex "Base address of serial PIO region"
103142
depends on SERIAL_PIO
104143
default 0x3f8
105144
help
106-
The base of the UART ports. This is logically 16-bit but used as a
107-
64-bit integer.
145+
The base address of the UART ports. This is logically 16-bit but used
146+
as a 64-bit integer.
108147

109148
config MALLOC_ALIGN
110149
int "Block size in the heap for malloc()"
@@ -121,62 +160,86 @@ config HEAP_SIZE
121160

122161
config CONSOLE_LOGLEVEL_DEFAULT
123162
int "Default loglevel on the serial console"
163+
depends on !RELEASE
124164
range 0 6
125165
default 3
166+
help
167+
This indicates the maximum debug level of logs that will be available
168+
on the the serial console. The higher the number, the more logs will
169+
be available.
126170

127171
config MEM_LOGLEVEL_DEFAULT
128172
int "Default loglevel in memory"
173+
depends on !RELEASE
129174
range 0 6
130175
default 5
176+
help
177+
This indicates the maximum debug level of logs that will be available
178+
in the logbuf in memory which can be accessed by ACRN log in SOS. The
179+
higher the number, the more logs will be available.
131180

132181
config NPK_LOGLEVEL_DEFAULT
133182
int "Default loglevel for the hypervisor NPK log"
183+
depends on !RELEASE
134184
range 0 6
135185
default 5
186+
help
187+
This indicates the maximum debug level of logs that will be available
188+
via NPK log. The higher the number, the more logs will be available.
136189

137190
config LOW_RAM_SIZE
138191
hex "Size of the low RAM region"
139192
default 0x00010000
140193
help
141-
A 32-bit integer indicating the size of RAM region below address
142-
0x10000, starting from address 0x0.
194+
A 32-bit integer indicating the size of RAM region below address
195+
0x10000, starting from address 0x0.
143196

144197
config RAM_START
145198
hex "Address of the RAM region assigned to the hypervisor"
146199
default 0x6e000000 if PLATFORM_SBL
147200
default 0x00100000 if PLATFORM_UEFI
148201
help
149-
A 64-bit integer indicating the base address to where the hypervisor
150-
should be loaded to. If RELOC is disabled the bootloader is required to
151-
load the hypervisor to this specific address. Otherwise the hypervisor
152-
will not boot.With RELOC enabled the hypervisor is capable of relocating
153-
its symbols to where it is placed at, and thus the bootloader may not
154-
place the hypervisor at this specific address.
202+
A 64-bit integer indicating the base address to where the hypervisor
203+
should be loaded to. If RELOC is disabled the bootloader is required
204+
to load the hypervisor to this specific address. Otherwise the
205+
hypervisor will not boot. With RELOC enabled the hypervisor is capable
206+
of relocating its symbols to where it is placed at, and thus the
207+
bootloader may not place the hypervisor at this specific address.
155208

156209
config RAM_SIZE
157210
hex "Size of the RAM region assigned to the hypervisor"
158211
default 0x02000000
159212
help
160-
A 64-bit integer indicating the size of RAM assigned to the
161-
hypervisor. It is ensured at link time that the footprint of the
162-
hypervisor does not exceed this size.
213+
A 64-bit integer indicating the size of RAM assigned to the
214+
hypervisor. It is ensured at link time that the footprint of the
215+
hypervisor does not exceed this size.
163216

164217
config CONSTANT_ACPI
165218
bool "The platform ACPI info is constant"
166219
default n
220+
help
221+
Whether constant ACPI tables shall be used. If selected, the built-in
222+
ACPI tables, usually generated on target platforms by an offline tool,
223+
will be used. If not a fixup subroutine will be invoked to update the
224+
built-in tables after parsing the real ACPI tables at runtime.
167225

168226
config DMAR_PARSE_ENABLED
169227
bool
170228
default n if PLATFORM_SBL
171229
default y if PLATFORM_UEFI
230+
help
231+
Whether to parse the ACPI DMA Remapping tables at runtime.
172232

173233
config GPU_SBDF
174234
hex
175235
depends on DMAR_PARSE_ENABLED
176236
default 0x00000010
177237
help
178-
A 32-bit integer encoding the segment, bus, device and function of the
179-
GPU.
238+
A 32-bit integer encoding the segment, bus, device and function of the
239+
GPU. This integer consists of a 16-bit segment ID, 8-bit bus ID, 5-bit
240+
device ID and 3-bit function ID. As an example, for PCI device at
241+
00:02.0 in DRHD segment 0, this SBDF would be (0 << 16) | (0 << 8) |
242+
(2 << 3) | (0 << 0), i.e. 0x00000010.
180243

181244
config EFI_STUB
182245
bool
@@ -195,11 +258,19 @@ config MTRR_ENABLED
195258
config RELOC
196259
bool "Enable relocation"
197260
default n
261+
help
262+
When selected, the hypervisor will relocate itself to where it is
263+
loaded. This allows the bootloader to put the hypervisor image to
264+
wherever appropriate. Without relocation the bootloader must put the
265+
image to RAM_START, otherwise the hypervisor will not start up.
198266

199267
config IOMMU_INIT_BUS_LIMIT
200-
hex "bus limitation when iommu init"
268+
hex "Limit of PCI bus on IOMMU initialization"
201269
default 0xf if PLATFORM_SBL
202270
default 0xff if PLATFORM_UEFI
271+
help
272+
Any BDF with a bus ID smaller than or equal to this limit is mapped to
273+
the IOMMU domain of the first VM.
203274

204275
config MAX_PCI_DEV_NUM
205276
int "Maximum number of PCI dev"

0 commit comments

Comments
 (0)