Commit Graph

4623 Commits

Author SHA1 Message Date
Shuo A Liu
e15bb5f391 hv: Disable HLT and PAUSE-loop exiting emulation in lapic passthrough
In lapic passthrough mode, it should passthrough HLT/PAUSE execution
too. This patch disable their emulation when switch to lapic passthrough mode.

Tracked-On: #4329
Tested-by: Dongsheng Zhang <dongsheng.x.zhang@intel.com>
Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-01-23 13:37:53 +08:00
Shuo A Liu
8af72acf97 hv: debug: show vcpu thread status in vcpu_list debug command
Due to vcpu and its thread are two different perspective modules, each
of them has its own status. Dump both states for better understanding
of system status.

Tracked-On: #4329
Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-01-23 13:37:53 +08:00
Shuo A Liu
cb29f94b40 hv: Use HLT as the default idle action of service OS
This patch overwrites the idle driver of service OS for industry, sdc,
sdc2 scenarios. HLT will be used as the default idle action.

Tracked-On: #4329
Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-01-23 13:37:53 +08:00
Shuo A Liu
655032e020 hv: HLT emulation in hypervisor
HLT emulation is import to CPU resource maximum utilization. vcpu
doing HLT means it is idle and can give up CPU proactively. Thus, we
pause the vcpu thread in HLT emulation and resume it while event happens.

When vcpu enter HLT, its vcpu thread will sleep, but the vcpu state is
still 'Running'.

VM ID    PCPU ID    VCPU ID    VCPU ROLE    VCPU STATE
=====    =======    =======    =========    ==========
  0         0          0       PRIMARY      Running
  0         1          1       SECONDARY    Running

Tracked-On: #4329
Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-01-23 13:37:53 +08:00
Shuo A Liu
55b148ab01 hv: Add vlapic_has_pending_intr of apicv to check pending interrupts
Sometimes HV wants to know if there are pending interrupts of one vcpu.
Add .has_pending_intr interface in acrn_apicv_ops and return the pending
interrupts status by check IRRs of apicv.

Tracked-On: #4329
Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-01-23 13:37:53 +08:00
Shuo A Liu
8e74c2cfd5 hv: vcpu: wait and signal vcpu event support
Introduce two kinds of events for each vcpu,
  VCPU_EVENT_IOREQ: for vcpu waiting for IO request completion
  VCPU_EVENT_VIRTUAL_INTERRUPT: for vcpu waiting for virtual interrupts events
vcpu can wait for such events, and resume to run when the
event get signalled.

This patch also change IO request waiting/notifying to this way.

Tracked-On: #4329
Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-01-23 13:37:53 +08:00
Shuo A Liu
9927b021c5 hv: sched: simple event implemention
This simple event implemention can only support exclusive waiting
at same time. It mainly used by thread who want to wait for special event
happens.
  Thread A who want to wait for some events calls
	wait_event(struct sched_event *);

  Thread B who can give the event signal calls
	signal_event(struct sched_event *);

Tracked-On: #4329
Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-01-23 13:37:53 +08:00
Shuo A Liu
5352463ceb hv: PAUSE-loop exiting support in hypervisor
As we enabled cpu sharing, PAUSE-loop exiting can help vcpu
to release its pcpu proactively. It's good for performance.

VMX_PLE_GAP: upper bound on the amount of time between two successive
executions of PAUSE in a loop.
VMX_PLE_WINDOW: upper bound on the amount of time a guest is allowed to
execute in a PAUSE loop

