Commit Graph

5104 Commits

Author SHA1 Message Date
Li Fei1 af8329394b hv: vpci: minor refine the vdev ownership data structure
Add a new field 'parent_user' to record the parent user of the vdev.  And refine
'new_owner' to 'user' to record who is the current user of the vdev. Like

-----------------------------------------------------------------------------------------------
vdev in    |   HV       |   pre-VM       |               SOS                   | post-VM
           |            |                |vdev used by SOS|vdev used by post-VM|
-----------------------------------------------------------------------------------------------
parent_user| NULL(HV)   |   NULL(HV)     |   NULL(HV)     |   NULL(HV)         | vdev in SOS
-----------------------------------------------------------------------------------------------
user       | vdev in HV | vdev in pre-VM |   vdev in SOS  |   vdev in post-VM  | vdev in post-VM
-----------------------------------------------------------------------------------------------

Tracked-On: #4550
Signed-off-by: Li Fei1 <fei1.li@intel.com>
Acked-by: Eddie Dong<eddie.dong@Intel.com>
2020-05-13 14:31:01 +08:00
Zide Chen 1bc5c7ac5b hv/acrn-config/efi-stuf: assign hvlog and ramoops buffer address < 256MB
If HV relocation is enabled, either ACRN efi-stub or GRUB relocates
hypervisor image above HPA 256MB, thus we put hvlog and ramoops buffer
under 256MB to avoid conflict with hypervisor owned address.

This patch hardcodes these addresses:

0xa00000 - 0xdfffff: 4MiB for ramoops buffer
0xe00000 - 0xffffff: 2MiB for hvlog buffer

However, user can customize them to other addresses as long as it's under
256MB, available in host e820, and SOS bootarg "nokaslr" is not specified.

If HV relocation is disabled, need to make sure that these buffer
addresses are not between HV_RAM_START and HV_RAM_START + HV_RAM_SIZE.

Tracked-On: #4760
Signed-off-by: Zide Chen <zide.chen@intel.com>
Reviewed-by: Jason Chen CJ <jason.cj.chen@intel.com>
2020-05-13 08:36:54 +08:00
Zide Chen be4797a10c efi-stub: don't relocate hypervisor to address lower than 256MB
With this patch, we relocate hypervisor image to HPA 256MB and above,
thus the hardcoded hvlog and ramoops buffer for SOS can safely reside at
addresses under HPA 256MB, given that 1:1 mapping between SOS GPA and HPA.

Tracked-On: #4760
Signed-off-by: Zide Chen <zide.chen@intel.com>
Reviewed-by: Jason Chen CJ <jason.cj.chen@intel.com>
2020-05-13 08:36:54 +08:00
wenlingz b64aa2b2f6 version:2.0-unstable
Signed-off-by: wenlingz <wenling.zhang@intel.com>
2020-05-12 09:36:17 +08:00
David B. Kinder b86e90532b doc: fix malformed acrn-issue references
Syntax of acrn-issue role was incorrect in fixed issues section

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-11 17:29:06 -07:00
David B. Kinder 956f1157e2 doc: edit 1.6.1 release notes
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-11 08:48:50 -07:00
David B. Kinder 0b18c9bdb4 doc: add 1.6.1 docs version menu choice
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-11 08:48:08 -07:00
fuzhongl 5ed7f889f1 Doc: releasenotes_1.6.1
Signed-off-by: fuzhongl <fuzhong.liu@intel.com>
2020-05-11 08:05:07 -07:00
guoqingxz fb65c42468 doc: update build ACRN doc
Signed-off-by: guoqingxz <guoqingx.q.zhang@intel.com>
2020-05-11 09:31:24 -04:00
fangfang.shen 2db40c9956 doc: update GSG for ACRN V1.6.1.
Signed-off-by: fangfang.shen <fangfang.shen@intel.com>
2020-05-10 14:35:54 -07:00
lirui34 0c36a93cee doc: update industry getting started guide to v1.6.1
Add instruction to launch multiple post launched VMs.

Signed-off-by: lirui34 <ruix.li@intel.com>
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-08 10:06:57 -07:00
David B. Kinder 5850f00880 doc: update libvirt guide
Clean up command-line formatting, reduce line length, prepare for
further technical review.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-08 08:32:41 -07:00
Conghui Chen d7e1f570d4 doc: cpu-sharing doc update
Update cpu-sharing document.

