Commit Graph

1405 Commits

Author SHA1 Message Date
Chuang Ke 68a7854052 [Workshop] Configurator create scenario popup window disappear sometimes
fix: 1. popup window won't be close when user click  background
2.close popup window do cancel function related

Tracked-On: #7991
Signed-off-by: Chuang-Ke <chuangx.ke@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-24 11:05:28 +08:00
Chuang Ke 2e4a373abb [config_tool] vUART widget address for pre-launched VM doesn't update
when the VM of a vUART endpoint changes the configurator can clear its corresponding I/O port or BDF settings automatically

Tracked-On: #8033
Signed-off-by: Chuang-Ke <chuangx.ke@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-24 10:27:52 +08:00
Chenli Wei 0609250743 misc: add assert to check the RTVM CPU affinity
The current ACRN Configurator have no warning when the user set CPU zero
to RTVM.

This patch add an assert to check the above.

Tracked-On: #6690
Signed-off-by: Chenli Wei <chenli.wei@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-24 08:28:26 +08:00
Chenli Wei e44b1b84ea misc: add cpu details to launch script
The current code use cpu_id in scenario xml and use apic_id of the pCPU
in the launched script, this confuses the user, especially the same name
"cpu_affinity" is used for these script.

So this patch add some comment to launched script to explain the
relationship between cpu_id and apic_id.

Tracked-On: #6690
Signed-off-by: Chenli Wei <chenli.wei@linux.intel.com>
2022-08-23 16:40:25 +08:00
Chenli Wei fa818d7b83 misc: refine the ACRN Configurator error message
The current ACRN Configurator show the XML name instead of DX-friendly
name when user delete the default value of some numeric field.

This patch add some "acrn:errormsg" which will show the DX-friendly name
to fix the above issue.

Tracked-On: #6690
Signed-off-by: Chenli Wei <chenli.wei@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-22 15:33:23 +08:00
David B. Kinder 946d5f274a Fix sample app histogram display
Improve graph labels and align histogram bars on x-axis labels
Add n= value to show it's not a static image.

Tracked-On: #8025

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2022-08-20 11:56:56 +08:00
Yuanyuan Zhao 1993bc8283 config_tools: change some default value
Change default user vm memory size from 256 to 1024.

Tracked-On: #8018
Signed-off-by: Yuanyuan Zhao <yuanyuan.zhao@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-19 12:28:45 +08:00
Yuanyuan Zhao 32bc596129 config_tool: add MAX_PCI_BUS_NUM in UI
Add MAX_PCI_BUS_NUM in UI for user.
If user defined MAX_PCI_BUS_NUM is greater than the value
calculated by board.xml, use user defined MAX_PCI_BUS_NUM.

Tracked-On: #8018
Signed-off-by: Yuanyuan Zhao <yuanyuan.zhao@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-19 12:28:45 +08:00
Liu Long 42f0878f0a SampleApplication: Disable the schroot mapping.
Disable the schroot mapping data from native env to the
chroot env.

Tracked-On: #7820
Signed-off-by: Liu Long <long.liu@linux.intel.com>
2022-08-18 11:27:09 +08:00
Chenli Wei 93b4a6e45d SampleApplication: Update the image create scripts
Update the rc.local for User VM, check the echo result and try again
if the echo failed.

Tracked-On: #7820
Signed-off-by: Chenli Wei <chenli.wei@linux.intel.com>
2022-08-18 09:32:42 +08:00
Liu Long e6de2e5798 SampleApplication: Update the image create scripts
1. Delete the generated images if the create scripts failed.
2. Enable root user login on GUI.
3. Enable systemd service in case there are many error logs.

Tracked-On: #7820
Signed-off-by: Liu Long <long.liu@linux.intel.com>
2022-08-17 18:30:14 +08:00
Chenli Wei 7f3174f740 misc: add a uio init setting
We need set uio when the hmi and rt user VM setup, so creat a rc.local
in the '/etc' and run it after system setup.

