Doc: Update GSG and Build ACRN from Source for v2.3

Update Getting Started Guide for ACRN Industry Scenario with Ubuntu Service VM;
and Getting Started Guide for ACRN logical partition mode.
Also update Build ACRN from Source for EFI related part since it is
removed form v2.3

Signed-off-by: fuzhongl <fuzhong.liu@intel.com>
Reviewed-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com
This commit is contained in:
fuzhongl 2020-11-26 15:20:22 +08:00 committed by David Kinder
parent 3db34b3164
commit 124752fcf7
3 changed files with 22 additions and 62 deletions

View File

@ -67,7 +67,6 @@ Install the necessary tools for the following systems:
$ sudo apt install gcc \
git \
make \
gnu-efi \
libssl-dev \
libpciaccess-dev \
uuid-dev \
@ -107,7 +106,6 @@ The `acrn-hypervisor <https://github.com/projectacrn/acrn-hypervisor/>`_
repository contains four main components:
1. The ACRN hypervisor code, located in the ``hypervisor`` directory.
#. The EFI stub code, located in the ``misc/efi-stub`` directory.
#. The ACRN device model code, located in the ``devicemodel`` directory.
#. The ACRN tools source code, located in the ``misc/tools`` directory.
@ -252,29 +250,18 @@ Now you can build all these components at once as follows:
The build results are found in the ``build`` directory. You can specify
a different Output folder by setting the ``O`` ``make`` parameter,
for example: ``make O=build-nuc BOARD=nuc7i7dnb``.
for example: ``make O=build-nuc``.
If you only need the hypervisor, use this command:
.. code-block:: none
$ make clean # Remove files previously built
$ make -C hypervisor
$ make -C misc/efi-stub HV_OBJDIR=$PWD/hypervisor/build EFI_OBJDIR=$PWD/hypervisor/build
The ``acrn.efi`` will be generated in the ``./hypervisor/build/acrn.efi`` directory hypervisor.
As mentioned in :ref:`ACRN Configuration Tool <vm_config_workflow>`, the
Board configuration and VM configuration can be imported from XML files.
If you want to build the hypervisor with XML configuration files,
specify the file location as follows (assuming you're at the top level
of the acrn-hypervisor directory):
.. code-block:: none
$ make BOARD_FILE=$PWD/misc/vm_configs/xmls/board-xmls/nuc7i7dnb.xml \
$ make all BOARD_FILE=$PWD/misc/vm_configs/xmls/board-xmls/nuc7i7dnb.xml \
SCENARIO_FILE=$PWD/misc/vm_configs/xmls/config-xmls/nuc7i7dnb/industry.xml TARGET_DIR=xxx
The build results are found in the ``build`` directory. You can specify
a different build folder by setting the ``O`` ``make`` parameter,
for example: ``make O=build-nuc``.
.. note::
The ``BOARD`` and ``SCENARIO`` parameters are not needed because the

View File

