X6833B: Build a vendor_dlkm image

* vendor_dlkm contains kernel modules that were previously located to
  /vendor/lib/modules and is updatable separately, making us able to
  test kernel modifications faster

* Reference: https://source.android.com/docs/core/architecture/partitions/vendor-odm-dlkm-partition

Signed-off-by: Woomymy <woomy@woomy.be>
Change-Id: I38f5989d4e5a52bf295add8099f6bf6cb8ea3288
Signed-off-by: dodyirawan85 <40514988+dodyirawan85@users.noreply.github.com>
This commit is contained in:
Woomymy 2023-03-18 16:09:51 +01:00 committed by dodyirawan85
parent 538a5a47db
commit 2648454f4f
2 changed files with 7 additions and 2 deletions

View file

@ -69,6 +69,7 @@ RECOVERY_MODULES := $(addprefix $(KERNEL_PATH)/modules/, $(BOARD_VENDOR_RAMDISK_
# Prevent duplicated entries (to solve duplicated build rules problem)
BOARD_VENDOR_RAMDISK_KERNEL_MODULES := $(sort $(BOARD_VENDOR_RAMDISK_KERNEL_MODULES) $(RECOVERY_MODULES))
# Vendor modules (installed to vendor_dlkm)
BOARD_VENDOR_KERNEL_MODULES_LOAD := $(strip $(shell cat $(KERNEL_PATH)/modules.load))
BOARD_VENDOR_KERNEL_MODULES := $(addprefix $(KERNEL_PATH)/modules/, $(BOARD_VENDOR_KERNEL_MODULES_LOAD))
@ -81,19 +82,22 @@ BOARD_VENDOR_BOOTIMAGE_PARTITION_SIZE := 67108864
BOARD_SUPER_PARTITION_SIZE := 9126805504
BOARD_SUPER_PARTITION_GROUPS := mtk_dynamic_partitions
BOARD_MTK_DYNAMIC_PARTITIONS_PARTITION_LIST := system vendor product
BOARD_MTK_DYNAMIC_PARTITIONS_PARTITION_LIST := system vendor product vendor_dlkm
BOARD_MTK_DYNAMIC_PARTITIONS_SIZE := 9122611200
BOARD_EROFS_PCLUSTER_SIZE := 262144
BOARD_USES_METADATA_PARTITION := true
BOARD_USES_VENDOR_DLKMIMAGE := true
BOARD_PRODUCTIMAGE_FILE_SYSTEM_TYPE := erofs
BOARD_SYSTEMIMAGE_FILE_SYSTEM_TYPE := erofs
BOARD_VENDORIMAGE_FILE_SYSTEM_TYPE := erofs
BOARD_VENDOR_DLKMIMAGE_FILE_SYSTEM_TYPE := erofs
TARGET_COPY_OUT_PRODUCT := product
TARGET_COPY_OUT_VENDOR := vendor
TARGET_COPY_OUT_VENDOR_DLKM := vendor_dlkm
# Platform
TARGET_BOARD_PLATFORM := mt6789

View file

@ -16,7 +16,8 @@ AB_OTA_PARTITIONS := \
vbmeta_system \
vbmeta_vendor \
vendor \
vendor_boot
vendor_boot \
vendor_dlkm
AB_OTA_POSTINSTALL_CONFIG += \
RUN_POSTINSTALL_system=true \