Tracked-On: #6690
Signed-off-by: Chenli Wei <chenli.wei@linux.intel.com>
2022-08-17 18:00:39 +08:00
Chuang Ke e47d0e2b2a [config_tool] v2 show warning message when users attempt to create a new scenario
fix warning message when users attempt to create a new scenario, or import an existing scenario, for an existing configuration
v1-->v2: update text to align with the design prototype spec.

Tracked-On: #7898
Signed-off-by: Chuang-Ke chuangx.ke@intel.com
Reviewed-by: Junjie Mao junjie.mao@intel.com
2022-08-17 16:48:43 +08:00
Chuang Ke 731d2171c7 [config_tool] Real time vCPU checkbox is confusing to users
add tooltip to explain "Real-time vCPU"
use the one generated from the XSD files to generate tooltip infomation.

Signed-off-by: Chuang-Ke <chuangx.ke@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
Tracked-On: #8000
2022-08-17 16:13:43 +08:00
David B. Kinder 9f0998af3e doc: remove use of :term: role in tooltip
The configurator can't process :term: glossary references, so remove it.

Tracked-On: #5692

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2022-08-17 10:51:26 +08:00
David B. Kinder b82805f77b doc: add tooltip for real-time vCPU option checkbox
Tracked-On: #9779

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2022-08-17 10:20:56 +08:00
chuangxke 206505453e Focus change to new VM when added
the focus  change to that new VM on the Basic tab when the new VM  added

Tracked-On: #7914
Signed-off-by: Chuang-Ke <chuangx.ke@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-17 10:04:51 +08:00
Wu Zhou c7b00e134f config-tools: change 'DISABLED' settings to 'ENABLED' in config xml
In order to improve DX, 'DISABLED' style configurator settings are
changed to 'ENABLED' style. The config xml files need too be changed
accordingly.

Including:
  - MCE_ON_PSC_DISABLED -> MCE_ON_PSC_ENABLED
  - ENFORCE_TURNOFF_AC -> SPLIT_LOCK_DETECTION_ENABLED
  - ENFORCE_TURNOFF_GP -> UC_LOCK_DETECTION_ENABLED

Tracked-On: #7661

Signed-off-by: Wu Zhou <wu.zhou@intel.com>
2022-08-17 09:23:33 +08:00
Wu Zhou 21d10af9d5 config-tools: change 'DISABLED' settings to 'ENABLED'
Some configurator settings are defined as 'feature DISABLED' style, which
could cause confusion to developers. This patch is to change them into
straightforward 'ENABLED' style.

Including:
  - MCE_ON_PSC_DISABLED -> MCE_ON_PSC_ENABLED
  - ENFORCE_TURNOFF_AC -> SPLIT_LOCK_DETECTION_ENABLED
  - ENFORCE_TURNOFF_GP -> UC_LOCK_DETECTION_ENABLED

Tracked-On: #7661

Signed-off-by: Wu Zhou <wu.zhou@intel.com>
2022-08-17 09:23:33 +08:00
zihengL1 b026238a69 config-tools: modified requirements.txt and update GSG
Modified requirements.txt in misc/config_tools/configurator
directory and add GSG requirements.txt inmisc/config_tools
directory.
Relevant python package installing steps in GSG.

Tracked-On: #7975
Reviewed-by: Junjie Mao junjie.mao@intel.com
Signed-off-by: Ziheng Li <ziheng.li@intel.com>
2022-08-16 17:20:23 +08:00
Chuang Ke 815d9b45c6 configurator does not consider L3 CAT config when opening an exiting configuration
1. rewrite function to match xml data structure  to fix the bug
2. fix inconsistency in one function ( data push order change accordingly)

Tracked-On: #7927
Signed-off-by: Chuang-Ke <chuangx.ke@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-16 16:21:48 +08:00
Kunhui-Li e906270dd3 config_tools: highlight success or fail status in save window
changing the green or yellow icon to highlight success or fail status
in save window.

Tracked-On: #7958
Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
2022-08-15 14:15:25 +08:00
Liu Long 237d07b9bd ACRN:SampleApplication: Copy RT kernel scripts
Add the copy RT kernel for the create image scripts.

