Commit Graph

7354 Commits

Author SHA1 Message Date
David B. Kinder 27f0d2969a doc: clarify 2.7 release notes
Update description of passthrough device usecase additions, and improved
description of Issue #6631 (Kata broken)

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-21 18:13:16 -08:00
wenlingz cba39a1c2f version:2.8-unstable
Signed-off-by: wenlingz <wenling.zhang@intel.com>
2021-12-20 14:24:33 +08:00
Zhao Yakui 39e70b2678 ACRN/DM: Add the ADL-P GPU device_id to support GPU passthrough
Otherwise it will fail to set the GPU opregion/stolen_memory for guest VM in
course of GPU passthrough and the display can't work.

Tracked-On: #6988
Acked-by: Wang, Yu1 <yu1.wang@intel.com>
Signed-off-by: Zhao Yakui <yakui.zhao@intel.com>
2021-12-17 15:37:40 +08:00
David B. Kinder 7f6f27be00 doc: add v2.7 docs to version menu
Also cleaned out older versions from list, keeping v1.0,
v1.6.1, v2.0, v2.5, and v2.6.

The documentation for previous releases is still available (by editing
the URL to mention that release (e.g., /2.1/ ).

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-16 10:12:59 -08:00
David B. Kinder 88f8ab0a45 doc: finalize 2.7 release notes
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-15 20:36:34 -08:00
fuzhongl edbef20c02 Doc: release notes update
Adding the fixed and known issues in release notes.

Signed-off-by: fuzhongl <fuzhong.liu@eintel.com>
2021-12-15 20:25:07 -08:00
fuzhongl 32e853ccf0 Doc: Launch script update for acrn on qemu
To launch User VM, cpu_affinity parameter is needed for v2.7.

Signed-off-by: fuzhongl <fuzhong.liu@eintel.com>
Reviewed-by:   gvancuts <geoffroy.vancutsem@intel.com>
2021-12-15 18:58:04 -08:00
Yang,Yu-chu 29bc085db9 config-tools: remove unused python scripts under scenario_config
Remove following scripts and calling thread:
 - misc/config_tools/scenario_config/ivshmem_cfg_h.py
 - misc/config_tools/scenario_config/pci_dev_c.py
 - misc/config_tools/scenario_config/pt_intx_c.py
 - misc/config_tools/scenario_config/vm_configurations_c.py
 - misc/config_tools/scenario_config/vm_configurations_h.py

Tracked-On: #6962
Signed-off-by: Yang,Yu-chu <yu-chu.yang@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-16 10:07:12 +08:00
Reyes, Amy 9b30aa84a8 doc: Add formatting to Supported HW
- Format the HW table to improve look and feel / readability

Signed-off-by: Reyes, Amy <amy.reyes@intel.com>
2021-12-15 17:39:53 -08:00
jackwhich ad5cf0ea3e doc: update GSG and partitioned documentation
1. Update launch script and replace the apt-get command with apt in GSG documentation.
2. Update the tag to v2.7 in partitioned documentation.

Signed-off-by: zhongzhenx.liu <zhongzhenx.liu@intel.com>
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-15 13:37:42 -08:00
Reyes, Amy a8ea36318d doc: Supported HW
- Remove outdated information.
- Add new HW table.

Signed-off-by: Reyes, Amy <amy.reyes@intel.com>
2021-12-15 13:25:31 -08:00
David B. Kinder ae0820760a doc: add CSS color styles
Add some color styles we can use (via .. rst-class:: style directive) to
add color to rst tables.  Also introduce a centered class instead of
using the deprecated .. centered:: directive.  Update documentation
guidelines to describe these new styles (background colors).

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-14 16:58:16 -08:00
David B. Kinder 7c8004ab0d doc: fix $disk usage in GSG
The commands in the Getting Started Guide for copying files to and from
the USB stick will fail if the USB stick volume name has a space in it.
Fix this by quoting uses of $disk.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-14 10:42:42 -08:00
David B. Kinder 60097affd3 doc: update 2.7 release notes
Fix errors in description of changes.
Add mention of SOS -> Service_VM change in config options/values.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-13 21:27:13 -08:00
Yifan Liu 82778ccc9b hv_prebuild: Support LAPIC-PT only VM
Currently in sanitize_vm_config, all LAPIC-PT VM are treated as RTVM,
which can be relaxed: LAPIC PT VM does not have to be RTVM.

Change the logic in sanitize_vm_config to support this relaxation.

Tracked-On: #6968
Signed-off-by: Yifan Liu <yifan1.liu@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-14 09:55:02 +08:00
Xiangyang Wu 4f034c99a2 doc: remove suspend and resume command from acrnctl
Currently, the command "acrnctl suspend" and "acrnctl resume"
is not used by user. This patch removes related code.

Tracked-On: #5921
Signed-off-by: Xiangyang Wu <xiangyang.wu@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-14 09:52:31 +08:00
Xiangyang Wu 982d1565d5 Misc: acrnctl: remove suspend and resume command from acrnctl
Currently, the command "acrnctl suspend" and "acrnctl resume"
is not used by user. This patch removes related code.

v1-->v2:
	Remove vm_suspend.

Tracked-On: #5921
Signed-off-by: Xiangyang Wu <xiangyang.wu@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-14 09:52:31 +08:00
Yonghua Huang a778a0da00 doc: update 'asa.rst' for 2.7 release
Update security advisory 2.7 release.

Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-13 09:55:27 -08:00
Xiangyang Wu 097afee832 doc: add note about SRIOV disable
Currently, Service VM may fail to shut down due to some enabled
VFs. ACRN doesn't disable VFs automatically.

In this patch, add a note for user to disable VFs before Service
VM shuts down.

Tracked-On: #5921

Signed-off-by: Xiangyang Wu <xiangyang.wu@intel.com>
2021-12-13 09:38:23 -08:00
Yuanyuan Zhao 8f114d82af hv: rename CONFIG_IOMMU_BUS_NUM
Rename `CONFIG_IOMMU_BUS_NUM` to `ACFG_MAX_PCI_BUS_NUM`. Configure tool
will calculate `ACFG_MAX_PCI_BUS_NUM` base on the max pci num which is
used by VF. So user needn't care about `ACFG_MAX_PCI_BUS_NUM`, and memory
will be used resonable.

Tracked-On: #6942
Signed-off-by: Yuanyuan Zhao <yuanyuan.zhao@linux.intel.com>
Reviewed-by: Wang, Yu1 <yu1.wang@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-13 11:06:10 +08:00
Yang,Yu-chu ae998f157e config-tools: generate ACFG_MAX_PCI_BUS_NUM based on board.xml
Extract the max pci bus number from board information and generate the
common configuration macro ACFG_MAX_PCI_BUS_NUM automatically.

Tracked-On: #6942
Signed-off-by: Yang,Yu-chu <yu-chu.yang@intel.com>
2021-12-13 11:06:10 +08:00
Mingqiang Chi 3555aae4ac hv:remove 2 bits vmx capability check
remove is_valid_xsave_combination api,
assume the hardware or QEMU can guarantee that support
XSAVE on CPU side and XSAVE_XRSTR on VMX side or not.
will add offline-tool in QEMU platform to avoid the user
use wrong XSAVE configurations.
remov check VMX_PROCBASED_CTLS2_XSVE_XRSTR based on the above reason.
for VMX_PROCBASED_CTLS2_PAUSE_LOOP, now it will panic
if run ACRN over QEMU, here remove it from essential check,
and it will print error information when set this bit
if there is no the hardware capability.

v1-v2:
  remove is_valid_xsave_combination

Tracked-On: #6584
Signed-off-by: Mingqiang Chi <mingqiang.chi@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-13 08:52:52 +08:00
Yifan Liu 5c9456462b hv && config-tool: Add compilation option to disable all interrupts in HV
This patch adds an option CONFIG_KEEP_IRQ_DISABLED to hv (default n) and
config-tool so that when this option is 'y', all interrupts in hv root
mode will be permanently disabled.

With this option to be 'y', all interrupts received in root mode will be
handled in external interrupt vmexit after next VM entry. The postpone
latency is negligible. This new configuration is a requirement from x86
TEE's secure/non-secure interrupt flow support. Many race conditions can be
avoided when keeping IRQ off.

v5:
Rename CONFIG_ACRN_KEEP_IRQ_DISABLED to CONFIG_KEEP_IRQ_DISABLED

v4:
Change CPU_IRQ_ENABLE/DISABLE to
CPU_IRQ_ENABLE_ON_CONFIG/DISABLE_ON_CONFIG and guard them using
CONFIG_ACRN_KEEP_IRQ_DISABLED

v3:
CONFIG_ACRN_DISABLE_INTERRUPT -> CONFIG_ACRN_KEEP_IRQ_DISABLED
Add more comment in commit message

Tracked-On: #6571
Signed-off-by: Yifan Liu <yifan1.liu@intel.com>
Reviewed-by: Wang, Yu1 <yu1.wang@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-10 09:50:17 +08:00
Jie Deng 2fab18a6d6 hv: tee: avoid halt in REE bootargs
"idle=halt " should be avoided in REE since we have to
keep the interrupt always masked in root mode.

Tracked-On: #6571
Signed-off-by: Jie Deng <jie.deng@intel.com>
Reviewed-by: Wang, Yu1 <yu1.wang@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-09 10:47:16 +08:00
Yifan Liu fa6b55db68 hv: tee: Handling x86_tee secure interrupts corner cases
Previous upstreamed patches handles the secure/non-secure interrupts in
handle_x86_tee_int. However there is a corner case in which there might
be unhandled secure interrupts (in a very short time window) when TEE
yields vCPU. For this case we always make sure that no secure interrupts
are pending in TEE's vlapic before scheduling REE.

Also in previous patches, if non-secure interrupt comes when TEE is
handling its secure interrupts, hypervisor injects a predefined vector
into TEE's vlapic. TEE does not consume this vector in secure interrupt
handling routine so it stays in vIRR, but it should be cleared because the
actual interrupt will be consumed in REE after VM Entry.

v3:
    Fix comments on interrupt priority

v2:
    Add comments explaining the priority of secure/non-secure interrupts

Tracked-On: #6571
Signed-off-by: Yifan Liu <yifan1.liu@intel.com>
Reviewed-by: Wang, Yu1 <yu1.wang@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-09 10:47:16 +08:00
Yifan Liu fd7ab300a8 hv: tee: Rename TEE_NOTIFICATION_VECTOR to TEE_FIXED_NONSECURE_VECTOR
The TEE_NOTIFICATION_VECTOR can sometimes be confused with TEE's PI
notification vector. So rename it to TEE_FIXED_NONSECURE_VECTOR for
better readability.

No logic change.

v3:
Add more comments in commit message.

Tracked-On: #6571
Signed-off-by: Yifan Liu <yifan1.liu@intel.com>
Reviewed-by: Wang, Yu1 <yu1.wang@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-09 10:47:16 +08:00
Yifan Liu 702a71639f hv: Add two vlapic APIs
Sometimes HV would like to know if there are specific interrupt
pending in vIRR, and clears them if necessary (such as in x86_tee case).

This patch adds two APIs: get_next_pending_intr and clear_pending_intr.
This patch also moves the inline api prio() from
vlapic.c to vlapic.h

v3:
    Remove apicv_get_next_pending_intr and apicv_clear_pending_intr
    and use vlapic_get_next_pending_intr and vlapic_clear_pending_intr
    directly.

v2:
    get_pending_intr -> get_next_pending_intr
    apicv_basic/advanced_clear_pending_intr -> apicv_clear_pending_intr
    apicv_basic/advanced_get_pending_intr -> apicv_get_next_pending_intr
    has_pending_intr kept

Tracked-On: #6571
Signed-off-by: Yifan Liu <yifan1.liu@intel.com>
Reviewed-by: Wang, Yu1 <yu1.wang@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-09 10:47:16 +08:00
Yifan Liu 1d831cd3a2 hv: Add checks in pci_enumerate_ext_cap to guard against malformed lists
In pci_enumerate_ext_cap we assume the extended capability linked lists
are always legal and correct, which might not be true when there was a
faulty hardware. This patch adds checks (time to live) to guard against malformed
extended capability linked lists.

v2:
Add error printing when node_limit <= 0.

Tracked-On: #6571
Signed-off-by: Yifan Liu <yifan1.liu@intel.com>
Reviewed-by: Wang, Yu1 <yu1.wang@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-09 10:47:16 +08:00
Yifan Liu b59c489750 hv: Hide Service VM hypercalls from REE
Though REE VM has its load order to be Service_VM, it does not offer
services as Service VM does. The only hypercalls allowed for REE are the
ones with GUEST_FLAG_REE.

Tracked-On: #6571
Signed-off-by: Yifan Liu <yifan1.liu@intel.com>
Reviewed-by: Wang, Yu1 <yu1.wang@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-09 10:47:16 +08:00
Yifan Liu 98bc4cab35 hv: Wrap GUEST_FLAG_TEE/REE checks into function
This patch wraps the check of GUEST_FLAG_TEE/REE into functions
is_tee_vm/is_ree_vm for readability. No logic changes.

Tracked-On: #6571
Signed-off-by: Yifan Liu <yifan1.liu@intel.com>
Reviewed-by: Wang, Yu1 <yu1.wang@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-09 10:47:16 +08:00
Shiqing Gao 90c987b600 doc: simplify the command to build Zephyr for ACRN
Simplify the build command using the west tool.

Signed-off-by: Shiqing Gao <shiqing.gao@intel.com>
2021-12-08 18:23:42 -08:00
Xiangyang Wu 0b3fedee86 doc: update s5 document
For WaaG VM, the User VM name is hard coded in the
lifecycle manager, this User VM ("windows") is needed
for guest shutdown.
Note: libvirt will be used to do guest shutdown and
the WaaG VM name will be configurable in furture.

The lifecycle manager starup picture in WaaG VM is out
of data, update it in this patch.

Tracked-on: #6652
Signed-off-by: Xiangyang Wu <xiangyang.wu@intel.com>
2021-12-08 16:56:58 -08:00
Kunhui-Li 0a5663c442 config_tools: rename sdc.xml to shared.xml on qemu platform
rename sdc.xml to shared.xml on qemu platform

Tracked-On: #6315
Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
2021-12-08 14:04:37 +08:00
David B. Kinder 38d9227f79 doc: update release notes with cpu_affinity notice
The acrn-dm ``--cpu_affinity`` parameter is now mandatory.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-07 20:44:32 -08:00
Kunhui-Li 821c450520 config_tools:doc: sync with release_2.7 for XSD files
update "bootargs" documentation to keep with release_2.7 branch
in VMtype.xsd.

Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
2021-12-06 17:39:49 -08:00
Kunhui-Li 9a299effcb doc: update release notes for v2.7 on configuration upgrades
This patch updates recommendations to upgrade from a prior ACRN version
for v2.7, and updates the what's new summary.

Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2021-12-06 12:13:03 -08:00
Amy Reyes 48063c840b doc: Remove placeholder text from acrntrace
Removed placeholders for images. Will create an issue for tracking.

Signed-off-by: Amy Reyes <amy.reyes@intel.com>
2021-12-06 10:05:51 -08:00
Amy Reyes 22f4041d48 doc: terminology cleanup in hld/tutorial images
- Replace SOS or Service OS with Service VM
- Replace UOS or User OS with User VM

Signed-off-by: Amy Reyes <amy.reyes@intel.com>
2021-12-06 10:05:07 -08:00
Chenli Wei 7390488b8d hv: remove CONFIG_LOG_DESTINATION
The CONFIG_LOG_DESTINATION parameter selects where the logging messages
send to,serial console or memory or npk device MMIO region.

Now we want to remove it and check the loglevel of each channel,close the
output when the loglevel is ZERO.

Tracked-On: #6934
Signed-off-by: Chenli Wei <chenli.wei@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-06 14:24:40 +08:00
Kunhui-Li de5abd5265 config_tools: remove CONFIG_LOG_DESTINATION
1. remove LOG_DESTINATION in the related python code, schema and
all existing scenario XML files.
2. for MEM_LOGLEVEL, NPK_LOGLEVEL and CONSOLE_LOGLEVEL,
update the loglevel range to [0, 5] from [0, 6].

Tracked-On: #6934
Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2021-12-06 14:24:40 +08:00
Amy Reyes 28560c1db7 doc: terminology cleanup in RTVM tutorial
- Replace SOS or Service OS with Service VM
- Clean up some of the grammar

Signed-off-by: Amy Reyes <amy.reyes@intel.com>
2021-12-02 10:37:07 -08:00
Yonghua Huang 638027fca1 dm: fix memory leakage issue in acrn_parse_cpu_affinity
fix memory leakage issue in function 'acrn_parse_cpu_affinity()',
 memory pointed by 'cp' is not released before function return.

Tracked-On: #6919
Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
2021-12-02 16:12:14 +08:00
Hu Fenglin 55eccbbd6b deb-pkg: Support specifying board.xml and scenario.xml
Currently, if board.xml and scenario.xml are specified,
the variable $(BOARD) and $(SCENARIO) are path, but the
parameters passed in to generate debian package should be
board and scenario name. So add a conversion function to
ensure that the function passed to the generated debian
package is board and scenario name.

Tracked-On: #6688
Signed-off-by: Hu Fenglin <fenglin.hu@intel.com>
2021-12-02 14:40:52 +08:00
Amy Reyes 30875208a6 doc: terminology cleanup in openstack and hld images
- Replace SOS or Service OS with Service VM
- Replace UOS or User OS with User VM
- Replace VHM with HSM

Signed-off-by: Amy Reyes <amy.reyes@intel.com>
2021-12-01 11:25:11 -08:00
Amy Reyes 82eeaee55f doc: terminology cleanup in DM HLD
- Replace SOS or Service OS with Service VM
- Replace UOS or User OS with User VM
- Clean up some of the grammar

Signed-off-by: Amy Reyes <amy.reyes@intel.com>
2021-12-01 11:23:47 -08:00
Amy Reyes 8cbadb488f doc: terminology cleanup in secure boot GRUB
- Replace UOS or User OS with User VM
- Replace SOS or Service OS with Service VM
- Clean up some of the grammar

Signed-off-by: Amy Reyes <amy.reyes@intel.com>
2021-12-01 10:21:54 -08:00
Amy Reyes 7ffa2a4a5f doc: terminology cleanup in HLD overview
- Replace SOS or Service OS with Service VM
- Replace UOS or User OS with User VM
- Replace VHM with HSM

Signed-off-by: Amy Reyes <amy.reyes@intel.com>
2021-12-01 10:20:06 -08:00
Amy Reyes db1a6ee961 doc: terminology cleanup in Hybrid GSG, tutorials
- Replace SOS or Service OS with Service VM
- Replace UOS or User OS with User VM
- Capitalize ACRN Configurator

Signed-off-by: Amy Reyes <amy.reyes@intel.com>
2021-12-01 10:17:14 -08:00
Xiangyang Wu d16d0f00bc HV: update destination shorthand during x2apic ICR emulation
Currently, in RTVM with multi vCPUs, lapic pass through is
configured, each vCPU works in x2apic mode. When one vCPU sends
IPI to all other vCPUs through writes ICR register with virtual
value 0x00000000000c00f8, this ICR writting will be intercepted,
the hypervisor passes destination shorthand field 11B (All Excluding
Self) in the virtual ICR value into physical ICR value during IPI
emulation, this IPI will be sent to each physical CPU core
in the platform according to 10.6.1 Interrupt Command Register (ICR),
Vol 3, SDM.
One vCPU in User VM with lapic pass through configuration can
send IPI with destination shorthand (10B or 11B) and any vector
(such as NMI or reboot vector) to other vCPUs, this IPI will sent
other VMs in the platform by hypervisor, this interference may
cause other VMs hang.

In this patch, set "Destination Shorthand" field of the
ICR value as 00B (No Shorthand) since the emulation is done
through sending IPI to each VCPU in dmask one by one.

Tracked-On: #6908

Signed-off-by: Xiangyang Wu <xiangyang.wu@intel.com>
Reviewed-by: Chen, Jason CJ <jason.cj.chen@intel.com>
2021-12-01 09:54:35 +08:00
Xie, nanlin 50a0fb9ea6 misc: update CODEOWNERS for debug tools
Tracked-On: #5581
Signed-off-by: Xie, nanlin <nanlin.xie@intel.com>
2021-12-01 08:53:50 +08:00