Tracked-On: #4329
Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2020-01-23 13:37:53 +08:00
Deb Taylor
65bc460127 Updated grammer in ACRN industry scenario doc
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-22 09:16:50 +08:00
Xie, nanlin
7cc887ede2 doc: Modify CL version from 32030 to 31670
Signed-off-by: Xie, nanlin <nanlin.xie@intel.com>
2020-01-21 09:43:19 +08:00
Shuang Zheng
7c06895cb1 doc: reset clear linux version and ootb command in getting start guide
Signed-off-by: Shuang Zheng <shuang.zheng@intel.com>
2020-01-16 13:59:20 +08:00
Jack Ren
6c554faab3 version: v1.5
Signed-off-by: Jack Ren <jack.ren@intel.com>
2020-01-10 19:34:15 +08:00
Deb Taylor
124b58c7da Doc: Updated one paragraph in re_industry doc.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-10 09:23:20 +08:00
Deb Taylor
62c2778a5b Doc: Fixed spelling error in the acrn_config_tool file.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-10 09:23:01 +08:00
Deb Taylor
c54ffa800f Doc: Style and grammar edits to GSG for ACRN Industry Scenario.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-10 09:22:48 +08:00
Deb Taylor
63ea135bad Doc: Grammar updates to ACRN Config Tool doc.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-10 09:22:34 +08:00
Victor Sun
123aadea7c doc: update some xml elements description
Signed-off-by: Victor Sun <victor.sun@intel.com>
2020-01-10 09:22:20 +08:00
Shuang Zheng
db43a7b870 doc: update getting start guide about clear linux version and ootb commands
Signed-off-by: Shuang Zheng <shuang.zheng@intel.com>
2020-01-10 09:22:01 +08:00
fangfang.shen
9e3b713b3f doc: change version info
Signed-off-by: fangfang.shen <fangfang.shen@intel.com>
2020-01-10 09:21:46 +08:00
fuzhongl
f9721e297d Doc: releasenotes_1.5 update
adding this information to releasenotes:
Update to use ACRNGT GOP to install Windows

Signed-off-by: fuzhongl <fuzhong.liu@intel.com>
2020-01-10 09:21:32 +08:00
Deb Taylor
777ca4304b Doc: Grammar update to arcn_ootd.rst.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-10 09:21:18 +08:00
fuzhongl
2c2bd9cd3b Doc: document update base on release_v1.5
Signed-off-by: fuzhongl <fuzhong.liu@intel.com>
2020-01-10 09:21:03 +08:00
Deb Taylor
6ec5db627d Doc: Grammatical edits to RN 1.5.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-10 09:20:44 +08:00
fuzhongl
5e3e33486e Doc: releasenotes_1.5
Signed-off-by: fuzhongl <fuzhong.liu@intel.com>
2020-01-10 09:20:30 +08:00
Geoffroy Van Cutsem
e149f6dc0c doc: fix wrong Docker container image in tutorial
Fix the name of the Docker Container image that is used to build the kernel
for an RTVM (Preempt-RT kernel) when that image was built by the user
him/herself.

Tracked-On: #4322
Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2020-01-10 09:20:12 +08:00
Deb Taylor
2f3546b6fa Doc: Added missing period in run_kata_containers file.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:26:05 +08:00
lirui34
70a2847e70 doc: Update some of the wrong path in acrn configuration tool doc.
Signed-off-by: lirui34 <ruix.li@intel.com>
2020-01-03 13:25:52 +08:00
Geoffroy Van Cutsem
be3c7f99d2 doc: add more details to the Kata Containers with ACRN tutorial
* Add more details about Kata Containers and ACRN in the introduction
* Adjust and correct some of the instructions

Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2020-01-03 13:25:39 +08:00
Deb Taylor
2d53d029ba Doc: Added Whiskey Lake specs to hardware ref page
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:25:26 +08:00
wenlingz
a5dbf41641 remove no support OS parts and add whl build
Signed-off-by: wenlingz <wenling.zhang@intel.com>
2020-01-03 13:25:13 +08:00
Conghui Chen
3660ff44d9 DOC: Content edits to CPU Sharing doc
Signed-off-by: Conghui Chen <conghui.chen@intel.com>
2020-01-03 13:25:01 +08:00
Deb Taylor
4ad3c814f4 Doc: Content edits to Running Kata containers on a Service VM doc
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:24:49 +08:00
Deb Taylor
799b1bae9d Doc: More edits to CPU Sharing doc.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:24:36 +08:00
Deb Taylor
55975688ad Doc: Add v1.5 release menu choice.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:24:22 +08:00
Deb Taylor
6fc8aa2151 Doc: Content edit to cpu-sharing page
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:24:09 +08:00
Deb Taylor
6d6eab40e2 Doc: Content edit to rt_industry document.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:23:56 +08:00
lirui34
a0c8f5845c doc: Add tutorial about how to launch kata vm.
Signed-off-by: lirui34 <ruix.li@intel.com>
2020-01-03 13:23:44 +08:00
fenglin.hu
10e0e33d8f doc: modify Configuration Tools
Signed-off-by: fenglin.hu <fenglin.hu@intel.com>
2020-01-03 13:23:32 +08:00
Conghui Chen
bb91377b7f doc: add document for cpu sharing
Add document and usage for cpu sharing.

