diff mbox series

[isar-cip-core,1/2] conf/machine: Add KERNEL_DEFCONFIG_VERSION to select defconfig path

Message ID 20210304170934.7424-2-Quirin.Gylstorff@siemens.com (mailing list archive)
State Handled Elsewhere
Headers show
Series Defconfig matches Kernel version | expand

Commit Message

Quirin Gylstorff March 4, 2021, 5:09 p.m. UTC
From: Quirin Gylstorff <quirin.gylstorff@siemens.com>

The repository cip-kernel-config[1] contains for each supported kernel
version its own directory. Add the variable KERNEL_DEFCONFIG_VERSION
to select the defconfig matching the kernel version.

Also add a version to select the rt configuration of [1].

[1]:https://gitlab.com/cip-project/cip-kernel/cip-kernel-config

Signed-off-by: Quirin Gylstorff <quirin.gylstorff@siemens.com>
---
 conf/machine/bbb.conf             | 5 +++++
 conf/machine/hihope-rzg2m.conf    | 5 ++++-
 conf/machine/iwg20m.conf          | 5 ++++-
 conf/machine/qemu-amd64.conf      | 5 ++++-
 conf/machine/simatic-ipc227e.conf | 5 ++++-
 kas/opt/4.4.yml                   | 1 +
 kas/opt/rt.yml                    | 1 +
 7 files changed, 23 insertions(+), 4 deletions(-)

Comments

Jan Kiszka March 8, 2021, 1:23 p.m. UTC | #1
On 04.03.21 18:09, Q. Gylstorff wrote:
> From: Quirin Gylstorff <quirin.gylstorff@siemens.com>
> 
> The repository cip-kernel-config[1] contains for each supported kernel
> version its own directory. Add the variable KERNEL_DEFCONFIG_VERSION
> to select the defconfig matching the kernel version.
> 
> Also add a version to select the rt configuration of [1].
> 
> [1]:https://gitlab.com/cip-project/cip-kernel/cip-kernel-config
> 
> Signed-off-by: Quirin Gylstorff <quirin.gylstorff@siemens.com>
> ---
>  conf/machine/bbb.conf             | 5 +++++
>  conf/machine/hihope-rzg2m.conf    | 5 ++++-
>  conf/machine/iwg20m.conf          | 5 ++++-
>  conf/machine/qemu-amd64.conf      | 5 ++++-
>  conf/machine/simatic-ipc227e.conf | 5 ++++-

Err, shouldn't those version-selecting variables better be moved into
the versioned kernel recipes?

Jan