Signed-off-by: Conghui Chen <conghui.chen@intel.com>
2020-05-08 08:31:17 -07:00
Zide Chen 0a956c34c7 hv: add a new field cpu_affinity in struct acrn_vm
For post-launched VMs, the configured CPU affinity could be different
from the actual running CPU affinity. This new field acrn_vm->cpu_affinity
recognizes this difference so that it's possible that CREATE_VM
hypercall won't overwrite the configured CPU afifnity.

Change name cpu_affinity_bitmap in acrn_vm_config to cpu_affinity.
This is read-only in run time, never overwritten by acrn-dm.

Remove vm_config->vcpu_num, which means the number of vCPUs of the
configured CPU affinity. This is not to be confused with the actual
running vCPU number: vm->hw.created_vcpus.

Changed get_vm_bsp_pcpu_id() to get_configured_bsp_pcpu_id() for less
confusion.

Tracked-On: #4616
Signed-off-by: Zide Chen <zide.chen@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-05-08 11:04:31 +08:00
Zide Chen 0629c5c8c2 hv/acrn-config: changed name from cpu_affinity_bitmap to cpu_affinity
Tracked-On: #4616
Signed-off-by: Zide Chen <zide.chen@intel.com>
2020-05-08 11:04:31 +08:00
Sainath Grandhi bf1ff8c98f hv: Offload syncing PIR to vIRR to processor hardware
ACRN syncs PIR to vIRR in the software in cases the Posted
Interrupt notification happens while the pCPU is in root mode.

Sync can be achieved by processor hardware by sending a
posted interrupt notiification vector.

This patch sends a self-IPI, if there are interrupts pending in PIR,
which is serviced by the logical processor at the next
VMEnter

Tracked-On: #4777
Signed-off-by: Sainath Grandhi <sainath.grandhi@intel.com>
2020-05-08 10:01:07 +08:00
Yan, Like 869ccb7ba8 HV: RDT: add CDP support in ACRN
CDP is an extension of CAT. It enables isolation and separate prioritization of
code and data fetches to the L2 or L3 cache in a software configurable manner,
depending on hardware support.

This commit adds a Kconfig switch "CDP_ENABLED" which depends on "RDT_ENABLED".
CDP will be enabled if the capability available and "CDP_ENABLED" is selected.

Tracked-On: #4604
Signed-off-by: Yan, Like <like.yan@intel.com>
Reviewed-by: Vijay Dhanraj <vijay.dhanraj@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-05-08 08:50:13 +08:00
Yan, Like 277c668b04 HV: RDT: clean up RDT code
This commit makes some RDT code cleanup, mainling including:
- remove the clos_mask and mba_delay validation check in setup_res_clos_msr(), the check will be done in pre-build;
- rename platform_clos_num to valid_clos_num, which is set as the minimal clos_mas of all enabled RDT resouces;
- init the platform_clos_array in the res_cap_info[] definition;
- remove the unnecessary return values and return value check.

Tracked-On: #4604
Signed-off-by: Yan, Like <like.yan@intel.com>
2020-05-08 08:50:13 +08:00
Yan, Like f774ee1fba HV: RDT: merge struct rdt_cache and rdt_membw in to a union
A RDT resource could be CAT or MBA, so only one of struct rdt_cache and struct rdt_membw
would be used at a time. They should be a union.
This commit merge struct rdt_cache and struct rdt_membw in to a union res.

Tracked-On: #4604
Signed-off-by: Yan, Like <like.yan@intel.com>
Reviewed-by: Vijay Dhanraj <vijay.dhanraj@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com
2020-05-08 08:50:13 +08:00
Deb Taylor bfe2a1c525 Doc: Initial file: Config ACRN using OpenStack & libvert
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-05-07 16:12:10 -04:00
Zide Chen 64e0f498a7 doc: update hvlog kernel parameter descriptions
Signed-off-by: Zide Chen <zide.chen@intel.com>
2020-05-07 10:50:07 -07:00
Yonghua Huang c4ab748cb9 doc: update security advisory for 1.6.1 release
Update mitigations for security vulnerabilities
 for ACRN 1.6.1 release

Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-07 10:48:21 -07:00
David B. Kinder 765e40bdb1 doc: edit notes on serial connection need
Clarify wording on tutorial notes about needing a serial port connection.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-07 10:08:21 -07:00
Geoffroy Van Cutsem 7689b92ed0 doc: update Zephyr document to indicate a serial port is needed
Update the "Run Zephyr as the User VM" document to add a note indicating a
serial port connection to the platform may be needed to see the Zephyr output
depending on the scenario  used (SDC vs. industrial).