Signed-off-by: Conghui Chen <conghui.chen@intel.com>
2020-01-03 13:23:18 +08:00
Deb Taylor
da1267b2d5 Doc: Content edits to Using WaaG VM on ACRN
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:23:06 +08:00
Deb Taylor
11cdaad03a Doc: Content edits to the introduction/index file.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:22:52 +08:00
Deb Taylor
5fe2573218 Doc: Content edits to the acrntrace README file.
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2020-01-03 13:22:22 +08:00
Yuan Liu
c4e6924d66 doc: add windows 10 activation
Signed-off-by: Yuan Liu <yuan1.liu@intel.com>
2020-01-03 13:22:09 +08:00
Jian Jun Chen
0d78ca597a doc: Update WaaG GSG to use ACRNGT GOP to install Windows
Signed-off-by: Jian Jun Chen <jian.jun.chen@intel.com>
2020-01-03 13:21:57 +08:00
Geoffroy Van Cutsem
a368512afe doc: add a little info on how to configure the boot options
Add a little information (at least pointers) as to how one can change the VM
(Pre-launched, Service or User) boot options.

Tracked-On: #3758
Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2020-01-03 13:21:45 +08:00
Yonghua Huang
eed89a051f doc:debug feature is disabled by default
Update guidance to build ACRN from source,
as debug feature is disabled by default in Makefile.

 'RELEASE' shall be 0 if debug feature is required.

Tracked-On: #4222
Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
2020-01-03 13:21:33 +08:00
Geoffroy Van Cutsem
8956f6d8f7 doc: add new dependency to Clear Linux ACRN builder container
Since commit 9e9e1f61, a new build dependency on the NUMA library has been
introduced. We therefore need to add the `devpkg-numactl` bundle to our
Dockerfile used to build the Clear Linux "ACRN builder" container image.

Tracked-On: #4175
Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2020-01-03 11:48:54 +08:00
Jian Jun Chen
5bf1f04ad7 hv: instr_emul: add emulation for 0xf6 test instruction
It is found that 0xf6 test instruction is used to access MMIO in
Windows. This patch added emulation for 0xf6 test instruction.

Tracked-On: #4310
Signed-off-by: Jian Jun Chen <jian.jun.chen@intel.com>
2019-12-30 09:26:05 +08:00
Victor Sun
ee74737fd2 HV: search rsdp from e820 acpi reclaim region
Per ACPI 6.2 spec, chapter 5.2.5.2 "Finding the RSDP on UEFI Enabled Systems":

In Unified Extensible Firmware Interface (UEFI) enabled systems, a pointer to
the RSDP structure exists within the EFI System Table. The OS loader is provided
a pointer to the EFI System Table at invocation. The OS loader must retrieve the
pointer to the RSDP structure from the EFI System Table and convey the pointer
to OSPM, using an OS dependent data structure, as part of the hand off of
control from the OS loader to the OS.

So when ACRN boot from direct mode on a UEFI enabled system, hypervisor might
be failed to get rsdp by seaching rsdp in legacy EBDA or 0xe0000~0xfffff region,
but it still have chance to get rsdp by seaching it in e820 ACPI reclaimable
region with some edk2 based BIOS.

The patch will search rsdp from e820 ACPI reclaim region When failed to get
rsdp from legacy region.

Tracked-On: #4301

Signed-off-by: Victor Sun <victor.sun@intel.com>
Reviewed-by: Fei Li <fei1.li@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2019-12-25 15:06:20 +08:00
Wei Liu
578a7ab4e0 acrn-config: remove pcpu3 from vm1 in SDC scenario
Currently kata vm is supported in SDC scenario by default, both vm1
and kata vm would share pcpu id 3 for vcpu affinity even when cpu
sharing is not enabled.
Remove pcpu id 3 from vm1 in SDC scenario config xmls.

Tracked-On: #4286
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2019-12-23 10:25:00 +08:00