>  kas/opt/4.4.yml                   | 1 +
>  kas/opt/rt.yml                    | 1 +
>  7 files changed, 23 insertions(+), 4 deletions(-)
> 
> diff --git a/conf/machine/bbb.conf b/conf/machine/bbb.conf
> index a9b460e..2878ed1 100644
> --- a/conf/machine/bbb.conf
> +++ b/conf/machine/bbb.conf
> @@ -11,6 +11,11 @@ DISTRO_ARCH = "armhf"
>  IMAGE_TYPE ?= "wic-img"
>  IMAGER_INSTALL += "u-boot-omap"
>  
> +# kernel defconfig
> +USE_CIP_KERNEL_CONFIG = "1"
> +KERNEL_DEFCONFIG_VERSION ?= "4.19.y-cip"
> +KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/arm/cip_bbb_defconfig"
> +
>  # On stretch, select U-Boot from buster which comes with distro-boot support
>  DISTRO_APT_SOURCES_append_cip-core-stretch = " conf/distro/debian-buster.list"
>  DISTRO_APT_PREFERENCES_cip-core-stretch += "conf/machine/preferences.bbb.conf"
> diff --git a/conf/machine/hihope-rzg2m.conf b/conf/machine/hihope-rzg2m.conf
> index a2ae03d..2a46b74 100644
> --- a/conf/machine/hihope-rzg2m.conf
> +++ b/conf/machine/hihope-rzg2m.conf
> @@ -13,7 +13,10 @@ DISTRO_ARCH = "arm64"
>  
>  IMAGE_TYPE ?= "wic-img"
>  
> -KERNEL_DEFCONFIG = "cip-kernel-config/4.19.y-cip/arm64/renesas_defconfig"
> +# kernel defconfig
> +KERNEL_DEFCONFIG_VERSION ?= "4.19.y-cip"
> +KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/arm64/renesas_defconfig"
>  USE_CIP_KERNEL_CONFIG = "1"
> +
>  DTB_FILES = "r8a774a1-hihope-rzg2m-ex.dtb"
>  IMAGE_BOOT_FILES = "${KERNEL_IMAGE} ${DTB_FILES}"
> diff --git a/conf/machine/iwg20m.conf b/conf/machine/iwg20m.conf
> index 91bfd94..b5f9490 100644
> --- a/conf/machine/iwg20m.conf
> +++ b/conf/machine/iwg20m.conf
> @@ -17,8 +17,11 @@ BAUDRATE_TTY = "115200"
>  # kernel version
>  PREFERRED_VERSION_linux-cip ?= "4.4.%"
>  PREFERRED_VERSION_linux-cip-rt ?= "4.4.%"
> +
> +# kernel defconfig
>  USE_CIP_KERNEL_CONFIG = "1"
> -KERNEL_DEFCONFIG = "cip-kernel-config/4.4.y-cip/arm/renesas_shmobile_defconfig"
> +KERNEL_DEFCONFIG_VERSION ?= "4.4.y-cip"
> +KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/arm/renesas_shmobile_defconfig"
>  
>  # Boot partition files
>  DTB_FILES = "r8a7743-iwg20d-q7-dbcm-ca.dtb"
> diff --git a/conf/machine/qemu-amd64.conf b/conf/machine/qemu-amd64.conf
> index c90d957..d99d8b1 100644
> --- a/conf/machine/qemu-amd64.conf
> +++ b/conf/machine/qemu-amd64.conf
> @@ -9,5 +9,8 @@
>  DISTRO_ARCH = "amd64"
>  
>  IMAGE_TYPE ?= "ext4-img"
> +
> +# kernel defconfig
>  USE_CIP_KERNEL_CONFIG = "1"
> -KERNEL_DEFCONFIG = "cip-kernel-config/4.19.y-cip/x86/cip_qemu_defconfig"
> +KERNEL_DEFCONFIG_VERSION ?= "4.19.y-cip"
> +KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/x86/cip_qemu_defconfig"
> diff --git a/conf/machine/simatic-ipc227e.conf b/conf/machine/simatic-ipc227e.conf
> index 3c9638f..aacfc9d 100644
> --- a/conf/machine/simatic-ipc227e.conf
> +++ b/conf/machine/simatic-ipc227e.conf
> @@ -10,5 +10,8 @@ DISTRO_ARCH = "amd64"
>  
>  IMAGE_TYPE ?= "wic-img"
>  IMAGER_INSTALL += "${GRUB_BOOTLOADER_INSTALL}"
> +
> +# kernel defconfig
>  USE_CIP_KERNEL_CONFIG = "1"
> -KERNEL_DEFCONFIG = "cip-kernel-config/4.19.y-cip/x86/siemens_ipc227e_defconfig"
> +KERNEL_DEFCONFIG_VERSION ?= "4.19.y-cip"
> +KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/x86/siemens_ipc227e_defconfig"
> diff --git a/kas/opt/4.4.yml b/kas/opt/4.4.yml
> index 65a4775..a601be3 100644
> --- a/kas/opt/4.4.yml
> +++ b/kas/opt/4.4.yml
> @@ -16,3 +16,4 @@ local_conf_header:
>    kernel-version: |
>      PREFERRED_VERSION_linux-cip = "4.4.%"
>      PREFERRED_VERSION_linux-cip-rt = "4.4.%"
> +    KERNEL_DEFCONFIG_VERSION = "4.4.y-cip"
> diff --git a/kas/opt/rt.yml b/kas/opt/rt.yml
> index b8fe6bb..d6fcf78 100644
> --- a/kas/opt/rt.yml
> +++ b/kas/opt/rt.yml
> @@ -15,3 +15,4 @@ header:
>  local_conf_header:
>    preempt-rt: |
>      KERNEL_NAME = "cip-rt"
> +    KERNEL_DEFCONFIG_VERSION_append = "-rt"
>
diff mbox series

Patch

diff --git a/conf/machine/bbb.conf b/conf/machine/bbb.conf
index a9b460e..2878ed1 100644
--- a/conf/machine/bbb.conf
+++ b/conf/machine/bbb.conf
@@ -11,6 +11,11 @@  DISTRO_ARCH = "armhf"
 IMAGE_TYPE ?= "wic-img"
 IMAGER_INSTALL += "u-boot-omap"
 
+# kernel defconfig
+USE_CIP_KERNEL_CONFIG = "1"
+KERNEL_DEFCONFIG_VERSION ?= "4.19.y-cip"
+KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/arm/cip_bbb_defconfig"
+
 # On stretch, select U-Boot from buster which comes with distro-boot support
 DISTRO_APT_SOURCES_append_cip-core-stretch = " conf/distro/debian-buster.list"
 DISTRO_APT_PREFERENCES_cip-core-stretch += "conf/machine/preferences.bbb.conf"
