Amit Pundir | 097c242 | 2020-02-19 20:12:40 +0530 | [diff] [blame^] | 1 | ifndef TARGET_KERNEL_USE |
| 2 | |
| 3 | KERNEL_MODS := $(wildcard device/linaro/dragonboard-kernel/android-5.4/*.ko) |
Amit Pundir | 1addda6 | 2020-02-02 13:07:33 +0530 | [diff] [blame] | 4 | |
Amit Pundir | 8e3de69 | 2020-02-01 18:25:51 +0530 | [diff] [blame] | 5 | # Local modules are built from following tree: |
| 6 | # https://github.com/pundiramit/linux/tree/android-5.4-modules |
Amit Pundir | 097c242 | 2020-02-19 20:12:40 +0530 | [diff] [blame^] | 7 | LOCAL_MODS := $(wildcard device/xiaomi/beryllium/prebuilt-kernel/android-5.4/*.ko) |
Amit Pundir | 1addda6 | 2020-02-02 13:07:33 +0530 | [diff] [blame] | 8 | |
Amit Pundir | 816b048 | 2020-02-01 20:25:18 +0530 | [diff] [blame] | 9 | # Skip copying modules broken on android-5.4 |
| 10 | # Use local module copy instead |
Amit Pundir | 097c242 | 2020-02-19 20:12:40 +0530 | [diff] [blame^] | 11 | SKIP_MODS := %/msm.ko |
Amit Pundir | 1addda6 | 2020-02-02 13:07:33 +0530 | [diff] [blame] | 12 | |
| 13 | # BT modules go to vendor partition |
Amit Pundir | 097c242 | 2020-02-19 20:12:40 +0530 | [diff] [blame^] | 14 | ONLY_VENDOR := %/btqca.ko %/hci_uart.ko |
| 15 | BOARD_VENDOR_KERNEL_MODULES := $(filter $(ONLY_VENDOR),$(KERNEL_MODS)) |
Amit Pundir | 1addda6 | 2020-02-02 13:07:33 +0530 | [diff] [blame] | 16 | |
Amit Pundir | 097c242 | 2020-02-19 20:12:40 +0530 | [diff] [blame^] | 17 | BOARD_VENDOR_RAMDISK_KERNEL_MODULES := $(filter-out $(SKIP_MODS) $(ONLY_VENDOR),$(KERNEL_MODS)) |
Amit Pundir | 8e3de69 | 2020-02-01 18:25:51 +0530 | [diff] [blame] | 18 | BOARD_VENDOR_RAMDISK_KERNEL_MODULES += $(LOCAL_MODS) |
Amit Pundir | c738b81 | 2019-06-19 16:13:49 +0530 | [diff] [blame] | 19 | |
Amit Pundir | 097c242 | 2020-02-19 20:12:40 +0530 | [diff] [blame^] | 20 | else # ifdef TARGET_KERNEL_USE |
| 21 | |
| 22 | KERNEL_MODS := $(wildcard device/xiaomi/beryllium/prebuilt-kernel/android-$(TARGET_KERNEL_USE)/*.ko) |
| 23 | |
| 24 | # Following modules go to vendor partition |
| 25 | ONLY_VENDOR := %/btqca.ko %/hci_uart.ko |
| 26 | |
| 27 | BOARD_VENDOR_KERNEL_MODULES := $(filter $(ONLY_VENDOR),$(KERNEL_MODS)) |
| 28 | BOARD_VENDOR_RAMDISK_KERNEL_MODULES := $(filter-out $(ONLY_VENDOR),$(KERNEL_MODS)) |
| 29 | |
| 30 | endif |
| 31 | |
Amit Pundir | c738b81 | 2019-06-19 16:13:49 +0530 | [diff] [blame] | 32 | # Inherit the full_base and device configurations |
| 33 | $(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) |
| 34 | $(call inherit-product, device/xiaomi/beryllium/aosp_beryllium/device.mk) |
| 35 | $(call inherit-product, device/xiaomi/beryllium/device-common.mk) |
| 36 | $(call inherit-product, $(SRC_TARGET_DIR)/product/full_base.mk) |
| 37 | |
| 38 | # Product overrides |
| 39 | PRODUCT_NAME := aosp_beryllium |
| 40 | PRODUCT_DEVICE := aosp_beryllium |
| 41 | PRODUCT_BRAND := AOSP |