Commit Graph

5240 Commits

Author SHA1 Message Date
Sainath Grandhi e14cafe412 acrn-config: round HI_MMIO_START/HI_MMIO_END to the closest 1G
Rounding HI_MMIO_START, HI_MMIO_END to the closest 1G. This avoids
round up logic in the hypervisor.

Tracked-On: #4586
Signed-off-by: Sainath Grandhi <sainath.grandhi@intel.com>
2020-04-13 16:52:18 +08:00
Jian Jun Chen 159c9ec759 hv: add lock for ept add/modify/del
EPT table can be changed concurrently by more than one vcpus.
This patch add a lock to protect the add/modify/delete operations
from different vcpus concurrently.

Tracked-On: #4253
Signed-off-by: Jian Jun Chen <jian.jun.chen@intel.com>
Reviewed-by: Li, Fei1 <fei1.li@intel.com>
2020-04-13 11:38:55 +08:00
David B. Kinder 1e8269b5f7 doc: fix misspellings
Fix misspellings missed during regular reviews

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-10 08:58:54 -07:00
David B. Kinder a29ef9178e doc: remove /404.html redirect
Using a root-level /404.html as a redirect to the /latest/404.html
causes the URL shown in the browser to change so you can't see what the
error-causing URL was.  Instead of a redirect, copy the /latest/404.html
generated by Sphinx to /404.html and edited with a <base> tag that
specifies a base URL for all relative URLs on a page.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-09 14:21:46 -07:00
Li Fei1 74edf2e54b hv: vmcs: remove vmcs field check for a vcpu
The VMCS field is an embedded array for a vCPU. So there's no need to check for
NULL before use.

Tracked-On: #3813
Signed-off-by: Li Fei1 <fei1.li@intel.com>
2020-04-09 09:40:26 +08:00
Li Fei1 366214e567 hv: virq: refine pending event inject sequence
Inject pending exception prior pending interrupt to complete the previous instruction.

Tracked-On: #1842
Signed-off-by: Li Fei1 <fei1.li@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-04-09 09:40:00 +08:00
David B. Kinder 88a5212396 doc: update robots.txt exclusion list
Developers using google search can accidentally find older versions of
documents and lead to confusion.  While we do maintain previous release
documentation on the site, we should have a preference for the latest
documentation when using external search engines.  (Note the on-site
search always returns version-specific results.)

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-08 18:22:48 -07:00
David B. Kinder 296b666f5f doc: tweak 404 page for phone display
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-08 18:22:14 -07:00
David B. Kinder 1b5a49770e doc: fix 404 display on mobile devices
Fix display of 404 errors on mobile phones.  Also added some additional
wording for reporting errors.  (Last change, I hope :)

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-08 17:11:55 -07:00
David B. Kinder e91eee2ab6 doc: update custom CSS with additional styles
Add styles for multi-column display, and for auto-numbered instruction
steps used in some other projects.

