diff options
author | Ming Liu <liu.ming50@gmail.com> | 2017-11-20 16:45:32 +0800 |
---|---|---|
committer | Laurent Bonnans <laurent.bonnans@here.com> | 2018-05-15 10:49:49 +0200 |
commit | 3af1b32743b245be8c4e199c6a3785bc92e93ab1 (patch) | |
tree | f1967ddf28ed77ccdb15734b8ff2cc114b5cdabd /classes | |
parent | b11ddfbc56721ccc2836c6994678acb3e1b5ca74 (diff) | |
download | meta-updater-3af1b32743b245be8c4e199c6a3785bc92e93ab1.tar.gz |
sota: introduce INITRAMFS_FSTYPES
RAMDISK_EXT and IMAGE_FSTYPES of initramfs-ostree-image should not be
defined separately, because they are representing the same fstype of
a same initramfs image, or else, they turn out to be inconsistent if
the users change one of them.
So we use INITRAMFS_FSTYPES already defined in bitbake.conf, to be able
to set fstype for initramfs. And it should default to ext4.gz.u-boot or
ext4.gz depending on what OSTREE_BOOTLOADER is being set.
Signed-off-by: Ming Liu <liu.ming50@gmail.com>
Diffstat (limited to 'classes')
-rw-r--r-- | classes/image_types_ostree.bbclass | 3 | ||||
-rw-r--r-- | classes/image_types_ota.bbclass | 2 | ||||
-rw-r--r-- | classes/sota.bbclass | 4 |
3 files changed, 4 insertions, 5 deletions
diff --git a/classes/image_types_ostree.bbclass b/classes/image_types_ostree.bbclass index 777360f..349d8fb 100644 --- a/classes/image_types_ostree.bbclass +++ b/classes/image_types_ostree.bbclass | |||
@@ -11,8 +11,7 @@ export OSTREE_REPO | |||
11 | export OSTREE_BRANCHNAME | 11 | export OSTREE_BRANCHNAME |
12 | export GARAGE_TARGET_NAME | 12 | export GARAGE_TARGET_NAME |
13 | 13 | ||
14 | RAMDISK_EXT ?= ".ext4.gz" | 14 | RAMDISK_EXT ?= ".${INITRAMFS_FSTYPES}" |
15 | RAMDISK_EXT_arm ?= ".ext4.gz.u-boot" | ||
16 | 15 | ||
17 | OSTREE_KERNEL ??= "${KERNEL_IMAGETYPE}" | 16 | OSTREE_KERNEL ??= "${KERNEL_IMAGETYPE}" |
18 | 17 | ||
diff --git a/classes/image_types_ota.bbclass b/classes/image_types_ota.bbclass index 17fe4e8..362c1bd 100644 --- a/classes/image_types_ota.bbclass +++ b/classes/image_types_ota.bbclass | |||
@@ -7,8 +7,6 @@ | |||
7 | # boot scripts, kernel and initramfs images | 7 | # boot scripts, kernel and initramfs images |
8 | # | 8 | # |
9 | 9 | ||
10 | OSTREE_BOOTLOADER ??= 'u-boot' | ||
11 | |||
12 | do_image_otaimg[depends] += "e2fsprogs-native:do_populate_sysroot \ | 10 | do_image_otaimg[depends] += "e2fsprogs-native:do_populate_sysroot \ |
13 | ${@'grub:do_populate_sysroot' if d.getVar('OSTREE_BOOTLOADER', True) == 'grub' else ''} \ | 11 | ${@'grub:do_populate_sysroot' if d.getVar('OSTREE_BOOTLOADER', True) == 'grub' else ''} \ |
14 | ${@'virtual/bootloader:do_deploy' if d.getVar('OSTREE_BOOTLOADER', True) == 'u-boot' else ''}" | 12 | ${@'virtual/bootloader:do_deploy' if d.getVar('OSTREE_BOOTLOADER', True) == 'u-boot' else ''}" |
diff --git a/classes/sota.bbclass b/classes/sota.bbclass index 1e765f0..7ff4bf1 100644 --- a/classes/sota.bbclass +++ b/classes/sota.bbclass | |||
@@ -20,13 +20,15 @@ WKS_FILE_sota ?= "sdimage-sota.wks" | |||
20 | 20 | ||
21 | EXTRA_IMAGEDEPENDS_append_sota = " parted-native mtools-native dosfstools-native" | 21 | EXTRA_IMAGEDEPENDS_append_sota = " parted-native mtools-native dosfstools-native" |
22 | 22 | ||
23 | INITRAMFS_FSTYPES = "${@oe.utils.ifelse(d.getVar('OSTREE_BOOTLOADER', True) == 'u-boot', 'ext4.gz.u-boot', 'ext4.gz')}" | ||
24 | |||
23 | # Please redefine OSTREE_REPO in order to have a persistent OSTree repo | 25 | # Please redefine OSTREE_REPO in order to have a persistent OSTree repo |
24 | OSTREE_REPO ?= "${DEPLOY_DIR_IMAGE}/ostree_repo" | 26 | OSTREE_REPO ?= "${DEPLOY_DIR_IMAGE}/ostree_repo" |
25 | # For UPTANE operation, OSTREE_BRANCHNAME must start with "${MACHINE}-" | 27 | # For UPTANE operation, OSTREE_BRANCHNAME must start with "${MACHINE}-" |
26 | OSTREE_BRANCHNAME ?= "${MACHINE}" | 28 | OSTREE_BRANCHNAME ?= "${MACHINE}" |
27 | OSTREE_OSNAME ?= "poky" | 29 | OSTREE_OSNAME ?= "poky" |
28 | OSTREE_INITRAMFS_IMAGE ?= "initramfs-ostree-image" | 30 | OSTREE_INITRAMFS_IMAGE ?= "initramfs-ostree-image" |
29 | 31 | OSTREE_BOOTLOADER ??= 'u-boot' | |
30 | 32 | ||
31 | GARAGE_SIGN_REPO ?= "${DEPLOY_DIR_IMAGE}/garage_sign_repo" | 33 | GARAGE_SIGN_REPO ?= "${DEPLOY_DIR_IMAGE}/garage_sign_repo" |
32 | GARAGE_SIGN_KEYNAME ?= "garage-key" | 34 | GARAGE_SIGN_KEYNAME ?= "garage-key" |