1
0
mirror of https://git.yoctoproject.org/meta-arm synced 2026-05-08 05:09:56 +00:00

10 Commits

Author SHA1 Message Date
Kamil Dziezyk 5f8eabe68f arm-autonomy/xenguest-network: add kea dhcp4 configuration
Since dhcp-server was removed from oe-core layer,
we decided to add kea dhcp support in meta-arm-autonomy.

This patch introduce following changes:
  (*) replaces all configuration and customization valid for dhcpd,
      with kea complatible one.
  (*) replaces dhcp-server rdependency with kea for xenguest-network recipe
  (*) replaces default kea dhcp4 server configuration with a minimal one.

Change-Id: I4202b5b8f3be6801cbb4f9068061eccfdadee5f0
Issue-Id: SCM-1522
Signed-off-by: Kamil Dziezyk <kamil.dziezyk@arm.com>
Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-10-28 10:25:48 -04:00
Kamil Dziezyk bab28a95cd arm-autonomy/xenguest-mkimage: add extra ramdisk support
Some guest images requires a ramdisk, that is built with a custom recipe.
This patch adds an option '--xen-ramdisk',
for xenguest-mkimage script to cover that.
Extra ramdisk support is also added to xenguest-image-extra bbclass,
via 'XENGUEST_EXTRA_RAMDISK' variable.

Issue-Id: SCM-1276
Change-Id: I8ec74a37c0c96ca83a3489911186f3b3262f80fd
Signed-off-by: Kamil Dziezyk <kamil.dziezyk@arm.com>
Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-10-15 11:48:16 -04:00
Diego Sueiro 7318d9ac3c arm-autonomy/xenguest-network: Add private network support for xenguest
Introduce the private/internal network support for xenguest by using NAT
and applying the proper iptables rules to allow the guest to have access
to the external network.

The XENGUEST_NETWORK_TYPE variable was introduced to allow the user to
setup the xenguest network type between "bridge" (default), "nat" and
"none".

Change-Id: I919e5b0fd0809093698b9dec3a9503b598b54828
Issue-Id: SCM-1019
Signed-off-by: Diego Sueiro <diego.sueiro@arm.com>
Reviewed-by: Bertrand Marquis <bertrand.marquis@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-07-30 16:14:58 -04:00
Bertrand Marquis 2ed1b36c56 arm-autonomy: rework initramfs support in xenguest FSTYPE
Rework the initramfs support in xenguest FSTYPE to be compatible with
Dunfell and remove an error with non existing recipeinfo during build.
- remove initramfs support in FSTYPE and do_deploy function
- create a KERNEL CLASS to create a xenguest image containing the kernel
bundle with initramfs during kernel compilation (only done if FSTYPE
contain xenguest and initramfs bundle is activated)
- add kernel-xenguest to KERNEL_CLASSES when autonomy-guest
DISTRO_FEATURE is activated
- remove unused parameters from xenguest-image class

Change-Id: If163aa74a2bbbd4f22651abefe8d2ab4677e82b0
Issue-Id: SCM-990
Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-05-08 10:22:29 -04:00
Bertrand Marquis df189a806b arm-autonomy: Create xenguest network bridge
Add a xenguest-network-bridge script to create a network bridge with the
host interfaces.
Add a xenguest init script to create a xen network interface connected
to the bridge
Add a network interfaces configuration file to have dhcp configuration
on the network bridge
Add xenguest-network-bridge to the default host image
Add XENGUEST_IMAGE_NETWORK_BRIDGE parameter to xenguest-image to let
user setup if a guest should be or not connected to the bridge

Change-Id: Id15fde234386376e89c2562e1ffa935c51affa5b
Issue-Id: SCM-767
Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-04-07 23:32:32 -04:00
Bertrand Marquis 77c6d12f59 arm-autonomy: Create xenguest-image-extra class
Add class xenguest-image-extra to be used by recipes which wants to add
elements to the generated xenguest image.
The recipes using this call must inherit the deploy class and declare a
deploy task that will be extended by the class. The variables
XENGUEST_EXTRA_* documented in the class can be used to define what
should be used to extend the xenguest image.

Change-Id: I8a7682a7a7ca57b424ea815145408ccb8e4348ca
Issue-Id: SCM-767
Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-04-07 23:32:32 -04:00
Bertrand Marquis 926ce4ffcd arm-autonomy: Create xenguest image type
Create an image type xenguest to create a xenguest image as part of a
Yocto image (add FSTYPE xenguest).

The image type is using xenguest-base-image as a producer for the
xenguest image directory, adds kernel defined by
XENGUEST_IMAGE_KERNEL to it, adds rootfs if listed in
XENGUEST_IMAGE_DISK_PARTITIONS and pack the final image with file
extension .xenguest with other types of images.

If initramfs is configured, a xenguest image containing the kernel with
initramfs is produced.

The xenguest image type is added to IMAGE_FSTYPES and IMAGE_CLASSES if
arm-autonomy-guest is set in DISTRO_FEATURES.

Change-Id: Ibae8a50d41375839492e43a2e28d9472dc71b4a1
Issue-Id: SCM-767
Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-04-07 23:32:32 -04:00
Bertrand Marquis 4c76616c9c arm-autonomy: Create xenguest-image class
Create xenguest-image class to be used by recipes and other classes to
manipulate xenguest images.
The recipe is defining some variables to configure default parameters of
xenguest image (memory size, number of vcpus, command line, etc.). Those
parameters all have the prefix XENGUEST_IMAGE_ and are documented at the
beginning of the class.

The class also provide some helper functions:
- xenguest_image_create to create a xenguest image (using global
parameters) in deploy as xenguest image directory
- xenguest_image_clone to clone current xenguest image from deploy to be
able to extend it and pack it in a xenguest image file
- xenguest_image_rootfs_file function to allow other recipes to detect
if the rootfs should or not be embedded in the xenguest image

Change-Id: I4ba54aa2c41e72964c152f673b71fe32f30b4aca
Issue-Id: SCM-767
Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-04-07 23:32:32 -04:00
Bertrand Marquis 23b3db93c3 arm-autonomy: Create arm-autonomy-guest feature
Introduce DISTRO_FEATURE arm-autonomy-guest which is:
- enabling ipv4 in distro features
- enabling xen frontend driver in the linux kernel using a kernel
feature
- enabling console over hvc0

Change-Id: Idd9a708799b35e483dbba22279ce677d9674ef09
Issue-Id: SCM-767
Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-04-07 23:32:32 -04:00
Bertrand Marquis 780adc19c3 arm-autonomy: Create arm-autonomy-host feature
Create a new distribution feature to enable functionalities for autonomy
host systems:
- enable xen and ipv4 in distribution features
- enable xen backend drivers in Linux kernel using a kmeta feature

For the feature to work properly, create a class inherited when the
layer is included to enable required parameters

Change-Id: Ia0cdaa2b69bc030515ea16d67c47fec6b1ea0897
Issue-Id: SCM-767
Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
Reviewed-by: Diego Sueiro <diego.sueiro@arm.com>
Signed-off-by: Jon Mason <jon.mason@arm.com>
2020-04-07 23:32:32 -04:00