Also updating the used page width to 1100px following experience
improvements noted on other sites.  Pages are hard to read when
displayed full-screen on really wide monitors.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-08 16:59:22 -07:00
David B. Kinder 5c35fa84ab doc: fix image size on 404 page
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-08 16:04:05 -07:00
David B. Kinder b67d88cab3 doc: fix 404 processing
Some additional tweaks to the publish script, image, and root-level
redirect to fix a redirect recursion problem.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-08 14:37:04 -07:00
David B. Kinder dffa75e50f doc: add a custom 404 page
Add a site-wide custom error page for broken references within the site.
Besides giving a better user experience, it's also easier to track
broken links to the site using google analytics (looking for hits to the
404.html page and noticing the referrer.

Note we only "publish" the custom 404.html when publishing the latest
documents (not for released versions) so we always get the latest
left-navigation menu when a 404 error occurs.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-08 12:53:37 -07:00
lirui34 f981ddbd1b doc: gsg quick setup script issue fix.
- Fix swupd mirror issue
- Fix bootloader config file not detect correctly issue

Signed-off-by: lirui34 <ruix.li@intel.com>
2020-04-08 11:49:49 +08:00
Tw e51d12d8cb sample: add sample script for launching xenomai RTVM
Add a launch script for xenomai RTVM.

Tracked-On: #4514
Signed-off-by: Tw <wei.tan@intel.com>
Reviewed-by: Binbin Wu <binbin.wu@intel.com>
2020-04-08 11:49:27 +08:00
Wei Liu 793e22a87a acrn-config: remove the same parameters and functions from launch_cfg_lib
Launch config should relay on library/common.py and launch_cfg_lib,
then remove the duplicate parameters and functions.

Tracked-On: #3854
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
Acked-by: Terry Zou <terry.zou@intel.com>
2020-04-08 10:19:17 +08:00
Wei Liu ba3c531e50 acrn-config: remove the same parameters and functions from scenario_cfg_lib
Scenario config should relay on library/common.py and scenario_cfg_lib,
then remove the duplicate parameters and functions.

Tracked-On: #3854
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
Acked-by: Terry Zou <terry.zou@intel.com>
2020-04-08 10:19:17 +08:00
Wei Liu ed8ac484ad acrn-config: remove the same parameters and functions from board_cfg_lib
Board config should relay on library/common.py and board_cfg_lib, then
remove the duplicate parameters and functions.

Tracked-On: #3854
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
Acked-by: Terry Zou <terry.zou@intel.com>
2020-04-08 10:19:17 +08:00
Wei Liu 78ce220eb9 acrn-config: expends parameters and functions to common lib
For purpose to refine the library/common and xx_cfg_lib, should have
to expands parameters and functions to common.py firstly.

Tracked-On: #3854
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
Acked-by: Terry Zou <terry.zou@intel.com>
2020-04-08 10:19:17 +08:00
Li Fei1 2d66d39529 hv: vpci: refine comment for pci_vdev_update_vbar_base
Refine why we set the base_gpa to zero for a vBAR.

Tracked-On: #3475
Signed-off-by: Li Fei1 <fei1.li@intel.com>
2020-04-08 10:15:34 +08:00
Li Fei1 572f755037 hv: vm: refine the devices unregistration sequence of vm shutdown
Conceptually, the devices unregistration sequence of the shutdown process should be
opposite to create.

Tracked-On: #4550
Signed-off-by: Li Fei1 <fei1.li@intel.com>
2020-04-08 10:13:37 +08:00
David B. Kinder 3a326056fd doc: some additional google analytics code
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-07 17:18:31 -07:00
David B. Kinder 7b969d15c0 doc: organize security advisory doc
Add headings to organize security advisory doc by release to make it a
bit easier to read.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-07 15:10:21 -07:00
David B. Kinder a5ef52094f doc: remove "Glossary" icon box on home page
Adding a big box for the glossary disturbed the home page layout and is
overkill for this one document. Adding the glossary to the left
navigation menu is sufficient.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-07 15:09:56 -07:00
David B. Kinder 415b6f5030 doc: add google analytics tag
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-07 15:08:44 -07:00
Sainath Grandhi 140077f225 acrn-config: Fixes for BAR remapping logic
This patch does the following
1) Removes the limitation on BAR size for 1 GB
2) Align the BAR address to the BAR size

Tracked-On: #4586
Signed-off-by: Sainath Grandhi <sainath.grandhi@intel.com>
Acked-by: Terry Zou <terry.zou@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2020-04-07 13:08:25 +08:00
Wei Liu dc7f218314 acrn-config: update IOMEM_INFO of tgl-rvp board
As we did in commit: 697f3fc09f, need
to update IOMEM_INFO for tgl-rvp.

Tracked-On: #4582
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2020-04-07 10:49:16 +08:00
Victor Sun e5777adf5e Makefile: support make with external configurations
Customer might have specific folder where stores their own configurations
for their customized scenario/board, so add TARGET_DIR parameter to support
option that build hyprvisor with specified configurations.

So valid usages are: (target = all | hypervisor)
 1. make <target>
 2. make <target> KCONFIG_FILE=xxx [TARGET_DIR=xxx]
 3. make <target> BOARD=xxx SCENARIO=xxx [TARGET_DIR=xxx]
 4. make <target> BOARD_FILE=xxx SCENARIO_FILE=xxx [TARGET_DIR=xxx]
 5. make <target> KCONFIG_FILE=xxx BOARD_FILE=xxx SCENARIO_FILE=xxx [TARGET_DIR=xxx]

If TARGET_DIR parameter is not specified in make command, hypervisor will be
built with board configurations under hypervisor/arch/x86/configs/ and scenario
configurations under hypervisor/scenarios/. Moreover, the configurations would
be overwritten if BOARD/SCENARIO files are specified in make command.

If TARGET_DIR parameter is specified in make command, hypervisor will be built
with configuration under that folder if no BOARD/SCENARIO files are specified.
When BOARD/SCENARIO files are available in make command, the TARGET_DIR is used
to store configurations that BOARD/SCENARIO file provided, i.e. Configurations
in TARGET_DIR folder will be overwritten.

Tracked-On: #4517