Tracked-On: #4553
Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2020-05-07 08:52:11 -07:00
Geoffroy Van Cutsem a69a5608da doc: add note to the Celadon User VM tutorial
Add a note to the "Run Celadon as the User VM" tutorial to indicate a serial
port connection to the platform (or change of the default config) may be needed
if the user uses a scenario other than SDC (the default one in the doc).

Tracked-On: #4554
Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2020-05-07 08:51:41 -07:00
yuhong.tao@intel.com b0ae9cfa2b HV: Config Splitlock Detection to be disable
#AC should be normally enabled for slpitlock detection, however,
community developers may want to run ACRN on buggy system.
In this case, CONFIG_ENFORCE_TURNOFF_AC can be used to turn off the
 #AC, to let the guest run without #AC.

Tracked-On: #4765
Signed-off-by: Tao Yuhong <yuhong.tao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-05-07 09:35:22 +08:00
Geoffroy Van Cutsem bf5d187539 devicemodel: remove obsolete argument from list of options
Remove the 'p' argument from the list as it is now obsolete and there is no
implementation for it in the code.

Tracked-On: #4732
Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2020-05-06 13:43:35 +08:00
Geoffroy Van Cutsem 97245363b1 doc: update `acrn-dm` parameters documentation
Update the documentation listing and describing all `acrn-dm` parameters as it
has gone out of sync with the actual implementation. Some parameters are missing
and others are now obsolete.

Tracked-On: #4732
Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2020-05-06 13:43:35 +08:00
Li Fei1 0c6b3e57d6 hv: ptdev: minor refine about ptirq_build_physical_msi
The virtual MSI information could be included in ptirq_remapping_info structrue,
there's no need to pass another input paramater for this puepose. So we could
remove the ptirq_msi_info input.

Tracked-On: #4550
Signed-off-by: Li Fei1 <fei1.li@intel.com>
2020-05-06 11:51:11 +08:00
Li Fei1 73335b7276 hv: ptirq: rename ptirq_lookup_entry_by_sid to find_ptirq_entry
We look up PTIRQ entru only by SID. So _by_sid could removed.
And refine function name to verb-obj style.

Tracked-On: #4550
Signed-off-by: Li Fei1 <fei1.li@intel.com>
2020-05-06 11:51:11 +08:00
Wei Liu da749bcf84 acrn-config: update tgl-rvp board information
Update tgl-rvp board information.

Tracked-On: #3854
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Terry Zou <terry.zou@intel.com>
2020-05-06 11:37:14 +08:00
Yin Fengwei 68269a559f gpa2hva: add INVAVLID_HPA return value check
For return value of local_gpa2hpa, either INVALID_HPA or NULL
means the EPT walking failure. Current code only take care of
NULL return and leave INVALID_HPA as correct case.

In some cases (if guest page table is filled with invalid memory
address), it could crash ACRN from guest.

Add INVALID_HPA return check as well.
Also add @pre assumptions for some gpa2hpa usages.

Tracked-On: #4730
Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
2020-05-06 11:29:30 +08:00
Wei Liu 0a3ca1974e acrn-config: fix log macros for board defconfig
fix macros log level for board defconfig.

Tracked-On: #4752
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2020-05-06 11:25:57 +08:00
Wei Liu d03d6e96e0 acrn-config: add clearlinux UOS for launch config xmls
add 6 clearlinux UOSes for launch config xmls.

Tracked-On: #4641
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
2020-05-06 11:25:57 +08:00
Wei Liu 1d1270766c acrn-config: enable gvtd for waag for nuc7/nuc6 board
enable gvtd for waag of nuc7/nuc6 board by default.