Tracked-On: #7820
Signed-off-by: Liu Long <long.liu@linux.intel.com>
2022-08-15 11:17:51 +08:00
Liu Long c59dcc0042 ACRN:SampleApplication: Update the image build scripts
1. Add the generic extra kernel modules for HMI VM, in case the
uio_pci_generic modules is missed.
2. Add ssh server for HMI VM.
3. Add specific version for python numy modules.

Tracked-On: #7820
Signed-off-by: Liu Long <long.liu@linux.intel.com>
2022-08-15 09:19:15 +08:00
Liu Long a4094b9eeb ACRN: Scripts: Modify the create images scripts
1. Create a build directory for store images so that the git will not trace the
images.
2. Disable more systemd server in RT-VM in case the error output in
console.
3. Add the make sampleapplication command in the scripts.

Tracked-On: #7820
Signed-off-by: Liu Long <long.liu@linux.intel.com>
2022-08-15 09:19:15 +08:00
David B. Kinder 4ef991effb doc: add MCE check avoidance explanation
Add a reference to the intel.com white paper on MCE avoidance to the
Disable MCE Workaround configuration option

Tracked-On: #7978

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2022-08-12 16:48:49 +08:00
zihengL1 22184ac99a config-tools: solve hv and vm memory address conflict
Fixed the problem that acrn can still build normally
when the memory addresses of HV and VM conflict, which
causes the hypervisor to hang.

At the same time, defined a class to process memory to
obtain and check the available memory range.
Memory range obtain and check related functions are
defined as class methods.

Tracked-On: #7913
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
Signed-off-by: Ziheng Li <ziheng.li@intel.com>
2022-08-12 16:26:50 +08:00
Chenli Wei a7397dedf0 misc: add assert to check the vBDF conflict
The current ACRN-Configurator just check the conflict of user setting.
have not check the conflict with native PCI device's bdf.

This patch add an assert to check the above conflict.

Tracked-On: #6690
Signed-off-by: Chenli Wei <chenli.wei@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-11 15:34:21 +08:00
Liu Long a72a2e1795 SampleApplication: Add the proxy setting for HMI
Add the proxy config file for the HMI VM images, in case install
the packages failed.

Tracked-On: #7820
Signed-off-by: Liu Long <long.liu@linux.intel.com>
2022-08-10 16:21:37 +08:00
David B. Kinder b8c85135d9 doc: update Security VM Features config option
Updated the description of Security VM Features per review comments, and
made the option visible (again) in the configurator as an advanced
hypervisor option.

Created a new glossary entry for "Security VM", referenced by this new
description and tooltip.

Tweak wording of virtio console and input device descriptions.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>

Tracked-On: #7968
2022-08-10 10:09:58 +08:00
Chuang Ke 481173bf50 v2-config_tool-Instruction-missing-for-L2-only-users
v1-->v2:
1. instruction displayed regardless of if L3 or L2 cache were available, now it displayed instructions accordingly no matter how many caches
2. let instructions displayed only once above the topmost CAT configuration table

Tracked-On: #7921
Signed-off-by: Chuang-Ke <chuangx.ke@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-09 22:15:27 +08:00
Kunhui-Li b5097ee3e3 config_tools: fix vBDF schema pattern issue
add escape charater to fix vBDF pattern match any character issue
for vUART and ivshmem.

Tracked-On: #7925
Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-09 21:45:47 +08:00
Junjie Mao 3f0eb96d85 sample_app: Add scripts to create RT and HMI VM images
Creating VM images is always a pain to users, and it is especially the case
for those who want to set up the ACRN sample application which needs two
different VM images, one with graphical desktop and the other optimized for
real-time.

This patch introduces the so-called "image builder" utility which is a set
of scripts that can automate the creation of those VM images. The scripts
will take care of:

  - Forking image files based on Ubuntu cloud images and enlarge the root
    file system per needs.

  - Setting up users and passwords.

  - Installing necessary packages to run either the graphical desktop or
    real-time applications.

  - Specific to the RT VM image, disabling services and tweaking kernel
    command line for optimized real-time performance.

  - Copying the sample applications into the images so that users can
    start them directly, after they launch the VMs.