Signed-off-by: Victor Sun <victor.sun@intel.com>
2020-04-03 15:15:05 +08:00
Victor Sun 471f7e5b28 Makefile: parameters check for board and scenario
When user use make parameters to specify BOARD and SCENARIO, there might
be some conflict because parameter of KCONFIG_FILE/BOARD_FILE/SCENARIO_FILE
also includes BOARD/SCENARIO info. To simplify, we only alow below valid
usages:

 1. make <target>
 2. make <target> KCONFIG_FILE=xxx
 3. make <target> BOARD=xxx SCENARIO=xxx
 4. make <target> BOARD_FILE=xxx SCENARIO_FILE=xxx
 5. make <target> KCONFIG_FILE=xxx BOARD_FILE=xxx SCENARIO_FILE=xxx

Especially for case 1 that no any parameters are specified:
    a. If hypervisor/build/.config file which generated by "make menuconfig"
       exist, the .config file will be loaded as KCONFIG_FILE:
       i.e. equal: make <target> KCONFIG_FILE=hypervisor/build/.config

    b. If hypervisor/build/.config file does not exist,
       the default BOARD/SCENARIO will be loaded:
       i.e. equal: make <target> BOARD=$(BOARD) SCENARIO=$(SCENARIO)

Tracked-On: #4517

Signed-off-by: Victor Sun <victor.sun@intel.com>
2020-04-03 15:15:05 +08:00
Victor Sun 2db5ae08d1 Makefile: make hypervisor from specified Kconfig
When user finish doing "make menuconfig", the .config file is saved in
acrn-config/hypervisor/build/ by default. So current Makefile will check
whether this customized .config file exists and then continue to do
following make process. But this might not true in the real user case,
user could put this customized .config file anywhere.

To resolve this problem, the patch add a KCONFIG_FILE parameter to handle
such case. When KCONFIG_FILE is specified, hypervisor could build hypervisor
with the specific configuration file.

Tracked-On: #4517

Signed-off-by: Victor Sun <victor.sun@intel.com>
2020-04-03 15:15:05 +08:00
Sainath Grandhi 5958d6f65f hv: Fix issues with the patch to reserve EPT 4K pages after boot
This patch fixes couple of minor issues with patch 8ffe6fc6

Tracked-On: #4563
Signed-off-by: Sainath Grandhi <sainath.grandhi@intel.com>
2020-04-03 11:06:14 +08:00
Victor Sun 3888c444cc HV: misra fix for multiboot2.c
The patch fixed a few misra violations for multiboot2.c;

Tracked-On: #4419

Signed-off-by: Victor Sun <victor.sun@intel.com>
2020-04-03 09:01:24 +08:00
Yan, Like 70fa6dce53 hv: config: enable RDT for apl-up2 by default
Tracked-On: #4566
Signed-off-by: Yan, Like <like.yan@intel.com>
2020-04-02 13:55:35 +08:00
Yan, Like e66c27df77 acrn-config: enable CAT for industry scenario on APL-UP2 by default
Tracked-On: #4566
Signed-off-by: Yan, Like <like.yan@intel.com>
Signed-off-by: Liu, Wei <weix.w.liu@intel.com>
2020-04-02 13:55:35 +08:00
Yan, Like 0b384b7284 acrn-config: support generation of per vcpu clos configuraton
Added "vcpu_clos" to configuration XML, here is an example of VM2 with 2 vCPUs:
  <clos desc="Class of Service for Cache Allocation Technology. Please refer SDM 17.19.2 for details and use with caution.">
	<vcpu_clos>1</vcpu_clos>
	<vcpu_clos>0</vcpu_clos>
  </clos>

A macro will be generated in vm_configuration.h:
  #define VM2_VCPU_CLOS          {1U, 0U}

And the macro will be used in vm_configuration.c:
  struct acrn_vm_config vm_configs[CONFIG_MAX_VM_NUM] = {
	...
	{
		...
		.clos = VM2_VCPU_CLOS,
		...
	}
  }

Tracked-On: #4566
Signed-off-by: Yan, Like <like.yan@intel.com>
Reviewed-by: Victor Sun <victor.sun@intel.com>
2020-04-02 13:55:35 +08:00
Yan, Like 2997c4b570 HV: CAT: support cache allocation for each vcpu
This commit allows hypervisor to allocate cache to vcpu by assigning different clos
to vcpus of a same VM.
For example, we could allocate different cache to housekeeping core and real-time core
of an RTVM in order to isolate the interference of housekeeping core via cache hierarchy.

Tracked-On: #4566
Signed-off-by: Yan, Like <like.yan@intel.com>
Reviewed-by: Chen, Zide <zide.chen@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-04-02 13:55:35 +08:00
Binbin Wu fcd9a1ca73 hv: vtd: use local var instead of global var
In dmar_issue_qi_request, currently use a global var qi_status, which could
cause potential issue when concurrent call to dmar_issue_qi_request for different
DMAR units.
Use local var instead.