Tracked-On: #4641
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2020-05-06 11:25:57 +08:00
Wei Liu a94f04fb94 acrn-config: add 4 POST_STD_VM and 1 KATA_VM for industry config xmls
For nuc7/nuc6/whl-ipci5/whl-ipc-i7 board, add 4 POST_STD_VM and 1
KATA_VM in their industry config xmls, and assign PCPU0-1 to these
PRE_LAUNCHED_VM.

Tracked-On: #4641
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2020-05-06 11:25:57 +08:00
Wei Liu 624edea6af HV: assign PCPU0-1 to post vm by default
Assign PCPU0-1 to post-launched VM. The CPU affinity can be overridden
with the '--cpu_affinity' parameter of acrn-dm.

Tracked-On: #4641
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2020-05-06 11:25:57 +08:00
Wei Liu db14c2f89f acrn-config: parse KATA VM count number with vm_type 'KATA_VM'
Parse KATA VM count number from scenario config with vm_type 'KATA_VM'
and Remove MAX_KATA_VM_NUM from scenario config xmls.

Tracked-On: #4641
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2020-05-06 11:25:57 +08:00
Wei Liu 22aecf83e0 HV: modify CONFIG_HV_RAM_START for NUC7i7DNB
When boot ACRN hypervisor from grub multiboot, HV will be loaded at
CONFIG_HV_RAM_START since relocation is not supported in grub
multiboot1. The CONFIG_HV_RAM_SIZE in industry scenario will take
~330MB(0x14000000), unfortunately the efi memmap on NUC7i7DNB is
truncated at 0x6dba2000 although it is still usable from 0x6dba2000. So
from grub point of view, it could not find a continuous memory from
0x6000000 to load industry scenario. Per efi memmap, there is a big
memory area available from 0x40400000, so put CONFIG_HV_RAM_START to
0x41000000 is much safe for NUC7i7DNB.

Tracked-On: #4641
Signed-off-by: Victor Sun <victor.sun@intel.com>
2020-05-06 11:25:57 +08:00
David B. Kinder c431199f41 doc: fix misspellings
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-05 09:07:45 -07:00
David B. Kinder b0c7993309 doc: remove stray UTF-8 characters
Convert UTF-8 characters (typically pasted from Word for smart quotes
and such) into equivalent ASCII characters.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-04 16:16:32 -07:00
Deb Taylor 1df539b76c Doc: Updated "Advanced Guides" titles for naming consistency
Updated WaaG file

Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-05-04 13:17:02 -04:00
David B. Kinder f9824261e6 doc: fix broken link to touch monitor
Fixes: #4503

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-04 09:35:30 -07:00
David B. Kinder 58f779a069 doc: update HLD for hv_cpu_virt
Update HLD with @zidechen0 material

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-03 17:15:16 -07:00
Conghui Chen dcb809e824 doc: update cpu-sharing doc
change IORR to BVT, update affinity related info.

Signed-off-by: Conghui Chen <conghui.chen@intel.com>
2020-05-03 17:00:03 -07:00
Victor Sun 1675dabddc doc: build from source update
As acrn-hypervisor Makefile rule changed, the doc need to be changed
accordingly.

Signed-off-by: Victor Sun <victor.sun@intel.com>
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-05-03 16:34:08 -07:00
Victor Sun 829083c46f doc: hv elements update
The hypervisor configuration is integrated into scenario XML now,
update the elements description for hv section.

Some elements in launch XML are updated also.

Signed-off-by: Victor Sun <victor.sun@intel.com>
2020-05-03 16:34:08 -07:00
Victor Sun 3f5bfe5511 doc: reference code update for cpu sharing
The VM configuration struct initialization method is slightly changed
recently, so reference code for cpu shaing need to be changed
accordingly.

Signed-off-by: Victor Sun <victor.sun@intel.com>
2020-05-03 16:34:08 -07:00
Victor Sun 515e478282 doc: remove sdc2 and update industry scenario
Remove SDC2 scenario since usages under SDC2 could be supported by
INDUSTRY scenario which would support up to 7 post-launched VMs.

Signed-off-by: Victor Sun <victor.sun@intel.com>
2020-05-03 16:34:08 -07:00
David B. Kinder 0bd30017eb doc: update windows as UOS tutorial
Fix consistent spelling of GVT-g and malformed bullet list.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-29 15:38:27 -07:00