diff --git a/conf/machine/hihope-rzg2m.conf b/conf/machine/hihope-rzg2m.conf
index a2ae03d..2a46b74 100644
--- a/conf/machine/hihope-rzg2m.conf
+++ b/conf/machine/hihope-rzg2m.conf
@@ -13,7 +13,10 @@  DISTRO_ARCH = "arm64"
 
 IMAGE_TYPE ?= "wic-img"
 
-KERNEL_DEFCONFIG = "cip-kernel-config/4.19.y-cip/arm64/renesas_defconfig"
+# kernel defconfig
+KERNEL_DEFCONFIG_VERSION ?= "4.19.y-cip"
+KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/arm64/renesas_defconfig"
 USE_CIP_KERNEL_CONFIG = "1"
+
 DTB_FILES = "r8a774a1-hihope-rzg2m-ex.dtb"
 IMAGE_BOOT_FILES = "${KERNEL_IMAGE} ${DTB_FILES}"
diff --git a/conf/machine/iwg20m.conf b/conf/machine/iwg20m.conf
index 91bfd94..b5f9490 100644
--- a/conf/machine/iwg20m.conf
+++ b/conf/machine/iwg20m.conf
@@ -17,8 +17,11 @@  BAUDRATE_TTY = "115200"
 # kernel version
 PREFERRED_VERSION_linux-cip ?= "4.4.%"
 PREFERRED_VERSION_linux-cip-rt ?= "4.4.%"
+
+# kernel defconfig
 USE_CIP_KERNEL_CONFIG = "1"
-KERNEL_DEFCONFIG = "cip-kernel-config/4.4.y-cip/arm/renesas_shmobile_defconfig"
+KERNEL_DEFCONFIG_VERSION ?= "4.4.y-cip"
+KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/arm/renesas_shmobile_defconfig"
 
 # Boot partition files
 DTB_FILES = "r8a7743-iwg20d-q7-dbcm-ca.dtb"
diff --git a/conf/machine/qemu-amd64.conf b/conf/machine/qemu-amd64.conf
index c90d957..d99d8b1 100644
--- a/conf/machine/qemu-amd64.conf
+++ b/conf/machine/qemu-amd64.conf
@@ -9,5 +9,8 @@ 
 DISTRO_ARCH = "amd64"
 
 IMAGE_TYPE ?= "ext4-img"
+
+# kernel defconfig
 USE_CIP_KERNEL_CONFIG = "1"
-KERNEL_DEFCONFIG = "cip-kernel-config/4.19.y-cip/x86/cip_qemu_defconfig"
+KERNEL_DEFCONFIG_VERSION ?= "4.19.y-cip"
+KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/x86/cip_qemu_defconfig"
diff --git a/conf/machine/simatic-ipc227e.conf b/conf/machine/simatic-ipc227e.conf
index 3c9638f..aacfc9d 100644
--- a/conf/machine/simatic-ipc227e.conf
+++ b/conf/machine/simatic-ipc227e.conf
@@ -10,5 +10,8 @@  DISTRO_ARCH = "amd64"
 
 IMAGE_TYPE ?= "wic-img"
 IMAGER_INSTALL += "${GRUB_BOOTLOADER_INSTALL}"
+
+# kernel defconfig
 USE_CIP_KERNEL_CONFIG = "1"
-KERNEL_DEFCONFIG = "cip-kernel-config/4.19.y-cip/x86/siemens_ipc227e_defconfig"
+KERNEL_DEFCONFIG_VERSION ?= "4.19.y-cip"
+KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/x86/siemens_ipc227e_defconfig"
diff --git a/kas/opt/4.4.yml b/kas/opt/4.4.yml
index 65a4775..a601be3 100644
--- a/kas/opt/4.4.yml
+++ b/kas/opt/4.4.yml
@@ -16,3 +16,4 @@  local_conf_header:
   kernel-version: |
     PREFERRED_VERSION_linux-cip = "4.4.%"
     PREFERRED_VERSION_linux-cip-rt = "4.4.%"
+    KERNEL_DEFCONFIG_VERSION = "4.4.y-cip"
diff --git a/kas/opt/rt.yml b/kas/opt/rt.yml
index b8fe6bb..d6fcf78 100644
--- a/kas/opt/rt.yml
+++ b/kas/opt/rt.yml
@@ -15,3 +15,4 @@  header:
 local_conf_header:
   preempt-rt: |
     KERNEL_NAME = "cip-rt"
+    KERNEL_DEFCONFIG_VERSION_append = "-rt"