Commit Graph

3944 Commits

Author SHA1 Message Date
lirui34
63e66e6592 doc: hybrid mode scenario introduction
Add introduction about how to enable hybrid mode scenario.

Signed-off-by: lirui34 <ruix.li@intel.com>
2019-08-15 10:00:29 +08:00
David B. Kinder
6b756b8b08 doc: add the SDC2 scenario doc into the navigation
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 10:00:11 +08:00
David B. Kinder
a3251d8542 doc: incorporate scenario-based doc update
PR #3516 was submitted during a documentation reorganization and
resulted in merge conflicts with files that no longer exist.  We closed
that PR and opened this one with those changes applied to the right
files.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 09:59:55 +08:00
David B. Kinder
defac8d195 doc: apply edits to SDC2 scenario doc
Update merged PR #3463 with format and wording improvements.
(Not linked yet into the document navigation)

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 09:59:38 +08:00
Tonny Tzeng
da744ac35f doc: adding guide to launch 2 Linux UOSes using SDC2 scenario
Tracked-On: #3462
Signed-off-by: Tonny Tzeng <tonny.tzeng@intel.com>
Reviewed-by: Fuzhong Liu <fuzhong.liu@intel.com>
Reviewed-by: Nanlin Xie <nanlin.xie@intel.com>
2019-08-15 09:59:22 +08:00
David B. Kinder
b5140fddb3 doc: update v1.0.1 release notes
Fix some wording, table formatting, and links to issues and commits from
the original PR #3515

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 09:59:07 +08:00
lirui34
e33491952f doc: release notes v1.0.1
Add release notes v1.0.1

Signed-off-by: lirui34 <ruix.li@intel.com>
2019-08-15 09:58:50 +08:00
David B. Kinder
4b5a06c1c8 doc: improve CSS for home page grid
Update the ACRN logo size to remove specifics in the CSS.  (Grid images
should be ~100px high for the grid.)

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 09:58:35 +08:00
David B. Kinder
f786168747 doc: fix image proportions on home page for ie
The ACRN icon on the new graphical home page looked fine with firefox,
edge, and chrome browsers, but not on IE.  This PR fixes that

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 09:58:20 +08:00
David B. Kinder
42d7fbea73 doc: fix broken links after content reorg
Home page "button" links needed to be manually updated (because of the
raw html usage) after content around.

Move partition mode docs from try to develop persona pages.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 09:58:04 +08:00
David B. Kinder
fd2e4391ea doc: additional doc navigation restructuring
Adjust doc navigation organization based on additional feedback.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 09:57:48 +08:00
David B. Kinder
34f9fec44c doc: simplify navigation with restored doc org
A few more tweaks to the site navigation since we moved the content back
to its original folder structure.

Remove the temporary "doc reorg in progress" banner.

Add reference to hardware in the "try" section.

Add link to the documentation home page in left nav pane.

Add additional redirects to handle external links to moved content.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 09:57:32 +08:00
David B. Kinder
f88348e956 doc: continue doc restructuring
Changing the folder structure will cause too many broken links for
external references (from other sites). So, let's put the content back
where it was before the reorg, and instead use the new persona-based
navigation to point to documents in the original locations.

Also, introduce redirects for some documents that no longer exits.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-08-15 09:56:49 +08:00
Victor Sun
901a65cb53 HV: inject exception for invalid vmcall
For non-trusty hypercalls, HV should inject #GP(0) to vCPU if they are
from non-ring0 or inject #UD if they are from ring0 of non-SOS. Also
we should not modify RAX of vCPU for these invalid vmcalls.

Tracked-On: #3497

Signed-off-by: Victor Sun <victor.sun@intel.com>
2019-08-01 16:07:57 +08:00
Conghui Chen
c4f6681045 softirq: disable interrupt when modify timer_list
In current code, the timer_list for per cpu can be accessed both in
vmexit and softirq handler. There is a case that, the timer_list is
modifying in vmexit, but an interrupt occur, the timer_list is also
modified in softirq handler. So the time_list may in unpredictable
state. In some platforms, the hv console may hang as its timer handler
is not invoked because of the corruption for timer_list.
So, to fix the issue, disable the interrupt before modifying the
timer_list.

