diff options
-rw-r--r-- | classes/image_types_ota.bbclass | 2 | ||||
-rw-r--r-- | conf/include/local/sota_minnowboard.inc | 10 | ||||
-rw-r--r-- | conf/include/local/sota_minnowboard_uboot.inc | 10 | ||||
-rw-r--r-- | recipes-bsp/grub/grub-efi_%.bbappend | 2 | ||||
-rw-r--r-- | scripts/lib/wic/canned-wks/efiimage-sota.wks | 8 | ||||
-rw-r--r-- | scripts/lib/wic/canned-wks/grub-ota.cfg | 2 |
6 files changed, 28 insertions, 6 deletions
diff --git a/classes/image_types_ota.bbclass b/classes/image_types_ota.bbclass index 74533dd..b275930 100644 --- a/classes/image_types_ota.bbclass +++ b/classes/image_types_ota.bbclass | |||
@@ -115,7 +115,7 @@ IMAGE_CMD_otaimg () { | |||
115 | rm -rf ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.otaimg | 115 | rm -rf ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.otaimg |
116 | sync | 116 | sync |
117 | dd if=/dev/zero of=${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.otaimg seek=$OTA_ROOTFS_SIZE count=$COUNT bs=1024 | 117 | dd if=/dev/zero of=${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.otaimg seek=$OTA_ROOTFS_SIZE count=$COUNT bs=1024 |
118 | mkfs.ext4 -O ^64bit ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.otaimg -d ${PHYS_SYSROOT} | 118 | mkfs.ext4 -O ^64bit ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.otaimg -L otaroot -d ${PHYS_SYSROOT} |
119 | rm -rf ${PHYS_SYSROOT} | 119 | rm -rf ${PHYS_SYSROOT} |
120 | 120 | ||
121 | rm -f ${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.otaimg | 121 | rm -f ${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.otaimg |
diff --git a/conf/include/local/sota_minnowboard.inc b/conf/include/local/sota_minnowboard.inc index 5a5b3f4..d39f4d3 100644 --- a/conf/include/local/sota_minnowboard.inc +++ b/conf/include/local/sota_minnowboard.inc | |||
@@ -1,9 +1,9 @@ | |||
1 | MACHINE = "intel-corei7-64" | 1 | MACHINE = "intel-corei7-64" |
2 | 2 | ||
3 | PREFERRED_PROVIDER_virtual/bootloader_sota = "u-boot-ota" | 3 | OSTREE_BOOTLOADER ?= "grub" |
4 | UBOOT_MACHINE_sota = "minnowmax_defconfig" | 4 | EFI_PROVIDER = "grub-efi" |
5 | 5 | ||
6 | EXTRA_IMAGEDEPENDS_append_sota = " minnowboard-bootfiles" | 6 | WKS_FILE = "efiimage-sota.wks" |
7 | IMAGE_BOOT_FILES_sota += "minnowboard-bootfiles/*" | 7 | IMAGE_BOOT_FILES = "" |
8 | 8 | ||
9 | OSTREE_BOOTLOADER ?= "u-boot" | 9 | OSTREE_KERNEL_ARGS ?= "ramdisk_size=16384 rw rootfstype=ext4 rootwait rootdelay=2 ostree_root=/dev/mmcblk2p2 console=ttyS0,115200 console=tty0" |
diff --git a/conf/include/local/sota_minnowboard_uboot.inc b/conf/include/local/sota_minnowboard_uboot.inc new file mode 100644 index 0000000..e64f7eb --- /dev/null +++ b/conf/include/local/sota_minnowboard_uboot.inc | |||
@@ -0,0 +1,10 @@ | |||
1 | MACHINE = "intel-corei7-64" | ||
2 | |||
3 | PREFERRED_PROVIDER_virtual/bootloader = "u-boot-ota" | ||
4 | UBOOT_MACHINE = "minnowmax_defconfig" | ||
5 | |||
6 | EXTRA_IMAGEDEPENDS_append = " minnowboard-bootfiles" | ||
7 | IMAGE_BOOT_FILES = "minnowboard-bootfiles/*" | ||
8 | |||
9 | OSTREE_KERNEL_ARGS ?= "ramdisk_size=16384 rw rootfstype=ext4 rootwait rootdelay=2 ostree_root=/dev/hda console=ttyS0,115200 console=tty0" | ||
10 | |||
diff --git a/recipes-bsp/grub/grub-efi_%.bbappend b/recipes-bsp/grub/grub-efi_%.bbappend new file mode 100644 index 0000000..545e806 --- /dev/null +++ b/recipes-bsp/grub/grub-efi_%.bbappend | |||
@@ -0,0 +1,2 @@ | |||
1 | |||
2 | GRUB_BUILDIN += "configfile" | ||
diff --git a/scripts/lib/wic/canned-wks/efiimage-sota.wks b/scripts/lib/wic/canned-wks/efiimage-sota.wks new file mode 100644 index 0000000..1e37d96 --- /dev/null +++ b/scripts/lib/wic/canned-wks/efiimage-sota.wks | |||
@@ -0,0 +1,8 @@ | |||
1 | # short-description: Create an OTA-enabled EFI disk image | ||
2 | # long-description: Creates an OTA-enabled EFI disk image that the user | ||
3 | # can directly dd to boot media. | ||
4 | |||
5 | part /boot --source bootimg-efi --sourceparams="loader=grub-efi" --ondisk hda --label msdos --active --align 1024 | ||
6 | part / --source otaimage --ondisk hda --fstype=ext4 --align 1024 --use-uuid | ||
7 | |||
8 | bootloader --ptable gpt --timeout=5 --append="rootfstype=ext4 console=ttyS0,115200 console=tty0" --configfile="grub-ota.cfg" | ||
diff --git a/scripts/lib/wic/canned-wks/grub-ota.cfg b/scripts/lib/wic/canned-wks/grub-ota.cfg new file mode 100644 index 0000000..fcd8d70 --- /dev/null +++ b/scripts/lib/wic/canned-wks/grub-ota.cfg | |||
@@ -0,0 +1,2 @@ | |||
1 | search.fs_label otaroot root | ||
2 | configfile /boot/loader/grub.cfg | ||