Tracked-On: #7820
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
2022-08-08 08:26:43 +08:00
Chuang Ke 88ed588711 vUART and IVSHMEM widgets don't generate address
[config_tool] vUART and IVSHMEM widgets don't generate address

Tracked-On: #7942
Signed-off-by: Chuang-Ke <chuangx.ke@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-05 16:43:32 +08:00
weizhang ddefbfa6b9 SampleApplication: Change the unit of result
Correct the unit of sample-application result, which should be us(microseconds).

Tracked-On #7820
Signed-off-by: Zhang Wei <wei6.zhang@linux.intel.com>
2022-08-05 10:35:10 +08:00
Junjie Mao 2a8b80d0c1 config_tools: board_inspector: guess L3 CAT parameters if not reported via CPUID
On some platforms the L3 CAT capabilities are not reported via CPUID even
though they are present. The public real-time tuning guide suggests to try
accessing the MSRs directly to detect if L3 CAT is available or not.

This patch implements such guessing logic in the board inspector in order
to enable CAT for users with those kinds of platforms.

Tracked-On: #7948
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
2022-08-05 07:36:40 +08:00
Junjie Mao 67d7b8f4c8 config_tools: board_inspector: fix MSR reads and writes
The MSR reading and writing routines today has the following issues:

  1. The missing of /dev/cpu/*/msr is not properly captured as it is
     reported via FileNotFoundError rather than IOError.

  2. The wrmsr logic is not updated to use the tmpdevfs msr file.

This patch fixes the issues above which is a prerequisite of adding
additional MSR parsing classes.

Tracked-On: #7948
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
2022-08-05 07:36:40 +08:00
Junjie Mao a6614e7e2f config_tools: board_inspector: refactors MSR utilities
In v3.0 the msrfield class has its initializer changed in a way that is
incompatible with the parameter names or the getter/setter. When introduced
from the BITS project, that class allows specifying an MSR field of
arbitrary length by being given the index of the most and least significant
bits.

This patch restores the original behavior of that msrfield class and moves
the use-case specific methods, namely is_vmx_cap_supported and
is_ctrl_setting_allowed, to a helper class.

Parsing of the VMX capability reporting MSRs in msr.py are updated
accordingly, and brief documentation of the MSR fields are added as well.

Tracked-On: #7948
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
2022-08-05 07:36:40 +08:00
Junjie Mao 4369896549 config_tools: acpi_gen: generate vRTCT instead of copying a physical one
As the last step to simplify the steps to enable software SRAM passthrough
to a pre-launched RT VM, this patch generates a virtual RTCT which only
contains a compatibility entry (to indicate that the format of the RTCT is
v2) and a couple of SSRAM or SSRAM waymask entries to report the software
SRAM blocks that pre-launched VM has access. That follows the practice how
ACRN device model generates virtual RTCT for post-launched VMs today.

In case RTCT v1 is used physically, this patch still generates a v2 RTCT
for the pre-launched VM but does not add an SSRAM waymask entry there
due to lack of information.

Tracked-On: #7947
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
2022-08-05 07:36:40 +08:00
Junjie Mao eff353700e config_tools: acpi_gen: refactor ACPI table generation logic
While functionally correct, the ACPI table (mostly DSDT) generation logic
in asl_gen.py contains multiple occurrences that share the same code
structure as follows:

    cls = <class of the table>
    length = ctypes.sizeof(cls)
    data = bytearray(length)
    res = cls.from_buffer(data)
    <setting multiple fields in res>

To minimize code duplication, this patch refactors the logic by abstracting
the creation of an ACPI table into a method which returns a newly created
object of the given class after setting the specified fields.

Tracked-On: #7947
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
2022-08-05 07:36:40 +08:00
Junjie Mao 89d54aa5d1 config_tools: board_inspector: record all details from RTCT in board XML
Today users still need to manually copy the RTCT binary file when they want
to passthrough software SRAM to a pre-launched RTVM, which is far from
being user friendly.

To get rid of that step, this patch extracts all information from the RTCT
table and format them in the board XML which is the only file users need to
copy from their target platform to build the hypervisor. The patch that
immediately follows will then use such information to generate vRTCT for
the pre-launched VM.

A side effect of this change is that more ranges, which represents those
reported by RTCT such as the CRL binary or the error log area, will be
added to the `memory` section of the board XML. The `id` attributes of
those range will be used to identify what that range is for. As a result,
getting RAM of the physical platform from the board XML requires additional
conditions on the `id` attributes to avoid counting non-RAM regions
unintendedly.

Tracked-On: #7947
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
2022-08-05 07:36:40 +08:00
Junjie Mao d7bac88e5e config_tools: board_inspector: refactor ACPI RTCT parser
This patch refactors and fixes the following in the ACPI RTCT parser of the
board inspector.

  1. Refactor to expose the RTCTSubtableSoftwareSRAM_v2 class directly as
     it is a fixed-size entry. There is no need to create a dynamic class
     which is mostly for variable-length entries.

  2. Rename the "format" field in RTCT entry header to "format_or_version",
     as that field actually means "version" in RTCT v2.

  3. Properly parse the RTCT compatibility entry which is currently parsed
     as an unknown entry with raw data.

Tracked-On: #7947
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
2022-08-05 07:36:40 +08:00
Liu Long b7d70385d9 SampleApplication: Add Makefile for the entire SampleApplication
Add the Makefile in the SampleApplication root directory. User
don't need to separate build the userapp and rtapp, just need make
once at the SampleApplication root directory.

Tracked-On #7820
Signed-off-by: Liu Long <long.liu@linux.intel.com>
2022-08-04 14:22:39 +08:00
Chenli Wei 6ac196d982 misc: add assert to check the duplicate devices
The current ACRN-Configurator allow user add duplicate PCI devices to
passthrough which it is not correct.

This patch add an assert to check the duplicate of PCI devices.

Tracked-On: #6690
Signed-off-by: Chenli Wei <chenli.wei@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-03 15:34:06 +08:00
Chuang Ke 670ccf21f8 config_tool: Instruction missing for L2-only users
In the cache widget, there are instructions: "Drag the ends of the boxes to cover the cache chunks you want to allocate to specific VMs. If you have a real-time VM,ensure its cache chunks do not overlap with any other VM's cache chunks."

Tracked-On: #7921
Signed-off-by: Chuang-Ke <chuangx.ke@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-08-02 08:43:53 +08:00
Kunhui-Li fa8c149a38 cofig_tools: apply vBDF pattern check to vUART and ivshmem
apply vBDF pattern check to vUART and ivshmem.

Tracked-On: #7925
Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-07-29 17:33:07 +08:00
Kunhui-Li 9a5f42e187 config_tools: add tooltips for cpu affinity
add tooltips for cpu affinity and tiny fix for virtio console device.

Tracked-On: #7933
Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
2022-07-29 17:33:07 +08:00
Kunhui-Li e83bea0882 config_tools: remove invaild hugepage check
Currently, on the whl-ipc-i5 platform, we found a warning message when
building ACRN with the shared scenario XML file from github.
However, this doesn't affect any feature of ACRN according to the QA's
test result.

So this patch removes this check in order not to confuse users at the first.
If necessary, we will add back the check after getting more detail.

v1-->v2
degrade the log level to debug.

Tracked-On: #7926
Signed-off-by: Kunhui-Li <kunhuix.li@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-07-29 17:33:07 +08:00
Chenli Wei da44d6337a misc: refine slot issue of launch script
The current launch script allocate bdf for ivshmem by itself and have
not get bdf from scenario.

This patch refine the above logic and generate slot by user settings.

Tracked-On: #6690
Signed-off-by: Chenli Wei <chenli.wei@linux.intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-07-29 17:03:45 +08:00
Chuang Ke c46c78591d [config_tool] Order of plus and minus icons is inconsistent
let minus icons in front of plus icons in those views below: Virtio input device, Virtio network device, Virtio console device, CPU affinity.

Tracked-On: projectacrn#7917
Signed-off-by: Chuang-Ke <chuangx.ke@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
2022-07-27 20:57:25 +08:00