Tracked-On: #3512
Signed-off-by: Yin Fengwei <fengwei.yin@intel.com>
Signed-off-by: Conghui Chen <conghui.chen@intel.com>
Reviewed-by: Li, Fei1 <fei1.li@intel.com>
2019-08-01 15:45:02 +08:00
Victor Sun
f49ab66b65 HV: fix highest severity flag in hybrid mode
In hybrid mode, pre-launched VM should have the highest severity to
handle platform reset, the flag should not be set in SOS VM;

Tracked-On: #3505

Signed-off-by: Victor Sun <victor.sun@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
2019-08-01 15:42:25 +08:00
David B. Kinder
11d4f4159f doc: Reorganize documentation site content
Take the existing ACRN technical documentation and reorganize its
presentation to be persona and use-case based, in preparation for adding
new scenario/use-case based architecture introduction and getting
started documents.

Introduce a more graphical home page and theme color tweaks.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-07-31 18:29:22 -07:00
Xiaoguang Wu
e188e1f245 DM USB: xHCI: fix an error in PORTSC emulation
When DM receives the Disable Slot command, according to xHCI spec,
the PP bit in PORTSC register should not be cleared.

Tracked-On: #3486
Signed-off-by: Xiaoguang Wu <xiaoguang.wu@intel.com>
Acked-by: Yu Wang <yu1.wang@intel.com>
2019-08-01 09:28:01 +08:00
Xiaoguang Wu
55a5876eba DM USB: xHCI: workaround for USB SSD which supports UAS protocol
The USB mediator doesn't support USB Attached SCSI (UAS) protocol
due to no proper implementation for USB Stream. This patch will
use USB Bulk transfer to workaround until formal implentation for
UAS is ready.

Tracked-On: #3486
Signed-off-by: Xiaoguang Wu <xiaoguang.wu@intel.com>
Acked-by: Yu Wang <yu1.wang@intel.com>
2019-08-01 09:28:01 +08:00
Xiaoguang Wu
0e2cfd2dee DM USB: add native info in control transfer logging code
Add native bus and port information in the control transfer logging code.

Tracked-On: #3486
Signed-off-by: Xiaoguang Wu <xiaoguang.wu@intel.com>
Acked-by: Yu Wang <yu1.wang@intel.com>
2019-08-01 09:28:01 +08:00
Peter Fang
87cafaea33 OVMF release v1.2
- Add support for VRING_USED_F_NO_NOTIFY in virtio devices
- Revert "Initialize EmuVariable NV storage memory with varstore from
  ROM"
- Add AcrnEmuVariableFvbRuntimeDxe to support NV storage
- Enable ahci driver.

Secure boot is supported from this release onwards.

Tracked-On: #3506
Signed-off-by: Peter Fang <peter.fang@intel.com>
2019-08-01 09:24:52 +08:00
lirui34
52618d0a23 doc: Update WaaG tutorial launch script and OVMF binary
Change WaaG launch script to the default ``launch_win.sh``,
and also provide one OVMF.fd binary in order to launch WaaG.
Change SOS / UOS to Service VM / Guest VM.

Signed-off-by: lirui34 <ruix.li@intel.com>
2019-07-31 13:08:05 -07:00
Alex Merritt
8f65bfe68d README: Fix Getting Started URL
Signed-off-by: Alex Merritt <mail@alexmerritt.us>
2019-07-31 13:01:35 -07:00
Victor Sun
363daf6aa2 HV: return extended info in vCPUID leaf 0x40000001
In some case, guest need to get more information under virtual environment,
like guest capabilities. Basically this could be done by hypercalls, but
hypercalls are designed for trusted VM/SOS VM, We need a machenism to report
these information for normal VMs. In this patch, vCPUID leaf 0x40000001 will
be used to satisfy this needs that report some extended information for guest
by CPUID.

Tracked-On: #3498

Signed-off-by: Victor Sun <victor.sun@intel.com>
Reviewed-by: Zhao Yakui <yakui.zhao@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2019-07-31 14:13:39 +08:00
Kaige Fu
accdadce98 HV: Enable vART support by intercepting TSC_ADJUST MSR
The policy of vART is that software in native can run in
VM too. And in native side, the relationship between the
ART hardware and TSC is:

  pTSC = (pART * M) / N + pAdjust

