summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2021-06-27 15:06:18 -0400
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>2021-06-29 21:31:12 +0000
commitbb745ab9a7c013d90582559df8912632318aa8f0 (patch)
treed2b04c0b623d7a71eede2d4655cbff9abf0a13cb
parentb7f2dbf507a8b2dd67ab7e422ea26122163eaf38 (diff)
meta-agl-lxc: Update host kernel configurationmarlin_12.90.0marlin/12.90.012.90.0
Add a generic kernel bbappend and associated conditional include file that uses the new AGL_KCONFIG_FRAGMENTS to disable all other AGL provided kernel configuration, replacing it with a local fragment to enable minimal required features for LXC support. The previous linux-renesas bbappend to leverage the meta-virtualization provided kernel configuration has been removed, and the agl-lxc template has been updated to drop the "virtualization" distro feature (thus disabling all meta-virtualization additions). Bug-AGL: SPEC-3983 Signed-off-by: Scott Murray <scott.murray@konsulko.com> Change-Id: Iea91c3e273fe01d764adb644efc212f92e4a92fe
-rw-r--r--meta-agl-lxc/dynamic-layers/meta-rcar-gen3/recipes-kernel/linux/linux-renesas_%.bbappend8
-rw-r--r--meta-agl-lxc/recipes-kernel/linux/linux-%.bbappend1
-rw-r--r--meta-agl-lxc/recipes-kernel/linux/linux/lxc.cfg26
-rw-r--r--meta-agl-lxc/recipes-kernel/linux/linux_lxc.inc9
-rw-r--r--templates/feature/agl-lxc/50_local.conf.inc6
5 files changed, 42 insertions, 8 deletions
diff --git a/meta-agl-lxc/dynamic-layers/meta-rcar-gen3/recipes-kernel/linux/linux-renesas_%.bbappend b/meta-agl-lxc/dynamic-layers/meta-rcar-gen3/recipes-kernel/linux/linux-renesas_%.bbappend
deleted file mode 100644
index 0eae3d3c..00000000
--- a/meta-agl-lxc/dynamic-layers/meta-rcar-gen3/recipes-kernel/linux/linux-renesas_%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-# Enable LXC support
-KERNEL_FEATURES += "lxc.scc"
-
-# Workaround cfg/virtio.scc issue in meta-virtualization for now.
-# If it's addition is made not unconditional or the file is made
-# available in meta-virtualization as opposed to yocto-kernel-cache,
-# this can be revisited.
-KERNEL_FEATURES_remove = "cfg/virtio.scc"
diff --git a/meta-agl-lxc/recipes-kernel/linux/linux-%.bbappend b/meta-agl-lxc/recipes-kernel/linux/linux-%.bbappend
new file mode 100644
index 00000000..d50b5d66
--- /dev/null
+++ b/meta-agl-lxc/recipes-kernel/linux/linux-%.bbappend
@@ -0,0 +1 @@
+include ${@'linux_lxc.inc' if bb.data.inherits_class('kernel', d) else ''}
diff --git a/meta-agl-lxc/recipes-kernel/linux/linux/lxc.cfg b/meta-agl-lxc/recipes-kernel/linux/linux/lxc.cfg
new file mode 100644
index 00000000..fb87ea19
--- /dev/null
+++ b/meta-agl-lxc/recipes-kernel/linux/linux/lxc.cfg
@@ -0,0 +1,26 @@
+CONFIG_CGROUP_DEVICE=y
+CONFIG_CPUSETS=y
+CONFIG_PROC_PID_CPUSET=y
+CONFIG_MEMCG=y
+CONFIG_CGROUP_SCHED=y
+CONFIG_FAIR_GROUP_SCHED=y
+CONFIG_RT_GROUP_SCHED=y
+CONFIG_CHECKPOINT_RESTORE=y
+CONFIG_NAMESPACES=y
+CONFIG_UTS_NS=y
+CONFIG_IPC_NS=y
+CONFIG_USER_NS=y
+CONFIG_PID_NS=y
+CONFIG_NET_NS=y
+
+CONFIG_NET_CLS_CGROUP=m
+CONFIG_BLK_CGROUP=y
+CONFIG_CGROUP_NET_PRIO=y
+
+# Virtual drivers
+CONFIG_HVC_DRIVER=y
+
+# Support for virtual ethernet and LXC
+CONFIG_VETH=y
+CONFIG_MACVLAN=y
+CONFIG_VXLAN=m
diff --git a/meta-agl-lxc/recipes-kernel/linux/linux_lxc.inc b/meta-agl-lxc/recipes-kernel/linux/linux_lxc.inc
new file mode 100644
index 00000000..f123f6d9
--- /dev/null
+++ b/meta-agl-lxc/recipes-kernel/linux/linux_lxc.inc
@@ -0,0 +1,9 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/linux:"
+
+# Disable all other AGL provided kernel configuration (barring
+# base BSP provided configuration), and just enable a locally
+# provided fragment with minimal LXC required configuration.
+AGL_KCONFIG_FRAGMENTS = "lxc.cfg"
+
+
+
diff --git a/templates/feature/agl-lxc/50_local.conf.inc b/templates/feature/agl-lxc/50_local.conf.inc
index eeb6aa70..6f337415 100644
--- a/templates/feature/agl-lxc/50_local.conf.inc
+++ b/templates/feature/agl-lxc/50_local.conf.inc
@@ -1 +1,7 @@
BBMULTICONFIG = "agl-container-guest"
+
+# Disable the meta-virtualization configuration support enabled by
+# agl-virt. This should be revisited when upgrading past dunfell,
+# as less of the extra configuration may be enabled in the future.
+DISTRO_FEATURES_remove = "virtualization"
+INHERIT_remove = "sanity-meta-virt"