Tracked-On: #4535
Signed-off-by: Shiqing Gao <shiqing.gao@intel.com>
Signed-off-by: Binbin Wu <binbin.wu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-04-02 11:31:40 +08:00
David B. Kinder 58fc6eeec9 doc: add 1.6 to doc version menu
Update doc version choice selector with the 1.6 release

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2020-04-01 20:18:14 -07:00
Jack Ren aa5e978b06 version: 1.7-unstable
Signed-off-by: Jack Ren <jack.ren@intel.com>
2020-04-02 10:24:37 +08:00
Wei Liu 5c297be955 acrn-config: find 64-bit mmio for HI_MMIO_START/HI_MMIO_END
Find the 64-bit mmio window from /proc/iomem to generate HI_MMIO_START/HI_MMIO_END.

Tracked-On: #4569
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
Acked-by: Terry Zou <terry.zou@intel.com>
2020-04-02 09:54:09 +08:00
Wei Liu 697f3fc09f acrn-config: update IOMEM_INFO of native board config xml
Replace SYSTEM_INFO with IOMEM_INFO for board xml files.

Tracked-On: #4569
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
Acked-by: Terry Zou <terry.zou@intel.com>
2020-04-02 09:54:09 +08:00
Wei Liu 6a9319b685 acrn-config: dump iomem info from /proc/iomem
Need more information from iomem, so dump all the iomem information
from /proc/iomem to instead of system ram information.

Tracked-On: #4569
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
Acked-by: Terry Zou <terry.zou@intel.com>
2020-04-02 09:54:09 +08:00
Deb Taylor de3bc3faec Doc: Release Notes update based on DKinder edits
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-04-01 19:28:25 -04:00
Deb Taylor 9a805f6c6b Doc: Grammactical edits to Release Notes 1.6
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-04-01 14:28:31 -04:00
Deb Taylor f282e8de0a Doc: Minor grammatical updates to rt_industry.html and building_acrn_in_docker.html
Refer to PRs 4568 and 4559.

Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-04-01 11:38:54 -04:00
Sainath Grandhi 8ffe6fc67a hv: Reserve space for VMs' EPT 4k pages after boot
As ACRN prepares to support servers with large amounts of memory
current logic to allocate space for 4K pages of EPT at compile time
will increase the size of .bss section of ACRN binary.

Bootloaders could run into a situation where they cannot
find enough contiguous space to load ACRN binary under 4GB,
which is typically heavily fragmented with E820 types Reserved,
ACPI data, 32-bit PCI hole etc.

This patch does the following
1) Works only for "direct" mode of vboot
2) reserves space for 4K pages of EPT, after boot by parsing
platform E820 table, for all types of VMs.

Size comparison:

w/o patch
Size of DRAM            Size of .bss
48 GB                   0xe1bbc98 (~226 MB)
128 GB                  0x222abc98 (~548 MB)

w/ patch
Size of DRAM            Size of .bss
48 GB                   0x1991c98 (~26 MB)
128 GB                  0x1a81c98 (~28 MB)

Tracked-On: #4563
Signed-off-by: Sainath Grandhi <sainath.grandhi@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-04-01 21:13:37 +08:00
lirui34 24cfdacb99 doc: update industry gsg to v1.6 release
- Update quick setup script to support whl board.
- Change board to WHL NUC.
- Change the Service VM disk to NVMe.
- Update CL version to 32680 and ACRN tags info.
- Update CL and acrn tag versions for waag user vm tutorial.

Signed-off-by: lirui34 <ruix.li@intel.com>
2020-04-01 05:42:15 -04:00
fuzhongl 0244bcaf5d Doc: releasenotes_1.6
Signed-off-by: fuzhongl <fuzhong.liu@intel.com>
2020-04-01 05:40:09 -04:00
fangfang.shen 122b2185ce Doc: update building acrn in docker for V1.6
One known issue :acrn-issue:`4560` during build ACRN HV.
Please refer to  next section to get Docker Image from Docker Hub.

Signed-off-by: fangfang.shen <fangfang.shen@intel.com>
2020-04-01 05:38:22 -04:00
Sainath Grandhi a19bcec6b9 acrn-config: Limit check on Pre-Launched VM RAM size
size and size_hpa2 can be greater than 2GB for Pre-Launched VMs.

Tracked-On: #4565
Signed-off-by: Sainath Grandhi <sainath.grandhi@intel.com>
2020-04-01 16:39:21 +08:00