The vART solution is:
  - Present the ART capability to guest through CPUID leaf
    15H for M/N which identical to the physical values.
  - PT devices see the pART (vART = pART).
  - Guest expect: vTSC = vART * M / N + vAdjust.
  - VMCS.OFFSET = vTSC - pTSC = vAdjust - pAdjust.

So to support vART, we should do the following:
  1. if vAdjust and vTSC are changed by guest, we should change
     VMCS.OFFSET accordingly.
  2. Make the assumption that the pAjust is never touched by ACRN.

For #1, commit "a958fea hv: emulate IA32_TSC_ADJUST MSR" has implementation
it. And for #2, acrn never touch pAdjust.

--
 v2 -> v3:
   - Add comment when handle guest TSC_ADJUST and TSC accessing.
   - Initialize the VMCS.OFFSET = vAdjust - pAdjust.

 v1 -> v2
   Refine commit message to describe the whole vART solution.

Tracked-On: #3501
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2019-07-31 13:29:51 +08:00
Nikhil Rane
4adc8102fd Makefile: Add install for uefi firmware
Add to include acrn.32.out during cl rpm
 generation as acrn.(board).32.out
This is required for Hybrid mode bringup in multios

Tracked-On:#3487
Signed-off-by: Nikhil Rane <nikhil.rane@intel.com>
2019-07-31 11:41:40 +08:00
Wei Liu
18b4e3023a acrn-config: add README for scenario_config and launch_config
currently scenario config and launch config is not ready, leave these
two folders for futrue useage and make folder structure clear.

Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Reviewed-by: Shuang Zheng shuang.zheng@intel.com
Acked-by: Terry Zou <terry.zou@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2019-07-30 16:38:23 +08:00
Wei Liu
a03b134190 acrn-config: generate a patch and apply to acrn-hypervisor
the script will parser the the board information which already generated on
target board, and apply to the acrn-hypervisor as a patch.

usage: board_cfg_gen.py --board <board_info_file>

sample:
	$ python3 board_cfg_gen.py --board ../target_board/board_info.xml

v1-v2:
1. allow to generate new board patch

v2-v3:
1. modify the description of generator tools
2. parser board_name.xml file
3. coding as PEP8 guildline

Tracked-On: #3480
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Reviewed-by: Shuang Zheng shuang.zheng@intel.com
Acked-by: Terry Zou <terry.zou@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2019-07-30 16:38:23 +08:00
Wei Liu
8adefe26ac acrn-config: generate board information on target board
These tools run on the target board and genearate board information.

usage: python3 board_parser.py <board_name> [--out board_info_file]

sample:
	$ sudo python3 board_parser.py apl-up2

v1-v2:
1. allow board parameter for new board

v2-v3:
1. add the usage descriptions for tools
2. add description of kernel cmd line for README
3. output informations to a xml type
4. coding as PEP8 guildline

Tracked-On: #3480
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Reviewed-by: Shuang Zheng shuang.zheng@intel.com
Acked-by: Terry Zou <terry.zou@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
2019-07-30 16:38:23 +08:00
Tianhua Sun
107c406baa dm: array bound checking to avoid buffer overflow
The array index of "epid" may be out of bounds if
"epid >= XHCI_MAX_ENDPOINTS", so bound check is
necessary before it is used.

Tracked-On: #3434
Signed-off-by: Tianhua Sun <tianhuax.s.sun@intel.com>
Reviewed-by: Yonghua Huang <yonghua.huang@intel.com>
Reviewed-by: Xiaoguang Wu <xiaoguang.wu@intel.com>
2019-07-30 16:36:13 +08:00
Tianhua Sun
493ddefd47 dm: fix pointer not checked for null before use
this patch fix null pointer access issues.

Tracked-On: #3434
Signed-off-by: Tianhua Sun <tianhuax.s.sun@intel.com>
Reviewed-by: Xiaoguang Wu <xiaoguang.wu@intel.com>
2019-07-30 16:36:13 +08:00
Yonghua Huang
d4f44bc7a6 hv: fix debug message format in 'init_pci_pdev_list'
To fix below err format:
  "%s" is used to output 'secondary_bus' with type of 'uint8_t'

