kernel: Allow installing modules on vendor_overlay

* This allows to easily overlay kernel vendor modules
  on devices with prebuilt vendor.img

Change-Id: Ie870f0c486043b57e4b8b10696830331540ae010
This commit is contained in:
Luca Stefani 2020-08-01 17:24:29 +02:00
parent 939e2e69d1
commit edc2e0c2eb

View file

@ -55,6 +55,8 @@
# modules in root instead of vendor
# NEED_KERNEL_MODULE_SYSTEM = Optional, if true, install kernel
# modules in system instead of vendor
# NEED_KERNEL_MODULE_VENDOR_OVERLAY = Optional, if true, install kernel
# modules in vendor_overlay instead of vendor
ifneq ($(TARGET_NO_KERNEL),true)
@ -158,6 +160,11 @@ else ifeq ($(NEED_KERNEL_MODULE_SYSTEM),true)
KERNEL_MODULES_OUT := $(TARGET_OUT)
KERNEL_DEPMOD_STAGING_DIR := $(KERNEL_BUILD_OUT_PREFIX)$(call intermediates-dir-for,PACKAGING,depmod_system)
KERNEL_MODULE_MOUNTPOINT := system
else ifeq ($(NEED_KERNEL_MODULE_VENDOR_OVERLAY),true)
KERNEL_MODULES_OUT := $(TARGET_OUT_PRODUCT)/vendor_overlay/$(PRODUCT_TARGET_VNDK_VERSION)
KERNEL_DEPMOD_STAGING_DIR := $(KERNEL_BUILD_OUT_PREFIX)$(call intermediates-dir-for,PACKAGING,depmod_product)
KERNEL_MODULE_MOUNTPOINT := vendor
$(INSTALLED_PRODUCTIMAGE_TARGET): $(TARGET_PREBUILT_INT_KERNEL)
else
KERNEL_MODULES_OUT := $(TARGET_OUT_VENDOR)
KERNEL_DEPMOD_STAGING_DIR := $(KERNEL_BUILD_OUT_PREFIX)$(call intermediates-dir-for,PACKAGING,depmod_vendor)