diff --git a/package/base-files/files/lib/upgrade/common.sh b/package/base-files/files/lib/upgrade/common.sh index b00e65350b..abe4eb7aba 100644 --- a/package/base-files/files/lib/upgrade/common.sh +++ b/package/base-files/files/lib/upgrade/common.sh @@ -249,6 +249,13 @@ export_partdevice() { if [ -b "/dev/$part" ]; then export "$var=$part" return 0 + else + # ventoy + local devpath="`readlink /sys/dev/block/$BOOTDEV_MAJOR:$(($BOOTDEV_MINOR + $offset))`" + [ -n "$devpath" ] && { + export "$var=${devpath##*/}" + return 0 + } fi fi diff --git a/package/kernel/linux/modules/block.mk b/package/kernel/linux/modules/block.mk index 3dbeca9f9f..e47da0ef75 100644 --- a/package/kernel/linux/modules/block.mk +++ b/package/kernel/linux/modules/block.mk @@ -205,10 +205,15 @@ $(eval $(call KernelPackage,block2mtd)) define KernelPackage/dax SUBMENU:=$(BLOCK_MENU) TITLE:=DAX: direct access to differentiated memory - KCONFIG:=CONFIG_DAX + KCONFIG:=CONFIG_DAX=y FILES:=$(LINUX_DIR)/drivers/dax/dax.ko endef +define KernelPackage/dax/install + $(INSTALL_DIR) $(1)/lib/modules/!ventoy + echo "DUMMY" >$(1)/lib/modules/!ventoy/dax.ko +endef + $(eval $(call KernelPackage,dax)) @@ -231,7 +236,8 @@ define KernelPackage/dm CONFIG_DM_SNAPSHOT=n \ CONFIG_DM_LOG_USERSPACE=n \ CONFIG_MD=y \ - CONFIG_BLK_DEV_DM \ + CONFIG_BLK_DEV_DM=y \ + CONFIG_DM_INIT=y \ CONFIG_DM_CRYPT \ CONFIG_DM_MIRROR FILES:= \ @@ -247,6 +253,11 @@ define KernelPackage/dm/description Kernel module necessary for LVM2 support endef +define KernelPackage/dm/install + $(INSTALL_DIR) $(1)/lib/modules/!ventoy + echo "DUMMY" >$(1)/lib/modules/!ventoy/dm-mod.ko +endef + $(eval $(call KernelPackage,dm)) define KernelPackage/dm-raid diff --git a/target/linux/x86/base-files/lib/upgrade/platform.sh b/target/linux/x86/base-files/lib/upgrade/platform.sh index ea9d0cdb97..b8172f7f11 100644 --- a/target/linux/x86/base-files/lib/upgrade/platform.sh +++ b/target/linux/x86/base-files/lib/upgrade/platform.sh @@ -2,7 +2,7 @@ # 1. keep overlay partition when upgrade # 2. reset rom uuid in ext_overlay (aka sandbox mode) when upgrade (stage2:istoreos_pre_upgrade) -RAMFS_COPY_BIN='grub-bios-setup' +RAMFS_COPY_BIN='grub-bios-setup readlink' platform_check_image() { local diskdev partdev diff