Tracked-On: #861
Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
2019-07-30 16:33:11 +08:00
fuyanX
bde1d4b1bb acrn-hv: code review fix lib/string.c
In lib/string.c, strncmp doesn't consider condition "n_arg=0",
just add a process to "n_arg=0".

Tracked-On: projectacrn/acrn-hypervisor#3466
Signed-off-by: YanX Fu <yanx.fu@intel.com>
Reviewed-by: Yonghua Huang <yonghua.huang@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
2019-07-30 14:38:03 +08:00
yuhong.tao@intel.com
653aa859b1 DM: monitor support force stop
When someone send DM message DM_STOP, with a non-zero data.acrnd_stop.force
value, DM set suspend mode to VM_SUSPEND_POWEROFF directly, that will
cause DM quit main loop. That can force stop VM

Tracked-On: #3484
Signed-off-by: Tao Yuhong <yuhong.tao@intel.com>
Reviewed-by: Yan, Like <like.yan@intel.com>
2019-07-30 13:27:16 +08:00
yuhong.tao@intel.com
8b27daa778 tools: acrnctl add '--force' option to 'stop' cmd
Run 'acrnctl stop VM_NAME --force‘ to force stop VM

When run 'acrnctl stop VM_NAME', acrn-dm let guest OS to shutdown
itself. If something wrong with guest OS, it can't shutdown, we can
run 'acrnctl stop VM_NAME --force', thus acrn-dm directly set suspend
mode to VM_SUSPEND_POWEROFF and quit main loop.

Tracked-On: #3484
Signed-off-by: Tao Yuhong <yuhong.tao@intel.com>
Reviewed-by: Yan, Like <like.yan@intel.com>
2019-07-30 13:27:16 +08:00
yuhong.tao@intel.com
59fd4202d3 tools: add force parameter to acrn VM stop operations
Add 'force' parameter to acrn_stop(), which will be write to request
message, the value of data.acrnd_stop.force. So we can tell DM to
force stop VM, instead of telling UOS to shutdown itself.

Tracked-On: #3484
Signed-off-by: Tao Yuhong <yuhong.tao@intel.com>
Acked-by: Yan, Like <like.yan@intel.com>
2019-07-30 13:27:16 +08:00
Yang, Yu-chu
d1c8a514f6 doc: Add ovmf option description
Added ovmf NV storage writeback option "w" description and usage example.

Signed-off-by: Yang, Yu-chu <yu-chu.yang@intel.com>
2019-07-29 20:36:43 -07:00
Victor Sun
9139f94ec9 HV: correct CONFIG_BOARD string of apl up2
The CONFIG_BOARD value in defconfig should match with Makefile, otherwise
the build might be failed in some condition.

Tracked-On: #2291

Signed-off-by: Victor Sun <victor.sun@intel.com>
2019-07-30 09:50:10 +08:00
David B. Kinder
8ee1615e51 doc: fix issues from moving tools to misc/tools
PR #3483 cleaned up the project root folder and moved stuff that was in
/tools into a new /misc folder.  There were a few references to
the old /tools folder missed in that update, addressed in this PR.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-07-29 14:23:04 -07:00
Deb Taylor
f44517c772 final edits 3
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2019-07-29 13:58:41 -07:00
Deb Taylor
879d01319f final edit 2
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2019-07-29 13:58:41 -07:00
Deb Taylor
1ccb902048 final edits
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2019-07-29 13:58:41 -07:00
Deb Taylor
d485ed86c0 edits
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2019-07-29 13:58:41 -07:00
Deb Taylor
28e49ac183 more edits 2019-07-29 13:58:41 -07:00
Deb Taylor
cc2714eee9 edits from David review
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2019-07-29 13:58:41 -07:00
Deb Taylor
7ee02d8eb0 Image resize
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2019-07-29 13:58:41 -07:00
Deb Taylor
87162e8b3e Making three images even smaller
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2019-07-29 13:58:41 -07:00
Deb Taylor
42960ddcc8 Adjust picture size for SGX
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2019-07-29 13:58:41 -07:00
Deb Taylor
d0f7563d89 Corrected images and formatting
Signed-off-by: Deb Taylor <deb.taylor@intel.com>
2019-07-29 13:58:41 -07:00
deb-intel
ce7a126f7e Added 3 SGX images 2019-07-29 13:58:41 -07:00