@ -11,9 +11,9 @@ Verified version
****************
- Ubuntu version: **18.04**
- GCC version: **7.4**
- ACRN-hypervisor branch: **release_2.2 (acrn-2020w40.1-180000p)**
- ACRN-Kernel (Service VM kernel): **release_2.2 (5.4.43-PKT-200203T060100Z)**
- GCC version: **7.5**
- ACRN-hypervisor branch: **release_2.3 (v2.3)**
- ACRN-Kernel (Service VM kernel): **release_2.3 (v2.3)**
- RT kernel for Ubuntu User OS: **4.19/preempt-rt (4.19.72-rt25)**
- HW: Maxtang Intel WHL-U i7-8665U (`AX8665U-A2 <http://www.maxtangpc.com/fanlessembeddedcomputers/140.html>`_)
@ -144,7 +144,6 @@ Build the ACRN Hypervisor on Ubuntu
$ sudo -E apt install gcc \
git \
make \
gnu-efi \
libssl-dev \
libpciaccess-dev \
uuid-dev \
@ -174,7 +173,6 @@ Build the ACRN Hypervisor on Ubuntu
.. code-block:: none
$ sudo -E apt-get install iasl
$ cd /home/acrn/work
$ wget https://acpica.org/sites/acpica/files/acpica-unix-20191018.tar.gz
$ tar zxvf acpica-unix-20191018.tar.gz
@ -194,11 +192,11 @@ Build the ACRN Hypervisor on Ubuntu
$ git clone https://github.com/projectacrn/acrn-hypervisor
$ cd acrn-hypervisor
#. Switch to the v2.2 version:
#. Switch to the v2.3 version:
.. code-block:: none
$ git checkout -b v2.2 remotes/origin/release_2.2
$ git checkout v2.3
#. Build ACRN:
@ -223,7 +221,7 @@ Build and install the ACRN kernel
.. code-block:: none
$ git checkout -b v2.2 remotes/origin/release_2.2
$ git checkout v2.3
$ cp kernel_config_uefi_sos .config
$ make olddefconfig
$ make all
@ -343,32 +341,6 @@ The User VM will be launched by OVMF, so copy it to the specific folder:
$ sudo mkdir -p /usr/share/acrn/bios
$ sudo cp /home/acrn/work/acrn-hypervisor/devicemodel/bios/OVMF.fd /usr/share/acrn/bios
Install IASL in Ubuntu for User VM launch
-----------------------------------------
Starting with the ACRN v2.2 release, we use the ``iasl`` tool to
compile an offline ACPI binary for pre-launched VMs while building ACRN,
so we need to install the ``iasl`` tool in the ACRN build environment.
Follow these steps to install ``iasl`` (and its dependencies) and
then update the ``iasl`` binary with a newer version not available
in Ubuntu 18.04:
.. code-block:: none
$ sudo -E apt-get install iasl
$ cd /home/acrn/work
$ wget https://acpica.org/sites/acpica/files/acpica-unix-20191018.tar.gz
$ tar zxvf acpica-unix-20191018.tar.gz
$ cd acpica-unix-20191018
$ make clean && make iasl
$ sudo cp ./generate/unix/bin/iasl /usr/sbin/
.. note:: While there are newer versions of software available from
the `ACPICA downloads site <https://acpica.org/downloads>`_, this
20191018 version has been verified to work.
Build and Install the RT kernel for the Ubuntu User VM
------------------------------------------------------
@ -477,7 +449,8 @@ Launch the RTVM
.. code-block:: none
$ sudo /usr/share/acrn/samples/nuc/launch_hard_rt_vm.sh
$ sudo cp /home/acrn/work/acrn-hyperviso/misc/vm_configs/sample_launch_scripts/nuc/launch_hard_rt_vm.sh /usr/share/acrn/
$ sudo /usr/share/acrn/launch_hard_rt_vm.sh
Recommended BIOS settings for RTVM
----------------------------------
@ -541,13 +514,13 @@ this, follow the below steps to allocate all housekeeping tasks to core 0:
#. Prepare the RTVM launch script
Follow the `Passthrough a hard disk to RTVM`_ section to make adjustments to
the ``/usr/share/acrn/samples/nuc/launch_hard_rt_vm.sh`` launch script.
the ``/usr/share/acrn/launch_hard_rt_vm.sh`` launch script.
#. Launch the RTVM:
.. code-block:: none
$ sudo /usr/share/acrn/samples/nuc/launch_hard_rt_vm.sh
$ sudo /usr/share/acrn/launch_hard_rt_vm.sh
#. Log in to the RTVM as root and run the script as below:
@ -677,7 +650,7 @@ Passthrough a hard disk to RTVM
.. code-block:: none
# vim /usr/share/acrn/samples/nuc/launch_hard_rt_vm.sh
# vim /usr/share/acrn/launch_hard_rt_vm.sh
passthru_vpid=(
["eth"]="8086 156f"
@ -719,4 +692,4 @@ Passthrough a hard disk to RTVM
.. code-block:: none
$ sudo /usr/share/acrn/samples/nuc/launch_hard_rt_vm.sh
$ sudo /usr/share/acrn/launch_hard_rt_vm.sh

View File

@ -18,8 +18,8 @@ Validated Versions
******************
- Ubuntu version: **18.04**
- ACRN hypervisor tag: **v2.1**
- ACRN kernel tag: **v2.1**
- ACRN hypervisor tag: **v2.3**
- ACRN kernel tag: **v2.3**
Prerequisites
*************
@ -145,13 +145,13 @@ Update ACRN hypervisor image
Refer to :ref:`getting-started-building` to set up the ACRN build
environment on your development workstation.
Clone the ACRN source code and check out to the tag v2.1:
Clone the ACRN source code and check out to the tag v2.3:
.. code-block:: none
$ git clone https://github.com/projectacrn/acrn-hypervisor.git
$ cd acrn-hypervisor
$ git checkout v2.1
$ git checkout v2.3
Build the ACRN hypervisor and ACPI binaries for pre-launched VMs with default xmls: